You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/05/21 10:08:24 UTC

[GitHub] [pulsar] truong-hua opened a new issue, #15696: Java pulsar function can not subscribe to a non-defined schema topic

truong-hua opened a new issue, #15696:
URL: https://github.com/apache/pulsar/issues/15696

   **Describe the bug**
   I rewrite all of my current pulsar function from Python to Java and facing a problem that the new functions can not subscribe to topics with error logged from brokers:
   
   ```
   2022-05-21T10:02:55,288+0000 [pulsar-client-internal-26-1] WARN  org.apache.pulsar.client.impl.MultiTopicsConsumerImpl - Failed subscription for createPartitionedConsumer: persistent://public/ticdc/inbox-message 3, e:java.util.concurrent.CompletionException: org.apache.pulsar.client.api.PulsarClientException$IncompatibleSchemaException: {"errorMsg":"Topic does not have schema to check","reqId":4374172734813500123, "remote":"pulsar.s1.stag.doopage.com/10.0.4.103:6650", "local":"/10.0.4.187:34098"}
   ```
   
   While the python function is running well. My java functions is implementing `Function<String, Void>`.
   Our `isAllowAutoUpdateSchema` config is set to true (default value) and we have no any override in namespace or topic level.
   
   **To Reproduce**
   Steps to reproduce the behavior:
   1. Create new topic with no schema defined
   2. Create a new Java function to subscribe from the topic
   3. The function can not subscribe the topic with a lot of restart and the broker has logged the above error. Manually upload a schema to the topic will resolve the issue
   
   **Expected behavior**
   - According to the document, Pulsar should auto populate the schema https://pulsar.apache.org/docs/schema-manage/
   - Or the Java function should be able to work like the Python function. Or Pulsar sinks is working well while only Pulsar function has that problem.
   
   **Desktop (please complete the following information):**
    - Ubuntu 20
   
   **Additional context**
   Puslar 2.10.0
   


-- 
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: commits-unsubscribe@pulsar.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar] truong-hua commented on issue #15696: Java pulsar function can not subscribe to a non-defined schema topic

Posted by GitBox <gi...@apache.org>.
truong-hua commented on issue #15696:
URL: https://github.com/apache/pulsar/issues/15696#issuecomment-1183997396

   Sorry, this is my mistake, just define `Function<byte[], Void>`worker and it can consume any schema. If possible, it should be clearly describe in the document.


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar] lgxbslgx commented on issue #15696: Java pulsar function can not subscribe to a non-defined schema topic

Posted by GitBox <gi...@apache.org>.
lgxbslgx commented on issue #15696:
URL: https://github.com/apache/pulsar/issues/15696#issuecomment-1152628937

   > Steps to reproduce the behavior:
   > 
   > Create new topic with no schema defined
   > Create a new Java function to subscribe from the topic
   > The function can not subscribe the topic with a lot of restart and the broker has logged the above error. Manually upload a schema to the topic will resolve the issue
   
   @truong-hua I look into this issue and try to reproduce it. But the Java function runs successfully locally.
   Could you give more information to reproduce your issue? Such as the command you use and the source code you test.
   
   


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar] github-actions[bot] commented on issue #15696: Java pulsar function can not subscribe to a non-defined schema topic

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #15696:
URL: https://github.com/apache/pulsar/issues/15696#issuecomment-1179897325

   The issue had no activity for 30 days, mark with Stale label.


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar] truong-hua closed issue #15696: Java pulsar function can not subscribe to a non-defined schema topic

Posted by GitBox <gi...@apache.org>.
truong-hua closed issue #15696: Java pulsar function can not subscribe to a non-defined schema topic
URL: https://github.com/apache/pulsar/issues/15696


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org