cryptoe commented on code in PR #13974:
URL: https://github.com/apache/druid/pull/13974#discussion_r1147789654


##########
processing/src/main/java/org/apache/druid/frame/channel/ComposingWritableFrameChannel.java:
##########
@@ -118,14 +123,17 @@ public void close() throws IOException
   {
     if (currentIndex < writableChannelSuppliers.size()) {
       writableChannelSuppliers.get(currentIndex).get().close();
+      convertChannelSuppliersToReadOnly(currentIndex);
       currentIndex = writableChannelSuppliers.size();
     }
   }
 
   @Override
   public boolean isClosed()
   {
-    return currentIndex == writableChannelSuppliers.size();
+    return currentIndex == writableChannelSuppliers.size() || 
writableChannelSuppliers.get(currentIndex)

Review Comment:
   Since this class does not own the `WritableFrameChannel` which are passed by 
the suppliers, the passed channel might be closed, externally and hence this 
check . 



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to