Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.11
-
Fixed logging non-informative ClosedChannelException
-
Release Notes Required
Description
After fixing IGNITE-15367 calling GridNioServer$AbstractNioClientWorker.closekey(SelectionKey key) would produce excessive java.nio.channels.ClosedChannelException because sock.shutdownInput() and sock.shutdownInput() would be called twice:
// GridNioServer$AbstractNioClientWorker private void closeKey(SelectionKey key) { // Shutdown input and output so that remote client will see correct socket close. Socket sock = ((SocketChannel)key.channel()).socket(); try { try { sock.shutdownInput(); // <-- First time } catch (IOException ignored) { // No-op. } try { sock.shutdownOutput(); // <-- First time } catch (IOException ignored) { // No-op. } } finally { U.close(key, log); // <-- Second time U.close(sock, log); // <-- Second time } }
Attachments
Issue Links
- links to