jetty.project icon indicating copy to clipboard operation
jetty.project copied to clipboard

Improve exception message in ManagedSelector

Open rushalias opened this issue 4 years ago • 1 comments

Jetty version(s) 9.4.42.v20210604

Java version/vendor (use: java -version) openjdk 11.0.11 2021-04-20 LTS OpenJDK Runtime Environment Corretto-11.0.11.9.1 (build 11.0.11+9-LTS) OpenJDK 64-Bit Server VM Corretto-11.0.11.9.1 (build 11.0.11+9-LTS, mixed mode)

OS type/version In Kubernetes Ubuntu 20 in userland container Ubuntu 18 in kernel

Description The message in the thrown exception is not accurate, there is no timeout involved. The exception is thrown if an attempt is made to use a SocketChannel that is in a pending state. See: https://github.com/eclipse/jetty.project/blob/jetty-9.4.x/jetty-io/src/main/java/org/eclipse/jetty/io/ManagedSelector.java#L948-L957

        @Override
        public void run()
        {
            if (_selectorManager.isConnectionPending(channel))
            {
                if (LOG.isDebugEnabled())
                    LOG.debug("Channel {} timed out while connecting, closing it", channel);
                failed(new SocketTimeoutException("Connect Timeout"));
            }
        }

How to reproduce? for reference: https://www.eclipse.org/lists/jetty-users/msg09911.html

rushalias avatar Jun 20 '21 20:06 rushalias

This issue has been automatically marked as stale because it has been a full year without activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jul 01 '22 00:07 github-actions[bot]

This issue has been automatically marked as stale because it has been a full year without activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jul 03 '23 00:07 github-actions[bot]