arnoldwakim opened a new pull request, #615:
URL: https://github.com/apache/arrow-go/pull/615

   ### Rationale for this change
   
   `StreamChunksFromReader` previously did not observe context cancellation. As 
a result, if a client disconnected early, the reader could continue producing 
data indefinitely, potentially blocking on channel sends, leaking `RecordBatch` 
objects, leaking the reader, and consuming unbounded memory and CPU (this 
observation triggered this PR).
   
   This fix ensures that data streaming promptly stops when the client 
disconnects.
   
   ### What changes are included in this PR?
   
   - `StreamChunksFromReader` now accepts a `context.Context`.
   - Tiny change was made to `DoGet`, to ensure it continues to work with the 
context-aware `StreamChunksFromReader`.
   
   ### Are these changes tested?
   
   - To be removed from description: the tests are bit tricky to write, similar 
to that of #437. Maybe @zeroshade has suggestions?
   
   ### Are there any user-facing changes?
   
   - `StreamChunksFromReader` now accepts a `context.Context`. 


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