Sha256: e79e3596a639247b0b9823a1615ec6516c7de50251017b47ed6961319246d567

Contents?: true

Size: 771 Bytes

Versions: 75

Compression:

Stored size: 771 Bytes

Contents

# frozen_string_literal: true

module Karafka
  module Processing
    module Strategies
      # When using manual offset management, we do not mark as consumed after successful processing
      module Mom
        include Default

        # Apply strategy when only manual offset management is turned on
        FEATURES = %i[
          manual_offset_management
        ].freeze

        # When manual offset management is on, we do not mark anything as consumed automatically
        # and we rely on the user to figure things out
        def handle_after_consume
          return if revoked?

          if coordinator.success?
            coordinator.pause_tracker.reset
          else
            retry_after_pause
          end
        end
      end
    end
  end
end

Version data entries

75 entries across 75 versions & 1 rubygems

Version Path
karafka-2.4.17 lib/karafka/processing/strategies/mom.rb
karafka-2.4.16 lib/karafka/processing/strategies/mom.rb
karafka-2.4.15 lib/karafka/processing/strategies/mom.rb
karafka-2.4.14 lib/karafka/processing/strategies/mom.rb
karafka-2.4.13 lib/karafka/processing/strategies/mom.rb
karafka-2.4.12 lib/karafka/processing/strategies/mom.rb
karafka-2.4.11 lib/karafka/processing/strategies/mom.rb
karafka-2.4.10 lib/karafka/processing/strategies/mom.rb
karafka-2.4.9 lib/karafka/processing/strategies/mom.rb
karafka-2.4.8 lib/karafka/processing/strategies/mom.rb
karafka-2.4.7 lib/karafka/processing/strategies/mom.rb
karafka-2.4.6 lib/karafka/processing/strategies/mom.rb
karafka-2.4.5 lib/karafka/processing/strategies/mom.rb
karafka-2.4.4 lib/karafka/processing/strategies/mom.rb
karafka-2.4.3 lib/karafka/processing/strategies/mom.rb
karafka-2.4.0 lib/karafka/processing/strategies/mom.rb
karafka-2.4.0.rc1 lib/karafka/processing/strategies/mom.rb
karafka-2.3.4 lib/karafka/processing/strategies/mom.rb
karafka-2.4.0.beta2 lib/karafka/processing/strategies/mom.rb
karafka-2.4.0.beta1 lib/karafka/processing/strategies/mom.rb