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 2019/09/13 15:51:08 UTC

[GitHub] [pulsar] sijie commented on a change in pull request #5165: [PIP-43] Support producer to send msg with different schema

sijie commented on a change in pull request #5165: [PIP-43] Support producer to send msg with different schema
URL: https://github.com/apache/pulsar/pull/5165#discussion_r324255217
 
 

 ##########
 File path: pulsar-client-api/src/main/java/org/apache/pulsar/client/api/ProducerBuilder.java
 ##########
 @@ -434,4 +434,18 @@
      * @return the producer builder instance
      */
     ProducerBuilder<T> autoUpdatePartitions(boolean autoUpdate);
+
+    /**
+     * Option to control whether enable multiple schema mode,
+     * which would be enabled automatically if this feature is touched by default.
+     * If enabled, producer can send a message with different schema from that specified just when it is created,
+     * otherwise a invalid message exception would be threw if the producer want to send a message
+     * with different schema.
+     *
+     * @param switchOption
+     *            indicates to enable, disable, or automatically enable multiple schema mode
+     * @return the producer builder instance
+     * @since 2.5.0
+     */
+    ProducerBuilder<T> withMultiSchema(SwitchOption switchOption);
 
 Review comment:
   `SwitchOption` is an unclear name. I would suggest using something more specific. for example, 'MultiSchemaProduceMode'.

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


With regards,
Apache Git Services