use of org.openkilda.wfm.UnsupportedActionException in project open-kilda by telstra.
the class CtrlAction method handle.
@Override
protected void handle() throws MessageFormatException, UnsupportedActionException {
String source = getTuple().getSourceComponent();
if (!source.equals(AbstractTopology.BOLT_ID_CTRL_ROUTE)) {
return;
}
isHandled = true;
AbstractAction action;
RouteMessage message = new RouteMessage(getTuple());
RequestData payload = message.getPayload();
switch(payload.getAction()) {
case "list":
action = new ListAction(this, message);
break;
case "dump":
action = new DumpStateAction(this, message);
break;
case "clearState":
action = new ClearStateAction(this, message);
break;
default:
throw new UnsupportedActionException(payload.getAction());
}
action.run();
}
Aggregations