wolfstudy opened a new issue #8239: URL: https://github.com/apache/pulsar/issues/8239
**Describe the bug** When allowAutoTopicCreationType is set to partitioned, the function trigger cannot work normally. The error as follows: ``` 13:41:15.112 [AsyncHttpClient-7-1] WARN org.apache.pulsar.client.admin.internal.FunctionsImpl - [http://localhost:8080/admin/v3/functions/public/default/example/trigger] Failed to perform http post request: javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error java.util.concurrent.ExecutionException: org.apache.pulsar.client.api.PulsarClientException: Topic reader cannot be created on a partitioned topic Reason: HTTP 500 Internal Server Error ``` The specific error location points to [here](https://github.com/apache/pulsar/blob/master/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PulsarClientImpl.java#L500) **To Reproduce** 1. bin/pulsar standalone(2.6.1) 2. bin/pulsar-admin functions create --function-config-file examples/example-function-config.yaml --jar examples/api-examples.jar examples/example-function-config.yaml: ``` tenant: "public" namespace: "default" name: "example" className: "org.apache.pulsar.functions.api.examples.ExclamationFunction" inputs: ["test_src"] userConfig: "PublishTopic": "test_result" output: "test_result" autoAck: true parallelism: 1 ``` 3. bin/pulsar-admin functions trigger --name example --trigger-value "hello admin pulsar" --topic test_src 4. See error ``` 13:41:15.112 [AsyncHttpClient-7-1] WARN org.apache.pulsar.client.admin.internal.FunctionsImpl - [http://localhost:8080/admin/v3/functions/public/default/example/trigger] Failed to perform http post request: javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error java.util.concurrent.ExecutionException: org.apache.pulsar.client.api.PulsarClientException: Topic reader cannot be created on a partitioned topic Reason: HTTP 500 Internal Server Error ``` **Expected behavior** When I set allowAutoTopicCreationType in standalone.conf to non-partitioned, the functions trigger can work normally. **Screenshots** If applicable, add screenshots to help explain your problem. **Desktop (please complete the following information):** - OS: Mac - Pulsar Broker: 2.6.1 - JDK: 1.8 ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected]
