Module: Karafka::Processing::ConsumerGroups::Strategies::Base

Included in:
Karafka::Pro::Processing::ConsumerGroups::Strategies::Base, Default
Defined in:
lib/karafka/processing/consumer_groups/strategies/base.rb

Overview

Base strategy that should be included in each strategy, just to ensure the API

Instance Method Summary collapse

Instance Method Details

#handle_after_consumeObject

Post-consumption handling

Raises:

  • (NotImplementedError)


43
44
45
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 43

def handle_after_consume
  raise NotImplementedError, "Implement in a subclass"
end

#handle_before_consumeObject

What should happen before we kick in the processing

Raises:

  • (NotImplementedError)


33
34
35
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 33

def handle_before_consume
  raise NotImplementedError, "Implement in a subclass"
end

#handle_consumeObject

What should happen in the processing

Raises:

  • (NotImplementedError)


38
39
40
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 38

def handle_consume
  raise NotImplementedError, "Implement in a subclass"
end

#handle_idleObject

Idle run handling

Raises:

  • (NotImplementedError)


48
49
50
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 48

def handle_idle
  raise NotImplementedError, "Implement in a subclass"
end

#handle_revokedObject

Revocation handling

Raises:

  • (NotImplementedError)


53
54
55
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 53

def handle_revoked
  raise NotImplementedError, "Implement in a subclass"
end

#handle_shutdownObject

Shutdown handling

Raises:

  • (NotImplementedError)


58
59
60
# File 'lib/karafka/processing/consumer_groups/strategies/base.rb', line 58

def handle_shutdown
  raise NotImplementedError, "Implement in a subclass"
end