Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-7633

Kafka Connect requires permission to create internal topics even if they exist

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.1.0
    • Fix Version/s: 2.0.2, 2.1.2, 2.2.1
    • Component/s: KafkaConnect
    • Labels:
      None

      Description

      Similar to issue https://issues.apache.org/jira/browse/KAFKA-6250 but now with a different exception.

      Error is:

      018-11-13 16:14:10,283 [DistributedHerder] ERROR o.a.k.c.r.d.DistributedHerder - Uncaught exception in herder work thread, exiting:
      org.apache.kafka.connect.errors.ConnectException: Error while attempting to create/find topic(s) 'connect-offsets'
              at org.apache.kafka.connect.util.TopicAdmin.createTopics(TopicAdmin.java:255)
              at org.apache.kafka.connect.storage.KafkaOffsetBackingStore$1.run(KafkaOffsetBackingStore.java:100)
              at org.apache.kafka.connect.util.KafkaBasedLog.start(KafkaBasedLog.java:126)
              at org.apache.kafka.connect.storage.KafkaOffsetBackingStore.start(KafkaOffsetBackingStore.java:110)
              at org.apache.kafka.connect.runtime.Worker.start(Worker.java:144)
              at org.apache.kafka.connect.runtime.AbstractHerder.startServices(AbstractHerder.java:108)
              at org.apache.kafka.connect.runtime.distributed.DistributedHerder.run(DistributedHerder.java:211)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
              at java.util.concurrent.FutureTask.run(FutureTask.java:266)
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
              at java.lang.Thread.run(Thread.java:745)
      Caused by: java.util.concurrent.ExecutionException: org.apache.kafka.common.errors.TopicAuthorizationException: Not authorized to access topics: [Topic authorization failed.]
              at org.apache.kafka.common.internals.KafkaFutureImpl.wrapAndThrow(KafkaFutureImpl.java:45)
              at org.apache.kafka.common.internals.KafkaFutureImpl.access$000(KafkaFutureImpl.java:32)
              at org.apache.kafka.common.internals.KafkaFutureImpl$SingleWaiter.await(KafkaFutureImpl.java:89)
              at org.apache.kafka.common.internals.KafkaFutureImpl.get(KafkaFutureImpl.java:258)
              at org.apache.kafka.connect.util.TopicAdmin.createTopics(TopicAdmin.java:228)
              ... 11 common frames omitted
      Caused by: org.apache.kafka.common.errors.TopicAuthorizationException: Not authorized to access topics: [Topic authorization failed.]
      

      Kafka 2.0 uses TOPIC_AUTHORIZATION_FAILED(29) as a response code now in the CreateTopicsResponse class whereas it used CLUSTER_AUTHORIZATION_FAILED(31) in Kafka 1.1 for example

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                arabelle Arabelle Hou
              • Votes:
                3 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: