merlimat commented on a change in pull request #3904: [go schema] support go 
schema for pulsar-client-go
URL: https://github.com/apache/pulsar/pull/3904#discussion_r273303793
 
 

 ##########
 File path: pulsar-client-go/pulsar/producer.go
 ##########
 @@ -125,6 +125,12 @@ type ProducerOptions struct {
        // release in order to be able to receive messages compressed with ZSTD.
        CompressionType
 
+       // Declare the schema of the data that this consumer will be accepting.
+       //
+       // The schema will be checked against the schema of the topic, and the
+       // consumer creation will fail if it's not compatible.
+       SchemaInfo
 
 Review comment:
   Actually, `SchemaInfo` it's just a part of whole equation. It represents the 
schema definition, but, in this case since it's struct it doesn't have any 
behavior associated.
   
   When creating a producer/consumer we should pass a "Schema" interface, that 
will encapsulate both the serde and will be able to provide a schemainfo.
   
   

----------------------------------------------------------------
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]


With regards,
Apache Git Services

Reply via email to