Sha256: 29b78fda164636950f6ef65120b6046e07def42d604876d9069069fc9f019c63
Contents?: true
Size: 880 Bytes
Versions: 5
Compression:
Stored size: 880 Bytes
Contents
module Racecar class Consumer Subscription = Struct.new(:topic, :start_from_beginning, :max_bytes_per_partition) class << self attr_accessor :max_wait_time attr_accessor :group_id def subscriptions @subscriptions ||= [] end # Adds one or more topic subscriptions. # # start_from_beginning - whether to start from the beginning or the end of each # partition. # max_bytes_per_partition - the maximum number of bytes to fetch from each partition # at a time. def subscribes_to(*topics, start_from_beginning: true, max_bytes_per_partition: 1048576) topics.each do |topic| subscriptions << Subscription.new(topic, start_from_beginning, max_bytes_per_partition) end end end def teardown; end end end
Version data entries
5 entries across 5 versions & 1 rubygems