KannarFr opened a new issue, #15452: URL: https://github.com/apache/pulsar/issues/15452
**Describe the bug** allowAutoTopicCreation doesn't work **To Reproduce** 1. Download https://www.apache.org/dyn/mirrors/mirrors.cgi?action=download&filename=pulsar/pulsar-2.10.0/apache-pulsar-2.10.0-bin.tar.gz 2. Extract it 3. Run `bin/standalone -nfw` 4. Ensure that the `standalone.conf` `allowAutoTopicCreation=true` 5. Create a tenant `test` on `standalone` cluster ```bash pulsarctl --admin-service-url http://localhost:8080 tenants create test -c standalone ```` 7. Create a namespace `test/test` ```bash pulsarctl --admin-service-url http://localhost:8080 namespaces create test/test ```` 9. Try to create a producer on it and get ``` 14:11:51.571 [pulsar-client-io-1-1] ERROR org.apache.pulsar.client.impl.ProducerImpl - [test/test/test] [null] Failed to create producer: {"errorMsg":"Topic Not Found.","reqId":1977895818880687123, "remote":"localhost/127.0.0.1:6650", "local":"/127.0.0.1:46162"} Exception in thread "main" org.apache.pulsar.client.api.PulsarClientException$TopicDoesNotExistException: {"errorMsg":"Topic Not Found.","reqId":1977895818880687123, "remote":"localhost/127.0.0.1:6650", "local":"/127.0.0.1:46162"} at org.apache.pulsar.client.api.PulsarClientException.unwrap(PulsarClientException.java:1066) at org.apache.pulsar.client.impl.ProducerBuilderImpl.create(ProducerBuilderImpl.java:88) at com.clevercloud.PulsarProducer.main(PulsarProducer.java:83) ``` 10. Get the `test/test` policies and get ```bash pulsarctl --admin-service-url http://localhost:8080 namespaces policies test/test ```` ```json "autoTopicCreationOverride": { "allowAutoTopicCreation": false, "topicType": "", "defaultNumPartitions": 0 }, ``` 12. Try to change this using REST API because the --enable option is not available on pulsarctl namespaces set-auto-topic-creation and it doesn't work better. The auto topic creation only works using `partitioned topicType` with default partition > 0. It is quite weird because we can't have auto topic creation using `non-partitioned topics`. More the policies shows as auto topic creation is not authorized for this namespace while it should be inherited from broker/standalone config which is enabled. And default ns policies should have `null` so fallback to broker config key. **Expected behavior** really allowAutoTopicCreation -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
