pulsar-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [pulsar] jiazhai commented on a change in pull request #3843: Add a wrapper around Kafka's ProducerInterceptor to support Kafka's ProducerConfig.INTERCEPTOR_CLASSES_CONFIG. #1090
Date Sun, 17 Mar 2019 14:52:06 GMT
jiazhai commented on a change in pull request #3843: Add a wrapper around Kafka's ProducerInterceptor
to support Kafka's ProducerConfig.INTERCEPTOR_CLASSES_CONFIG. #1090
URL: https://github.com/apache/pulsar/pull/3843#discussion_r266243053
 
 

 ##########
 File path: pulsar-client-kafka-compat/pulsar-client-kafka/src/main/java/org/apache/kafka/clients/producer/PulsarKafkaProducer.java
 ##########
 @@ -157,6 +161,10 @@ private PulsarKafkaProducer(Map<String, Object> conf, Properties
properties, Ser
         // Kafka, on the other hand, still blocks for "max.block.ms" time and then gives
error.
         boolean shouldBlockPulsarProducer = sendTimeoutMillis > 0 || blockOnBufferFull;
         pulsarProducerBuilder.blockIfQueueFull(shouldBlockPulsarProducer);
+
+        interceptors = (List) producerConfig.getConfiguredInstances(
+                ProducerConfig.INTERCEPTOR_CLASSES_CONFIG, ProducerInterceptor.class);
+        //interceptorsClasses.forEach(interceptorClazz -> interceptors.add(createKafkaProducerInterceptor(interceptorClazz)));
 
 Review comment:
   remove this?

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

Mime
View raw message