You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@eventmesh.apache.org by "Pil0tXia (via GitHub)" <gi...@apache.org> on 2024/04/23 05:03:27 UTC
Re: [PR] [ISSUE #3861] Not yet make full use of Polymorphism in Producer and AbstractProducer (eventmesh)
Pil0tXia commented on code in PR #3867:
URL: https://github.com/apache/eventmesh/pull/3867#discussion_r1575643937
##########
eventmesh-storage-plugin/eventmesh-storage-kafka/src/main/java/org/apache/eventmesh/storage/kafka/producer/ProducerImpl.java:
##########
@@ -42,36 +41,20 @@
@Slf4j
@SuppressWarnings("deprecation")
-public class ProducerImpl {
+public class ProducerImpl extends AbstractProducer {
private final KafkaProducer<String, CloudEvent> producer;
- private final Properties properties = new Properties();
- private final AtomicBoolean isStarted = new AtomicBoolean(false);
public ProducerImpl(Properties props) {
+ super(props);
+ properties.clear();
Review Comment:
Excuse me but I still don't understand that why Kafka needs a `clear()` statement here but RocketMQ and Pulsar don't.
--
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.
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org