use of org.openkilda.wfm.share.zk.ZooKeeperBolt in project open-kilda by telstra.
the class FlowHsTopology method zkBolt.
private void zkBolt(TopologyBuilder topologyBuilder) {
ZooKeeperBolt zooKeeperBolt = new ZooKeeperBolt(getConfig().getBlueGreenMode(), getZkTopoName(), getZookeeperConfig(), getBoltInstancesCount(ComponentId.FLOW_CREATE_HUB.name(), ComponentId.FLOW_UPDATE_HUB.name(), ComponentId.FLOW_DELETE_HUB.name(), ComponentId.FLOW_PATH_SWAP_HUB.name(), ComponentId.FLOW_REROUTE_HUB.name(), ComponentId.FLOW_SWAP_ENDPOINTS_HUB.name(), ComponentId.FLOW_ROUTER_BOLT.name(), ComponentId.FLOW_CREATE_MIRROR_POINT_HUB.name(), ComponentId.FLOW_DELETE_MIRROR_POINT_HUB.name(), ComponentId.FLOW_VALIDATION_HUB.name(), ComponentId.YFLOW_CREATE_HUB.name(), ComponentId.YFLOW_UPDATE_HUB.name(), ComponentId.YFLOW_REROUTE_HUB.name(), ComponentId.YFLOW_DELETE_HUB.name(), ComponentId.YFLOW_READ_BOLT.name(), ComponentId.YFLOW_VALIDATION_HUB.name()));
declareBolt(topologyBuilder, zooKeeperBolt, ZooKeeperBolt.BOLT_ID).allGrouping(ComponentId.FLOW_CREATE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_UPDATE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_DELETE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_PATH_SWAP_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_REROUTE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_SWAP_ENDPOINTS_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_ROUTER_BOLT.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_CREATE_MIRROR_POINT_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_DELETE_MIRROR_POINT_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.FLOW_VALIDATION_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_CREATE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_UPDATE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_REROUTE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_DELETE_HUB.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_READ_BOLT.name(), ZkStreams.ZK.toString()).allGrouping(ComponentId.YFLOW_VALIDATION_HUB.name(), ZkStreams.ZK.toString());
}
use of org.openkilda.wfm.share.zk.ZooKeeperBolt in project open-kilda by telstra.
the class RerouteTopology method zkBolt.
private void zkBolt(TopologyBuilder topologyBuilder) {
ZooKeeperBolt zooKeeperBolt = new ZooKeeperBolt(getConfig().getBlueGreenMode(), getZkTopoName(), getZookeeperConfig(), getBoltInstancesCount(RerouteBolt.BOLT_ID, OperationQueueBolt.BOLT_ID));
declareBolt(topologyBuilder, zooKeeperBolt, ZooKeeperBolt.BOLT_ID).allGrouping(RerouteBolt.BOLT_ID, ZkStreams.ZK.toString()).allGrouping(OperationQueueBolt.BOLT_ID, ZkStreams.ZK.toString());
}
use of org.openkilda.wfm.share.zk.ZooKeeperBolt in project open-kilda by telstra.
the class OpenTsdbTopology method createTopology.
@Override
public StormTopology createTopology() {
logger.info("Creating OpenTsdbTopology - {}", topologyName);
TopologyBuilder tb = new TopologyBuilder();
ZooKeeperSpout zooKeeperSpout = new ZooKeeperSpout(getConfig().getBlueGreenMode(), getZkTopoName(), getZookeeperConfig());
declareSpout(tb, zooKeeperSpout, ZooKeeperSpout.SPOUT_ID);
ZooKeeperBolt zooKeeperBolt = new ZooKeeperBolt(getConfig().getBlueGreenMode(), getZkTopoName(), getZookeeperConfig(), getBoltInstancesCount(OTSDB_PARSE_BOLT_ID));
declareBolt(tb, zooKeeperBolt, ZooKeeperBolt.BOLT_ID).allGrouping(OTSDB_PARSE_BOLT_ID, ZkStreams.ZK.toString());
attachInput(tb);
OpenTsdbConfig openTsdbConfig = topologyConfig.getOpenTsdbConfig();
declareBolt(tb, new DatapointParseBolt(), OTSDB_PARSE_BOLT_ID).shuffleGrouping(OTSDB_SPOUT_ID).allGrouping(ZooKeeperSpout.SPOUT_ID);
declareBolt(tb, new OpenTSDBFilterBolt(), OTSDB_FILTER_BOLT_ID).fieldsGrouping(OTSDB_PARSE_BOLT_ID, new Fields("hash"));
OpenTsdbClient.Builder tsdbBuilder = OpenTsdbClient.newBuilder(openTsdbConfig.getHosts()).returnDetails();
if (openTsdbConfig.getClientChunkedRequestsEnabled()) {
tsdbBuilder.enableChunkedEncoding();
}
OpenTsdbBolt openTsdbBolt = new OpenTsdbBolt(tsdbBuilder, Collections.singletonList(TupleOpenTsdbDatapointMapper.DEFAULT_MAPPER));
openTsdbBolt.withBatchSize(openTsdbConfig.getBatchSize()).withFlushInterval(openTsdbConfig.getFlushInterval());
declareBolt(tb, openTsdbBolt, OTSDB_BOLT_ID).shuffleGrouping(OTSDB_FILTER_BOLT_ID);
return tb.createTopology();
}
use of org.openkilda.wfm.share.zk.ZooKeeperBolt in project open-kilda by telstra.
the class StatsTopology method zooKeeperBolt.
private void zooKeeperBolt(TopologyBuilder topologyBuilder) {
ZooKeeperBolt zooKeeperBolt = new ZooKeeperBolt(getConfig().getBlueGreenMode(), getZkTopoName(), getZookeeperConfig(), getBoltInstancesCount(STATS_REQUESTER_BOLT.name(), STATS_OFS_ROUTER_BOLT.name(), SERVER42_STATS_FLOW_RTT_METRIC_GEN.name(), STATS_CACHE_BOLT.name()));
declareBolt(topologyBuilder, zooKeeperBolt, ZooKeeperBolt.BOLT_ID).allGrouping(STATS_REQUESTER_BOLT.name(), StatsRequesterBolt.ZOOKEEPER_STREAM).allGrouping(STATS_OFS_ROUTER_BOLT.name(), SpeakerStatsRouterBolt.ZOOKEEPER_STREAM).allGrouping(SERVER42_STATS_FLOW_RTT_METRIC_GEN.name(), FlowRttMetricGenBolt.ZOOKEEPER_STREAM).allGrouping(STATS_CACHE_BOLT.name(), CacheBolt.ZOOKEEPER_STREAM);
}
use of org.openkilda.wfm.share.zk.ZooKeeperBolt in project open-kilda by telstra.
the class FloodlightRouterTopology method zkBolt.
private void zkBolt(TopologyBuilder topology) {
ZooKeeperBolt zooKeeperBolt = new ZooKeeperBolt(topologyConfig.getBlueGreenMode(), getZkTopoName(), getZookeeperConfig(), getBoltInstancesCount(SpeakerToNetworkProxyBolt.BOLT_ID, ComponentType.SPEAKER_DISCO_REQUEST_BOLT, ComponentType.KILDA_FLOW_HS_REPLY_BOLT, ComponentType.SPEAKER_FLOW_REQUEST_BOLT, ComponentType.KILDA_PING_REPLY_BOLT, ComponentType.KILDA_STATS_REPLY_BOLT, ComponentType.KILDA_ISL_LATENCY_REPLY_BOLT, ComponentType.KILDA_CONNECTED_DEVICES_REPLY_BOLT, ComponentType.KILDA_SWITCH_MANAGER_REPLY_BOLT, ComponentType.NORTHBOUND_REPLY_BOLT, ComponentType.KILDA_NB_WORKER_REPLY_BOLT, ComponentType.SPEAKER_REQUEST_BOLT, RegionTrackerBolt.BOLT_ID, SwitchMonitorBolt.BOLT_ID));
declareBolt(topology, zooKeeperBolt, ZooKeeperBolt.BOLT_ID).allGrouping(SpeakerToNetworkProxyBolt.BOLT_ID, ZkStreams.ZK.toString()).allGrouping(ComponentType.SPEAKER_DISCO_REQUEST_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_FLOW_HS_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.SPEAKER_FLOW_REQUEST_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_PING_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_STATS_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_ISL_LATENCY_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_CONNECTED_DEVICES_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_SWITCH_MANAGER_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.NORTHBOUND_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.KILDA_NB_WORKER_REPLY_BOLT, ZkStreams.ZK.toString()).allGrouping(ComponentType.SPEAKER_REQUEST_BOLT, ZkStreams.ZK.toString()).allGrouping(RegionTrackerBolt.BOLT_ID, ZkStreams.ZK.toString()).allGrouping(SwitchMonitorBolt.BOLT_ID, ZkStreams.ZK.toString());
}
Aggregations