varkey98 commented on code in PR #355:
URL: 
https://github.com/apache/flink-connector-kafka/pull/355#discussion_r4703384768


##########
flink-connector-kafka/src/main/java/org/apache/flink/connector/kafka/sink/KafkaWriter.java:
##########
@@ -201,7 +207,7 @@ public List<KafkaWriterState> snapshotState(long 
checkpointId) throws IOExceptio
     public void close() throws Exception {
         markClosed();
         LOG.debug("Closing writer with {}", currentProducer);
-        closeAll(currentProducer);
+        closeAll(currentProducer, recordSerializer::close);

Review Comment:
   Thanks, makes sense, updated it to throw the existing failure and add the 
exception while closing as a suppressed one alongside it, or throw just the 
serializer close exception if there are no produce related exceptions currently



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to