zooo-code commented on code in PR #10577:
URL: https://github.com/apache/seatunnel/pull/10577#discussion_r2929896273


##########
seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/multitablesink/MultiTableSinkWriter.java:
##########
@@ -318,6 +424,20 @@ public void abortPrepare() {
         }
     }
 
+    /**
+     * Closes this writer and releases all resources.
+     *
+     * <p>Drains remaining queues, then calls {@link 
ExecutorService#shutdownNow()} to interrupt all
+     * consumer threads. Each sub-writer is closed under its respective {@link
+     * MultiTableWriterRunnable} lock to avoid concurrent access. Finally, the 
shared {@link
+     * MultiTableResourceManager} is closed.
+     *
+     * <p>Uses first-exception-wins error handling: if multiple sub-writers 
throw during close, only
+     * the first exception is propagated. Resource manager close errors are 
logged but not
+     * propagated.
+     *
+     * @throws IOException if any sub-writer fails to close
+     */

Review Comment:
   @dybyte  The implementation wraps exceptions in `RuntimeException`, not 
`IOException`.
   
   Updated `@throws` to document the actual thrown type and added a note about 
the mismatch with the inherited method signature.
   
   Thanks!



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