Database Reference
In-Depth Information
try {
//splitting the event based on semicolon
String[] eventTokens = event.split(",");
duration = Long.parseLong(eventTokens[4]);
callId = Long.parseLong(eventTokens[0]);
logger.debug(" Event (callId = {}) is a Zero
duration Qualifier ", callId);
collector.emit(....);
} catch (Exception e) {
logger.error("Corrupt Stopped record. Error
occurred while parsing the event : {}", event);
}
}
/**
* Declares output fields in tuple emitted from this bolt
*/
@Override
public void declareOutputFields(OutputFieldsDeclarer
declarer) {
declarer.declareStream(CALL_END, new Fields());
}
@
Override
public Map < String, Object > getComponentConfiguration()
{
return null;
}
}
The next step is to conjugate the Esper bolt into the topology. This can be easily down-
loaded as a bundle from https://github.com/tomdz/storm-esper , and it can be quickly
bundled into the topology using the following code:
Search WWH ::




Custom Search