steveloughran commented on PR #4766:
URL: https://github.com/apache/hadoop/pull/4766#issuecomment-1221329260

   as this draining code is used in prefetch too, i'm going to
   1. create a StreamDrainer class which the prefetch stream will also switch 
to; this code is fussy and I don't want duplicates
   2. have it implement CallableWithIOE so can be passed in to submit(); no 
need for an extra l-expression to invoke.
   
   the isolation lets me add unit tests for its failure cases
   
   * read returns -1 while data still remaining
   * read() throws ioe
   * remaining finishes while data remaining
   * abort failure


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