Database Reference
In-Depth Information
=
bindings.get(input.getSourceGlobalStreamid());
if (bound != null && bound.size() > 0) {
for (FilterBinding b : bound) {
if (b.filter.regexp.matcher(
input.getString(b.fieldNdx)
).matches()) {
collector.emit(b.filter.stream,
input.select(b.filter.fields));
}
}
}
collector.ack(input);
}
Basic Bolts
If a bolt meets certain criteria it may also be implemented as a BasicBolt ,
which removes some of the boilerplate involved in implementing a
RichBolt . The BasicBolt implementation does not have a prepare step.
Itisassumedthattheonlynonserializedconfigurationrequiredistocapture
the collector object.
A BasicBolt also assumes that all tuples will be acknowledged using ack .
This is implemented fairly deep in the Storm code, rather than being part of
the BasicOutputCollector implementation.
Search WWH ::




Custom Search