Starting with 1.6.X, when a statement is closed, it has a result set and streaming is enabled, a kill command is sent out. That killed our application since we have a large scale application with hundreds of processes. cancelCurrentQuery creates a new connection and sends a kill command. If a new connection is created for every select, there are thousands of sockets left in TIMED_WAIT and the server cannot create new connections.
This should be done in a dedicated, pooled connection. In addition to that, the code should check if the result set was already consumed and skip kill since there will be nothing to do anyway. In this case, even if a new connection is done, it will be done in 0.01% of the cases where the app abourts the ResultSet.