Affects: \ 5.3.8


spring framework version 5.3.8

jetty version 10.0.5

jetty dependency

        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-server</artifactId>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-webapp</artifactId>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-servlet</artifactId>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty.websocket</groupId>
            <artifactId>websocket-jetty-server</artifactId>
        </dependency>

NoSuchMethodError when invoke JettyWebSocketSession.getRemoteAddress in jetty 10.

    @Override
    public InetSocketAddress getRemoteAddress() {
        checkNativeSessionInitialized();
        return getNativeSession().getRemoteAddress();
    }

in jetty 10 getNativeSession().getRemoteAddress(); return SocketAddress not InetSocketAddress so we should cast SocketAddress to InetSocketAddress the method should be

    @Override
    public InetSocketAddress getRemoteAddress() {
        checkNativeSessionInitialized();
        return (InetSocketAddress)getNativeSession().getRemoteAddress();
    }

Comment From: leonchen83

above also affect JettyWebSocketSession.getLocalAddress

Comment From: rstoyanchev

It's a binary incompatible change, so we'll also have to invoke that via reflection on Jetty 10.