eolivelli opened a new pull request #9895: URL: https://github.com/apache/pulsar/pull/9895
Relates to #9844 ### Motivation Currently Schema#AUTO_CONSUME works only with GenericRecord, and makes it very difficult for users to deal with both Data Structures and primitive types because you have to know the type of data you are going to handle while creating the consumer or a Pulsar IO Sink. This change introduces a Schema.OBJECT() (ObjectSchema.java) that is like Schema.AUTO_CONSUME but it is able to deal with GenericRecord, primitive types like Strings and KeyValue. Currently KeyValue still does not work, due to another issue, that I am not going to address within this PR. Currently this Patch does not change Pulsar IO, but once we agree on this way it will be straightforward to implement support for Sink<Object> ### Modifications Add a new Schema.OBJECT() implementation, very like to Schema.AUTO_CONSUME() ### Verifying this change Adding only minimal unit tests, I will add more tests once we agree on the direction. ---------------------------------------------------------------- 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]
