failed to get Partitioned metadata : authorization failed

Viewed 579

I'm seeing this exception in my app when trying to interact with my Pulsar topic:

"message":"[persistent://exampleTenant/example-app-consumer/example-app-REPLAY] failed to get Partitioned metadata : Authorization failed feeds_exampleTenant_example-app-consumer on topic persistent://exampleTenant/example-app-consumer/example-app-REPLAY with error Don't have permission to administrate resources on this tenant"

I've verified:

  • The endpoint is correct (so I'm hitting the right cluster)
  • The port is correct (I'm hitting SSL, not the non-SSL port)
  • My token is correct.
  • My role and token are correct for interacting with my primary topic

What could be the issue?

1 Answers

This exception occurs when your role lacks the required permission. You either need the appropriate permission (consume, produce, or both) to be granted to your role for this additional topic you're accessing, or you will need a new role with a new token to be issued.

In the case that you're using a replay topic or a dead letter queue (DLQ) topic, you will need to ensure that you have adequate permission for interacting with those topics (whichever are applicable.) Since permissions in Pulsar are managed at the namespace level, if you expect to have permission, you need to check that your tenant and namespace were provided correctly.

Related