belugabehr edited a comment on pull request #1029:
URL: https://github.com/apache/hive/pull/1029#issuecomment-638240582


   As I understand it, the code calling the JDBC Driver captures and handles 
the OOM error and then closes the JDBC Driver.  When it closes, it throws 
another error " CloseOperation failed: out of sequence response".  You would 
like for the close to be silent here.  Is that correct?
   
   If so, there's not a ton that can be done here (other than perhaps wrap the 
OOM error in a Thrift Exception).
   
   In this particular case, Thrift client is reading the size of the string off 
the wire, then trying to create a buffer large enough to read the string.  This 
is where it fails.  When it fails here, it loses its place in the stream.  The 
data is still in the stream, but the size is lost since that was read before 
the OOM error and there is no way to push the size back into the stream.  At 
this point, Thrift client is hosed and it can't read anything else.
   
   When the JDBC Driver is closed, it sends a "close" request to HS2 to 
gracefully shutdown the connection.  However, it is unable to read the response 
properly because, again, it lost its place and does not know how to find the 
next message.  I'm not sure what the fix is here, but I don't think this is it.


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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to