Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delivery callback called with an invalid error when producing without ACL permissions #92

Closed
mensfeld opened this issue Oct 11, 2019 · 2 comments

Comments

@mensfeld
Copy link
Member

Version: current master

Reproduction:

config = {
    :'bootstrap.servers' => '127.0.0.1:9092',
    :'request.required.acks' => 1,
    :'sasl.mechanisms' => 'PLAIN',
    :'sasl.username' => 'edward',
    :'sasl.password' => 'edward',
    :'security.protocol' => 'sasl_plaintext',
    :'message.timeout.ms' => 100
  }
producer = Rdkafka::Config.new(config).producer
delivery_handles = []

100.times do |i|
  puts "Producing message #{i}"
  delivery_handles << producer.produce(
      topic:   "ruby-test-topic",
      payload: "Payload #{i}",
      key:     "Key #{i}"
  )
end

delivery_handles.each(&:wait)

Rdkafka::RdkafkaError (Local: Message timed out (msg_timed_out))

We never get a proper failure (something like authorization failed). Instead, we /librdkafka wait forever (till the message.timeout.ms).

This behavior can be really confusing as one would expect to get a clear error message indicating a lack of permissions.

ref karafka/waterdrop#108

@thijsc
Copy link
Collaborator

thijsc commented Feb 27, 2020

Has this been fixed by #86?

We don't use ACLs so don't have a test setup handy for it myself.

@thijsc
Copy link
Collaborator

thijsc commented Feb 28, 2021

Closing, feel free to reopen if this is still relevant.

@thijsc thijsc closed this as completed Feb 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants