- The Server delegates the request to the its configured handler, which is normally an instance of HandlerCollection.
- The HandlerCollection acts like Jetty 5, and calls each of it's contained handlers in turn. Typically it is configured with
a ContextHandlerCollection, a DefaultHandler and a RequestLogHandler. This allows a request to be handled by a context or the default handler, and then be passed to the request log handler.
- The ContextHandlerCollection
maintains a map of context path to lists of ContextHandlers. For a given request, each the URI is used to find matching context paths, and each is called in turn until the request is handled.
- If the ContextHandler accepts a request (it may reject it due to virtual hosts), it will delegate the request to a nested handler and for the duration of that call it will set:
- the request context path
- the current thread context classloader
- the resource base
- the error handler
- context attributes and init parameters.
- Typically the ContextHandler will be an instance of WebAppContext and will thus contain a nested chain of SessionHandler, SecurityHandler and ServletHandler. The request is delegated to the first handler in this chain, a SessionHandler
- The SessionHandler will examine the request for any session ID to be activated and will activate the mechanism for creating new sessions before delegating the request to the SecurityHandler.
- The SecurityHandler will check any constraints and authentication before delegating the request to the ServletHandler
- The ServletHandler implements the dispatch to Filters and Servlets to handle the request according to the servlet specification.
Servlet 2.5 and JSP 2.1
new package names.
loggingJetty 6 implements the 2.5 servlet specification. There is nothing revolutionary in this update of the API and mostly represents API cleanups and corrections. The upgrade to JSP 2.1 is slightly more significant as this requires JAVA 1.5 (hence jetty retains JSP 2.0 as an option).
Jetty 6 took the opportunity to clean up the package hirarchy and to remove some long deprecated methods.
DETAILS TO GO HERE
The pain that is commons logging has been removed and Jetty now has no hard dependency on any logging mechanism. If an SLF4J jar is found, it will be used, otherwise any logging is simply sent to stderr.
Build and packaging
Jetty 6 is built with maven, which has changed the way the jars are bundled.
- MORE DETAIL HERE *