use of org.openkilda.messaging.AliveRequest in project open-kilda by telstra.
the class RecordHandler method handleCommand.
@VisibleForTesting
void handleCommand(CommandMessage message) {
logger.debug("Handling message: '{}'.", message);
CommandData data = message.getData();
if (data instanceof DiscoverIslCommandData) {
doDiscoverIslCommand((DiscoverIslCommandData) data, message.getCorrelationId());
} else if (data instanceof DiscoverPathCommandData) {
doDiscoverPathCommand(data);
} else if (data instanceof RemoveFlowForSwitchManagerRequest) {
doDeleteFlowForSwitchManager(message);
} else if (data instanceof ModifyFlowMeterForSwitchManagerRequest) {
doModifyFlowMeterForSwitchManager(message);
} else if (data instanceof ModifyDefaultMeterForSwitchManagerRequest) {
doModifyDefaultMeterForSwitchManager(message);
} else if (data instanceof ReinstallDefaultFlowForSwitchManagerRequest) {
doReinstallDefaultFlowForSwitchManager(message);
} else if (data instanceof NetworkCommandData) {
doNetworkDump((NetworkCommandData) data);
} else if (data instanceof SwitchRulesDeleteRequest) {
doDeleteSwitchRules(message);
} else if (data instanceof SwitchRulesInstallRequest) {
doInstallSwitchRules(message);
} else if (data instanceof DumpRulesForFlowHsRequest) {
doDumpRulesForFlowHsRequest(message);
} else if (data instanceof DumpRulesRequest) {
doDumpRulesRequest(message);
} else if (data instanceof DumpRulesForSwitchManagerRequest) {
doDumpRulesForSwitchManagerRequest(message);
} else if (data instanceof InstallFlowForSwitchManagerRequest) {
doInstallFlowForSwitchManager(message);
} else if (data instanceof DeleterMeterForSwitchManagerRequest) {
doDeleteMeter(message, context.getKafkaSwitchManagerTopic());
} else if (data instanceof DeleteMeterRequest) {
doDeleteMeter(message, context.getKafkaNorthboundTopic());
} else if (data instanceof PortConfigurationRequest) {
doConfigurePort(message);
} else if (data instanceof DumpSwitchPortsDescriptionRequest) {
doDumpSwitchPortsDescriptionRequest(message);
} else if (data instanceof DumpPortDescriptionRequest) {
doDumpPortDescriptionRequest(message);
} else if (data instanceof DumpMetersRequest) {
doDumpMetersRequest(message);
} else if (data instanceof DumpMetersForSwitchManagerRequest) {
doDumpMetersForSwitchManagerRequest(message);
} else if (data instanceof DumpMetersForFlowHsRequest) {
doDumpMetersForFlowHsRequest(message);
} else if (data instanceof MeterModifyCommandRequest) {
doModifyMeterRequest(message);
} else if (data instanceof AliveRequest) {
doAliveRequest(message);
} else if (data instanceof InstallIslDefaultRulesCommand) {
doInstallIslDefaultRule(message);
} else if (data instanceof RemoveIslDefaultRulesCommand) {
doRemoveIslDefaultRule(message);
} else if (data instanceof DumpGroupsForSwitchManagerRequest) {
doDumpGroupsForSwitchManagerRequest(message);
} else if (data instanceof DumpGroupsForFlowHsRequest) {
doDumpGroupsForFlowHsRequest(message);
} else if (data instanceof InstallGroupRequest) {
doInstallGroupRequest(message);
} else if (data instanceof ModifyGroupRequest) {
doModifyGroupRequest(message);
} else if (data instanceof DeleteGroupRequest) {
doDeleteGroupRequest(message);
} else if (data instanceof BroadcastWrapper) {
handleBroadcastCommand(message, (BroadcastWrapper) data);
} else {
handlerNotFound(data);
}
}
use of org.openkilda.messaging.AliveRequest in project open-kilda by telstra.
the class RegionTrackerBolt method emitSpeakerAliveRequest.
// SwitchStatusCarrier implementation
@Override
public void emitSpeakerAliveRequest(String region) {
AliveRequest request = new AliveRequest();
CommandMessage message = new CommandMessage(request, System.currentTimeMillis(), getCommandContext().fork(String.format("alive-request(%s)", region)).getCorrelationId());
getOutput().emit(STREAM_SPEAKER_ID, getCurrentTuple(), makeSpeakerTuple(null, message, region));
}
Aggregations