Jetty Logo
Version: 9.2.3.v20140905
Contact the core Jetty developers at www.webtide.com

private support for your internal/customer projects ... custom extensions and distributions ... versioned snapshots for indefinite support ... scalability guidance for your apps and Ajax/Comet projects ... development services from 1 day to full product delivery

Jetty : The Definitive Reference

Revision History
Revision 9.2.3.v201409052014-10-24 01:00:17

This documentation is produced and contributed to under the EPL.


Table of Contents

I. Getting Started With Jetty
1. Introducing Jetty
What is Jetty?
What Version Do I Use?
Jetty and Java EE Web Profile
2. Using Jetty Introduction
Downloading Jetty
Running Jetty
Deploying Web Applications
Finding Jetty in Maven
3. Jetty Configuration Introduction
How to Configure Jetty
What to Configure in Jetty
II. Jetty Configuration
4. Deploying to Jetty
Anatomy of a Web Application
Automatic Web Application Deployment
Configuring a Specific Web Application Deployment
Deployment Processing of WebAppContexts
Configuring Static Content Deployment
Hot Deployment
Deployment Architecture
Quickstart Webapps
Overlay WebApp Deployer
5. Configuring Contexts
Setting a Context Path
Configuring Virtual Hosts
Temporary Directories
Serving a WebApp from a Particular Port/Connector
Creating Custom Error Pages
Setting Max Form Size
6. Configuring Jetty Connectors
Connector Configuration Overview
Configuring SSL
Setting Port 80 Access for a Non-Root User
7. Configuring Security
Jetty 9.1: Using the ${jetty.home} and ${jetty.base} Concepts to Configure Security
Authentication
Limiting Form Content
Aliased Files and Symbolic links
Secure Password Obfuscation
JAAS Support
Spnego Support
8. Configuring JSP Support
Configuring JSP
III. Jetty Administration Guide
9. Starting Jetty
Startup Overview
Managing Server Classpath
Managing Startup Modules
Managing Jetty Base and Jetty Home
Using start.jar
Startup a Unix Service using jetty.sh
Startup via Windows Service
10. Session Management
Setting Session Characteristics
Using Persistent Sessions
Session Clustering with a Database
Session Clustering with MongoDB
11. Configuring JNDI
Quick Setup
Working with Jetty JNDI
Configuring JNDI
Using JNDI with Jetty Embedded
Datasource Examples
12. Annotations
Quick Setup
Working with Annotations
Using Annotations with Jetty Embedded
13. JMX
Using Java Management Extensions (JMX)
Jetty JConsole
Jetty JMX Annotations
14. SPDY
Introducing SPDY
Configuring SPDY
Configuring SPDY Proxy
Configuring SPDY push
Implement a custom SPDY PushStrategy
15. ALPN
16. NPN
17. FastCGI Support
FastCGI Introduction
Configuring Jetty for FastCGI
18. Provided Servlets, Filters, and Handlers
Default Servlet
Proxy Servlet
Balancer Servlet
CGI Servlet
Quality of Service Filter
Denial of Service Filter
Gzip Filter
Cross Origin Filter
Resource Handler
Debug Handler
Statistics Handler
IP Access Handler
Moved Context Handler
Shutdown Handler
Default Handler
Error Handler
Rewrite Handler
19. Jetty Runner
Use Jetty without an installed distribution
20. Optimizing Jetty
Garbage Collection
High Load
Limiting Load
21. Jetty Logging
Configuring Jetty Logging
Default Logging with Jetty's StdErrLog
Configuring Jetty Request Logs
Example: Logging with Apache Log4j
Example: Logging with Java's java.util.logging via Slf4j
Example: Logging with Java's java.util.logging via JavaUtilLog
Example: Logging with Logback
Example: Capturing Multiple Logging Frameworks with Slf4j
Example: Centralized Logging with Logback
Jetty Dump Tool
IV. Jetty Development Guide
22. Maven and Jetty
Using Maven
Configuring the Jetty Maven Plugin
Files Scanned by the Jetty Maven Plugin
Jetty Jspc Maven Plugin
23. Using Ant with Jetty
Using the Ant Jetty Plugin
24. Handlers
Writing Custom Handlers
25. Embedding
Jetty Embedded HelloWorld
Embedding Jetty
Embedded Examples
26. Debugging
Options
Enable remote debugging
Debugging With Eclipse
Debugging With IntelliJ
27. Frameworks
Spring Setup
OSGI
Weld
Metro
28. HTTP Client
Introduction
API Usage
Other Features
29. WebSocket Introduction
What Jetty provides
WebSocket APIs
30. Jetty Websocket API
Jetty WebSocket API Usage
WebSocket Events
WebSocket Session
Send Messages to Remote Endpoint
Using WebSocket Annotations
Using WebSocketListener
Using the WebSocketAdapter
Jetty WebSocket Server API
Jetty WebSocket Client API
31. Java Websocket API
Java WebSocket Client API Usage
Java WebSocket Server API
V. Reference Guide
32. Platforms, Stacks and Alternative Distributions
Many many options...
Jelastic
CloudFoundry
Amazon Elastic Beanstalk
Fedora
Ubuntu
33. Architecture
Jetty Architecture
Jetty Classloading
Managing 1xx Responses
Creating a Custom Protocol
34. Contributing to Jetty
Community
Documentation
Source Control and Building
Coding Standards
Issues, Features, and Bugs
Contributing Patches
Releasing Jetty
Testing a Jetty Release
35. Reference Section
Jetty XML Syntax
Jetty XML Usage
jetty.xml
jetty-web.xml
jetty-env.xml
webdefault.xml
Jetty override-web.xml
36. Troubleshooting
Troubleshooting Zip Exceptions
Troubleshooting Locked Files on Windows
Preventing Memory Leaks
Jetty Security Reports

List of Tables

1.1. Jetty Versions
1.2. JavaEE7 Web Profile
1.3. Java EE 6 Web Profile
2.1. Contents
4.1. Default Configuration classes
4.2. JNDI Configuration classes
4.3. Annotation Configuration classes
6.1. Connector Configuration
8.1. Understanding Apache JspServlet Parameters
8.2. Understanding Glassfish JSP Parameters
10.1. Init Parameters
10.2. Default Values for Session Id Table
10.3. Default Values for Session Table
11.1. DataSource Declaration Conventions
15.1. ALPN vs. OpenJDK versions
16.1. NPN vs. OpenJDK versions
21.1. Slf4j Logging Grid
27.1. Bundle Name Mapping
27.2. Jars Required for JSP
27.3. Jars Required for Annotations
29.1. WebSocket connection states
33.1. Default System Classes
33.2. Default Server Classes
36.1. Resolved Issues

List of Examples

12.1. ServerWithAnnotations.java
Client Example.
Server Example.
Client Example.
Server Example.
25.1. FileServer.java
25.2. SplitFileServer.java
25.3. ManyConnectors.java
25.4. SpdyServer.java
25.5. SecuredHelloHandler.java
25.6. MinimalServlets.java
25.7. OneWebApp.java
25.8. OneWebAppWithJsp.java
30.1. Send Binary Message (Blocking)
30.2. Send Text Message (Blocking)
30.3. Send Partial Binary Message (Blocking)
30.4. Send Partial Text Message (Blocking)
30.5. Send Ping Control Frame (Blocking)
30.6. Send Pong Control Frame (Blocking)
30.7. Send Binary Message (Async Simple)
30.8. Send Binary Message (Async, Wait Till Success)
30.9. Send Binary Message (Async, timeout of send)
30.10. Send Text Message (Async Simple)
30.11. Send Text Message (Async, Wait Till Success)
30.12. Send Text Message (Async, timeout of send)
30.13. AnnotatedEchoSocket.java
30.14. ListenerEchoSocket.java
30.15. AdapterEchoSocket.java
30.16. MyEchoServlet.java
30.17. MyAdvancedEchoCreator.java
30.18. MyAdvancedEchoServlet.java
30.19. SimpleEchoClient.java
30.20. SimpleEchoSocket.java

See an error or something missing? Contribute to this documentation at Github!(Generated: 2014-10-24T01:00:41-07:00)