Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Use BaseRichBolt or BaseBasicBolt in case of at-most-once processing

Tags:

apache-storm

I'm beginner in Storm and I would like to know whether I should use BaseRichBolt or BaseBasicBolt if at-most-once processing is good for me?

As I understand in case of BaseBasicBolt tuples are automatically anchored and acknowledged and in case of BaseRichBolt we have to do that ourselves. Does that mean that I should use BaseRichBolt if I want at-most-once processing?

My logic is that anchoring and acking will unnecessary make things slower, am I right?

like image 559
Kobe-Wan Kenobi Avatar asked Sep 26 '22 14:09

Kobe-Wan Kenobi


1 Answers

In order to enable fault-tolerance in Storm, it is required that Spouts assign message IDs to the tuples they emit. As long as there are no message IDs assigned, acking and anchoring will have no effect.

Thus, the overhead that BaseBasicBolt has is tiny and you should not be able to measure any performance difference. Of course, using BaseRichBolt will avoid this tiny overhead at all.

like image 165
Matthias J. Sax Avatar answered Nov 05 '22 08:11

Matthias J. Sax