Search in sources :

Example 1 with FlowMirrorPointDeleteHubBolt

use of org.openkilda.wfm.topology.flowhs.bolts.FlowMirrorPointDeleteHubBolt in project open-kilda by telstra.

the class FlowHsTopology method flowDeleteMirrorPointHub.

private void flowDeleteMirrorPointHub(TopologyBuilder topologyBuilder, PersistenceManager persistenceManager) {
    int hubTimeout = (int) TimeUnit.SECONDS.toMillis(topologyConfig.getDeleteMirrorPointHubTimeoutSeconds());
    FlowMirrorPointDeleteConfig config = FlowMirrorPointDeleteConfig.flowMirrorPointDeleteBuilder().speakerCommandRetriesLimit(topologyConfig.getDeleteMirrorPointSpeakerCommandRetries()).autoAck(true).timeoutMs(hubTimeout).requestSenderComponent(ComponentId.FLOW_ROUTER_BOLT.name()).workerComponent(ComponentId.FLOW_DELETE_MIRROR_POINT_WORKER.name()).lifeCycleEventComponent(ZooKeeperSpout.SPOUT_ID).build();
    FlowResourcesConfig flowResourcesConfig = configurationProvider.getConfiguration(FlowResourcesConfig.class);
    FlowMirrorPointDeleteHubBolt hubBolt = new FlowMirrorPointDeleteHubBolt(config, persistenceManager, flowResourcesConfig);
    declareBolt(topologyBuilder, hubBolt, ComponentId.FLOW_DELETE_MIRROR_POINT_HUB.name()).fieldsGrouping(ComponentId.FLOW_ROUTER_BOLT.name(), ROUTER_TO_FLOW_DELETE_MIRROR_POINT_HUB.name(), FLOW_FIELD).directGrouping(ComponentId.FLOW_DELETE_MIRROR_POINT_WORKER.name(), Stream.SPEAKER_WORKER_TO_HUB_DELETE_MIRROR_POINT.name()).allGrouping(ZooKeeperSpout.SPOUT_ID).directGrouping(CoordinatorBolt.ID);
}
Also used : FlowResourcesConfig(org.openkilda.wfm.share.flow.resources.FlowResourcesConfig) FlowMirrorPointDeleteConfig(org.openkilda.wfm.topology.flowhs.bolts.FlowMirrorPointDeleteHubBolt.FlowMirrorPointDeleteConfig) FlowMirrorPointDeleteHubBolt(org.openkilda.wfm.topology.flowhs.bolts.FlowMirrorPointDeleteHubBolt)

Aggregations

FlowResourcesConfig (org.openkilda.wfm.share.flow.resources.FlowResourcesConfig)1 FlowMirrorPointDeleteHubBolt (org.openkilda.wfm.topology.flowhs.bolts.FlowMirrorPointDeleteHubBolt)1 FlowMirrorPointDeleteConfig (org.openkilda.wfm.topology.flowhs.bolts.FlowMirrorPointDeleteHubBolt.FlowMirrorPointDeleteConfig)1