What URL are you using?  Be precise.

Is AppServlet or SessionFilter using any async processing or async I/O? (if
so, you are missing DispatcherType.ASYNC, and also the asyncSupported flags)

What does SessionFilter do?

What happens if you exclude the Filter?

Also, why are you using a ContextHandler for static resources? (Use the
DefaultServlet)


--
Joakim Erdfelt <[email protected]>
webtide.com <http://www.webtide.com/> - intalio.com/jetty
Expert advice, services and support from from the Jetty & CometD experts
eclipse.org/jetty - cometd.org

On Fri, Dec 5, 2014 at 2:37 PM, Bryan Coleman <[email protected]>
wrote:

>  In short, I have an embedded jetty setup working with version
> 9.2.3.v20140905.  However, when I upgrade to version 9.2.4.v20141103 or
> 9.2.5.v20141112, the servlet is unreachable.
>
>
>
> I am running on linux using jdk 1.7.0_71.
>
>
>
> Here is my code:
>
>
>
>           server = new Server();
>
>
>
>             HttpConfiguration https = new HttpConfiguration();
>
>             https.addCustomizer(new SecureRequestCustomizer());
>
>
>
>             SslContextFactory ssl = new SslContextFactory();
>
>             ssl.setKeyStorePath(getKeyStorePath());
>
>             ssl.setKeyStoreType("JKS");
>
>             ssl.setKeyStorePassword("");
>
>             ssl.setKeyManagerPassword("");
>
>
>
>             ServerConnector connector = new ServerConnector(server, new
> SslConnectionFactory(ssl, HttpVersion.HTTP_1_1.toString()), new
> HttpConnectionFactory(https));
>
>             connector.setPort(port);
>
>             connector.setIdleTimeout(300000);
>
>
>
>             server.setConnectors(new Connector[]{connector});
>
>
>
>             HashSessionManager session_manager = new HashSessionManager();
>
>             session_manager.setMaxInactiveInterval(3600);
>
>             session_manager.addEventListener(new HttpSessionListener() {
>
>                 public void sessionCreated(HttpSessionEvent event) {
>
>                     // do something                }
>
>
>
>                 public void sessionDestroyed(HttpSessionEvent event) {
>
>                   // do something
>
>                 }
>
>             });
>
>
>
>             SessionHandler session_handler = new
> SessionHandler(session_manager);
>
>
>
>             ServletContextHandler context = new
> ServletContextHandler(ServletContextHandler.SESSIONS);
>
>             context.setHandler(session_handler);
>
>             context.addFilter(new FilterHolder(SessionFilter.class), "/*",
> EnumSet.of(DispatcherType.INCLUDE, DispatcherType.REQUEST));
>
>             context.setContextPath("/");
>
>             context.addServlet(new ServletHolder(new AppServlet()),
> "/Test/");
>
>
>
>             ContextHandler context_static = new ContextHandler();
>
>             context_static.setContextPath("/static");
>
>             context_static.setResourceBase(System.getProperty("user.dir")
> + File.separator + "static" + File.separator);
>
>             context_static.setHandler(new ResourceHandler());
>
>
>
>             ContextHandlerCollection contexts = new
> ContextHandlerCollection();
>
>             contexts.setHandlers(new Handler[]{context, context_static});
>
>             server.setHandler(contexts);
>
>
>
>             server.start();
>
>
>
>
>
> Any ideas?
>
> _______________________________________________
> 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
>
_______________________________________________
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

Reply via email to