steveloughran commented on code in PR #5780:
URL: https://github.com/apache/hadoop/pull/5780#discussion_r1253062630


##########
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/services/AbfsOutputStream.java:
##########
@@ -493,6 +494,12 @@ public synchronized void close() throws IOException {
     }
 
     try {
+      // Check if Executor Service got shutdown before the writes could be
+      // completed.
+      if (hasActiveBlockDataToUpload() && executorService.isShutdown()) {
+        throw new IOException("Executor Service closed before writes could be"

Review Comment:
   throw a PathIOException with the output stream path; gives better 
diagnostics about what failed to be written. whoever fields support calls will 
appreciate this. I think L515 needs the same treatment.
   
   now, when this is thrown there's no need to catch and wrap it as it is not 
from flushInternal, so need a way to avoid this. maybe add some boolean on L495 
"exceptionCreated", which, if true, allows you to throw the exception on L509 
without wrapping.



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