Class: Karafka::Pro::Processing::Jobs::ConsumeNonBlocking
- Inherits:
-
Karafka::Processing::Jobs::Consume
- Object
- Karafka::Processing::Jobs::Base
- Karafka::Processing::Jobs::Consume
- Karafka::Pro::Processing::Jobs::ConsumeNonBlocking
- Defined in:
- lib/karafka/pro/processing/jobs/consume_non_blocking.rb
Overview
Note:
It needs to be working with a proper consumer that will handle the partition management. This layer of the framework knows nothing about Kafka messages consumption.
The main job type in a non-blocking variant. This variant works “like” the regular consumption but does not block the queue.
It can be useful when having long lasting jobs that would exceed ‘max.poll.interval` if would block.
Instance Attribute Summary
Attributes inherited from Karafka::Processing::Jobs::Consume
Attributes inherited from Karafka::Processing::Jobs::Base
Instance Method Summary collapse
-
#initialize(*args) ⇒ ConsumeNonBlocking
constructor
Makes this job non-blocking from the start.
Methods inherited from Karafka::Processing::Jobs::Consume
#after_call, #before_call, #before_schedule, #call
Methods inherited from Karafka::Processing::Jobs::Base
#after_call, #before_call, #before_schedule, #call, #finish!, #finished?, #non_blocking?
Constructor Details
#initialize(*args) ⇒ ConsumeNonBlocking
Makes this job non-blocking from the start
31 32 33 34 |
# File 'lib/karafka/pro/processing/jobs/consume_non_blocking.rb', line 31 def initialize(*args) super @non_blocking = true end |