Thank you, Simone - On Thu, Jun 23, 2016 at 4:02 PM, Simone Bordet <[email protected]> wrote:
> > The server shows a NPE that is the root cause of your issue. > > Your server-side code is wrong at line 40, where you specify the > SslConnectionFactory, you tell it that the next protocol is HTTP/1.1, > but then you don't add the HttpConnectionFactory. > > Please look at > https://github.com/eclipse/jetty.project/blob/jetty-9.3.10.v20160621/examples/embedded/src/main/java/org/eclipse/jetty/embedded/LikeJettyXml.java#L160 > do I need to add ServerConnector sslConnector = new ServerConnector(server, new SslConnectionFactory(sslContextFactory,HttpVersion.HTTP_1_1.asString()), new HttpConnectionFactory(https_config)); even if I intend my embedding Jetty program to serve WebSocket connections only? My background is that I am developing a word game and have purchased Thawte SSL certificate for 2 domains: "example.com" and "www.example.com". On example.com ports 80 and 443 Apache+WordPress is running and serves HTML5 canvas with the game. On www.example.com (different IP address!) ports 80 and 443 I am trying to run embedded Jetty which would answer WebSocket requests. If a player would ever manually enter "www.example.com" into her browser, I would like Jetty to rewrite the URL to "example.com" and redirect. So would I need new HttpConnectionFactory(https_config) here? Or would I have to use the RewriteHandler for that like in https://github.com/eclipse/jetty.project/blob/jetty-9.3.10.v20160621/examples/embedded/src/main/java/org/eclipse/jetty/embedded/LikeJettyXml.java#L200 Thank you for any insights Alex
_______________________________________________ jetty-users mailing list [email protected] To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/jetty-users
