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 2021/04/29 09:14:45 UTC

[GitHub] [pulsar] vroyer opened a new issue #10438: Add a Message.getSchema() in the client API

vroyer opened a new issue #10438:
URL: https://github.com/apache/pulsar/issues/10438


   When the schema is not known at compile time, a `Consumer<GenericObject>` should be able to get the message schema.
   
   Currently, a `Consumer<GenericRecord>` can get the AVRO message and retreive its schema, but if the message is a KeyValue for example, there is no way to get the actual Schema.
   
   The idea is to introduce a `CompletableFuture<Schema<?>> getSchema()` in the Message API, returning null by default.
   
   The implementation classes (MessageImpl, TopicMessageImpl) could then fetch the Schema if available, and eventually keep it cached as a class member.


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] codelipenghui closed issue #10438: Add a Message.getSchema() in the client API

Posted by GitBox <gi...@apache.org>.
codelipenghui closed issue #10438:
URL: https://github.com/apache/pulsar/issues/10438


   


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] eolivelli commented on issue #10438: Add a Message.getSchema() in the client API

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


   As discussed at the community meeting I am going to send a PIP


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] eolivelli commented on issue #10438: Add a Message.getSchema() in the client API

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


   This is the PIP
   https://docs.google.com/document/d/1VWi5LHP44V31nP4bCui9d5RXwH6xc_phrUes6tvNguk
   


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] codelipenghui commented on issue #10438: Add a Message.getSchema() in the client API

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


   https://github.com/apache/pulsar/pull/10476 is merged, so close this issue.


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] eolivelli commented on issue #10438: Add a Message.getSchema() in the client API

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


   @congbobo184 here https://github.com/apache/pulsar/pull/9970/files#diff-955419b4b0ad976e96f9f7595989e79c391109aeaa304bd286a80fc6eb9360c7R324 you are adding MessageImpl#getSchema() with CompletableFuture<Schema>
   
   but why can't we use directly the schema instance that is cached inside the Message ?


-- 
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:
users@infra.apache.org



[GitHub] [pulsar] eolivelli commented on issue #10438: Add a Message.getSchema() in the client API

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






-- 
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:
users@infra.apache.org