lib/karafka/web/tracking/consumers/reporter.rb in karafka-web-0.7.8 vs lib/karafka/web/tracking/consumers/reporter.rb in karafka-web-0.7.9
- old
+ new
@@ -133,12 +133,12 @@
# for the delivery, hence will slow things down a little bit. On the other hand during
# normal operations we should not have that many messages to dispatch and it should not
# slowdown any processing.
def produce(messages)
if messages.count >= PRODUCE_SYNC_THRESHOLD
- ::Karafka.producer.produce_many_sync(messages)
+ ::Karafka::Web.producer.produce_many_sync(messages)
else
- ::Karafka.producer.produce_many_async(messages)
+ ::Karafka::Web.producer.produce_many_async(messages)
end
# Since we run this in a background thread, there may be a case upon shutdown, where the
# producer is closed right before a potential dispatch. It is not worth dealing with this
# and we can just safely ignore this
rescue WaterDrop::Errors::ProducerClosedError