459655 - Remove SPDY and NPN.

Cleanup of javadocs, comments, XML and other text files.
This commit is contained in:
Simone Bordet 2015-02-11 16:18:07 +01:00
parent e19ed33341
commit be860741d5
21 changed files with 63 additions and 105 deletions

View File

@ -4,7 +4,13 @@ Thanks for your interest in this project.
Project description
--------------------
Jetty is a lightweight highly scalable java based web server and servlet engine. Our goal is to support web protocols like HTTP, HTTP/2, SPDY, and WebSocket in a high volume low latency way that provides maximum performance while retaining the ease of use and compatibility with years of servlet development. Jetty is a modern fully async web server that has a long history as a component oriented technology easily embedded into applications while still offering a solid traditional distribution for webapp deployment.
Jetty is a lightweight highly scalable java based web server and servlet engine.
Our goal is to support web protocols like HTTP, HTTP/2, and WebSocket in a high
volume low latency way that provides maximum performance while retaining the ease
of use and compatibility with years of servlet development.
Jetty is a modern fully async web server that has a long history as a component
oriented technology easily embedded into applications while still offering a solid
traditional distribution for webapp deployment.
- [https://projects.eclipse.org/projects/rt.jetty](https://projects.eclipse.org/projects/rt.jetty)
@ -14,7 +20,10 @@ Information regarding source code management, builds, coding standards, and more
- [https://www.eclipse.org/jetty/documentation/current/advanced-contributing.html](https://www.eclipse.org/jetty/documentation/current/advanced-contributing.html)
The canonical Jetty git repository is located at git.eclipse.org and we are unable to directly merge pull requests into the GitHub mirrored repository. Providing you have completed the contributors agreement mentioned below we will endeavor to pull your commit into Jetty proper.
The canonical Jetty git repository is located at git.eclipse.org and we are unable
to directly merge pull requests into the GitHub mirrored repository.
Providing you have completed the contributors agreement mentioned below we will
endeavor to pull your commit into Jetty proper.
Contributor License Agreement
------------------------------

View File

@ -1,7 +1,13 @@
Project description
============
Jetty is a lightweight highly scalable java based web server and servlet engine. Our goal is to support web protocols like HTTP, HTTP/2, SPDY, and WebSocket in a high volume low latency way that provides maximum performance while retaining the ease of use and compatibility with years of servlet development. Jetty is a modern fully async web server that has a long history as a component oriented technology easily embedded into applications while still offering a solid traditional distribution for webapp deployment.
Jetty is a lightweight highly scalable java based web server and servlet engine.
Our goal is to support web protocols like HTTP, HTTP/2 and WebSocket in a high
volume low latency way that provides maximum performance while retaining the ease
of use and compatibility with years of servlet development. Jetty is a modern
fully async web server that has a long history as a component oriented technology
easily embedded into applications while still offering a solid traditional
distribution for webapp deployment.
- [https://projects.eclipse.org/projects/rt.jetty](https://projects.eclipse.org/projects/rt.jetty)

View File

@ -22,7 +22,6 @@ package org.eclipse.jetty.embedded;
import java.io.IOException;
import java.util.Date;
import java.util.EnumSet;
import javax.servlet.DispatcherType;
import javax.servlet.Filter;
import javax.servlet.FilterChain;
@ -79,12 +78,12 @@ public class Http2Server
http_config.setSendXPoweredBy(true);
http_config.setSendServerVersion(true);
// HTTP connector
// HTTP Connector
ServerConnector http = new ServerConnector(server,new HttpConnectionFactory(http_config));
http.setPort(8080);
server.addConnector(http);
// SSL Context Factory for HTTPS and SPDY
// SSL Context Factory for HTTPS and HTTP/2
String jetty_distro = System.getProperty("jetty.distro","../../jetty-distribution/target/distribution");
SslContextFactory sslContextFactory = new SslContextFactory();
sslContextFactory.setKeyStorePath(jetty_distro + "/etc/keystore");
@ -95,17 +94,17 @@ public class Http2Server
HttpConfiguration https_config = new HttpConfiguration(http_config);
https_config.addCustomizer(new SecureRequestCustomizer());
// HTTP2 factory
// HTTP/2 Connection Factory
HTTP2ServerConnectionFactory h2 = new HTTP2ServerConnectionFactory(https_config);
NegotiatingServerConnectionFactory.checkProtocolNegotiationAvailable();
ALPNServerConnectionFactory alpn = new ALPNServerConnectionFactory();
alpn.setDefaultProtocol(http.getDefaultProtocol());
// SSL Factory
// SSL Connection Factory
SslConnectionFactory ssl = new SslConnectionFactory(sslContextFactory,alpn.getProtocol());
// HTTP2 Connector
// HTTP/2 Connector
ServerConnector http2Connector =
new ServerConnector(server,ssl,alpn,h2,new HttpConnectionFactory(https_config));
http2Connector.setPort(8443);

View File

@ -18,10 +18,10 @@
package org.eclipse.jetty.embedded;
import org.eclipse.jetty.http.HttpVersion;
import java.io.File;
import java.io.FileNotFoundException;
import org.eclipse.jetty.http.HttpVersion;
import org.eclipse.jetty.server.Connector;
import org.eclipse.jetty.server.HttpConfiguration;
import org.eclipse.jetty.server.HttpConnectionFactory;
@ -78,7 +78,7 @@ public class ManyConnectors
http.setPort(8080);
http.setIdleTimeout(30000);
// SSL Context Factory for HTTPS and SPDY
// SSL Context Factory for HTTPS
// SSL requires a certificate so we configure a factory for ssl contents
// with information pointing to what keystore the ssl connection needs
// to know about. Much more configuration is available the ssl context,

View File

@ -3,10 +3,8 @@ org.eclipse.jetty.LEVEL=INFO
org.eclipse.jetty.STACKS=true
org.eclipse.jetty.SOURCE=false
#org.eclipse.jetty.STACKS=false
#org.eclipse.jetty.spdy.LEVEL=DEBUG
#org.eclipse.jetty.server.LEVEL=DEBUG
#org.eclipse.jetty.io.LEVEL=DEBUG
#org.eclipse.jetty.io.ssl.LEVEL=DEBUG
#org.eclipse.jetty.spdy.server.LEVEL=DEBUG
#org.eclipse.jetty.server.LEVEL=DEBUG
#org.eclipse.jetty.servlets.LEVEL=DEBUG

View File

@ -25,12 +25,7 @@ public class TestXml
public static void main(String[] args) throws Exception
{
System.setProperty("jetty.home","../jetty-distribution/target/distribution");
XmlConfiguration.main(new String[]
{
"../jetty-jmx/src/main/config/etc/jetty-jmx.xml",
"../jetty-server/src/main/config/etc/jetty.xml",
"../jetty-spdy/spdy-jetty-http-webapp/src/main/config/etc/jetty-spdy.xml"
}
);
XmlConfiguration.main("../jetty-jmx/src/main/config/etc/jetty-jmx.xml",
"../jetty-server/src/main/config/etc/jetty.xml");
}
}

View File

@ -1,9 +1,8 @@
# ALPN is provided via a -Xbootclasspath that modifies the secure connections
# in java to support the ALPN layer needed for SPDY (and eventually HTTP/2)
# in java to support the ALPN layer needed for HTTP/2.
#
# This modification has a tight dependency on specific recent updates of
# Java 1.7 and Java 1.8
# (Java versions prior to 1.7u40 are not supported)
# Java 1.7 and Java 1.8 (Java versions prior to 1.7u40 are not supported).
#
# The alpn protonego module will use an appropriate alpn-boot jar for your
# specific version of Java.

View File

@ -31,8 +31,8 @@ import org.eclipse.jetty.io.ClientConnectionFactory;
* <em>how</em> a HTTP exchange is carried over the network depends on implementations of this class.
* <p/>
* The default implementation uses the HTTP protocol to carry over the network the HTTP exchange,
* but the HTTP exchange may also be carried using the SPDY protocol or the FCGI protocol or, in future,
* other protocols.
* but the HTTP exchange may also be carried using the FCGI protocol, the HTTP/2 protocol or,
* in future, other protocols.
*/
public interface HttpClientTransport extends ClientConnectionFactory
{
@ -54,7 +54,7 @@ public interface HttpClientTransport extends ClientConnectionFactory
* Creates a new, transport-specific, {@link HttpDestination} object.
* <p />
* {@link HttpDestination} controls the destination-connection cardinality: protocols like
* HTTP have 1-N cardinality, while multiplexed protocols like SPDY have a 1-1 cardinality.
* HTTP have 1-N cardinality, while multiplexed protocols like HTTP/2 have a 1-1 cardinality.
*
* @param origin the destination origin
* @return a new, transport-specific, {@link HttpDestination} object

View File

@ -64,14 +64,14 @@
<!-- =========================================================== -->
<!-- Http Configuration. -->
<!-- This is a common configuration instance used by all -->
<!-- connectors that can carry HTTP semantics (HTTP, HTTPS, SPDY)-->
<!-- connectors that can carry HTTP semantics (HTTP, HTTPS, etc.)-->
<!-- It configures the non wire protocol aspects of the HTTP -->
<!-- semantic. -->
<!-- -->
<!-- This configuration is only defined here and is used by -->
<!-- reference from the jetty-http.xml, jetty-https.xml and -->
<!-- jetty-spdy.xml configuration files which instantiate the -->
<!-- connectors. -->
<!-- reference from other XML files such as jetty-http.xml, -->
<!-- jetty-https.xml and other configuration files which -->
<!-- instantiate the connectors. -->
<!-- -->
<!-- Consult the javadoc of o.e.j.server.HttpConfiguration -->
<!-- for all configuration that may be set here. -->

View File

@ -69,7 +69,7 @@ NAME=$(echo $(basename $0) | sed -e 's/^[SK][0-9]*//' -e 's/\.sh$//')
# JETTY_ARGS
# The default arguments to pass to jetty.
# For example
# JETTY_ARGS=jetty.port=8080 jetty.spdy.port=8443 jetty.secure.port=443
# JETTY_ARGS=jetty.port=8080 jetty.secure.port=443
#
# JETTY_USER
# if set, then used as a username to run the server as

View File

@ -21,7 +21,7 @@
Container which supports asynchronous server and client
implementations of the <a href="http://en.wikipedia.org/wiki/HTTP">HTTP</a>,
<a href="http://en.wikipedia.org/wiki/WebSocket">Websocket</a> and <a
href="http://en.wikipedia.org/wiki/SPDY">SPDY</a> protocols. The
href="http://en.wikipedia.org/wiki/HTTP/2">HTTP/2</a> protocols. The
project is 100% <a href="http://en.wikipedia.org/wiki/Open_source">Open Source</a> and hosted by the <a href="http://www.eclipse.org">Eclipse Foundation</a> at <a href="http://www.eclipse.org/jetty/">http://www.eclipse.org/jetty</a>.
</p>
</div>

View File

@ -8,17 +8,10 @@ protonego-impl/${protonego}
[ini-template]
# Protocol Negotiation Implementation Selection
# choices are:
# 'npn' : original implementation for SPDY (now deprecated)
# 'alpn' : replacement for NPN, in use by current SPDY implementations
# and the future HTTP/2 spec
# 'alpn' : in use by current HTTP/2 implementation.
# Note: java 1.8+ are ALPN only.
protonego=alpn
# Configuration for NPN
# npn.protocols=spdy/3,http/1.1
# npn.defaultProtocol=http/1.1
# Configuration for ALPN
# alpn.protocols=h2-14,http/1.1
# alpn.defaultProtocol=http/1.1

View File

@ -45,8 +45,6 @@ public interface Session
public Stream getStream(int streamId);
// TODO: remote and local address, etc. see SPDY's Session
public interface Listener
{
public Map<Integer,Integer> onPreface(Session session);

View File

@ -53,8 +53,6 @@ public interface Stream
public void setIdleTimeout(long idleTimeout);
// TODO: see SPDY's Stream
public interface Listener
{
public void onHeaders(Stream stream, HeadersFrame frame);

View File

@ -4,7 +4,7 @@
<!-- ============================================================= -->
<!-- Base SSL configuration -->
<!-- This configuration needs to be used together with 1 or more -->
<!-- of jetty-https.xml, jetty-spdy.xml and/or jetty-http2.xml -->
<!-- of jetty-https.xml or jetty-http2.xml -->
<!-- ============================================================= -->
<Configure id="Server" class="org.eclipse.jetty.server.Server">

View File

@ -64,14 +64,14 @@
<!-- =========================================================== -->
<!-- Http Configuration. -->
<!-- This is a common configuration instance used by all -->
<!-- connectors that can carry HTTP semantics (HTTP, HTTPS, SPDY)-->
<!-- connectors that can carry HTTP semantics (HTTP, HTTPS, etc.)-->
<!-- It configures the non wire protocol aspects of the HTTP -->
<!-- semantic. -->
<!-- -->
<!-- This configuration is only defined here and is used by -->
<!-- reference from the jetty-http.xml, jetty-https.xml and -->
<!-- jetty-spdy.xml configuration files which instantiate the -->
<!-- connectors. -->
<!-- reference from other XML files such as jetty-http.xml, -->
<!-- jetty-https.xml and other configuration files which -->
<!-- instantiate the connectors. -->
<!-- -->
<!-- Consult the javadoc of o.e.j.server.HttpConfiguration -->
<!-- for all configuration that may be set here. -->

View File

@ -49,7 +49,7 @@ import org.eclipse.jetty.util.thread.Scheduler;
/**
* <p>An abstract implementation of {@link Connector} that provides a {@link ConnectionFactory} mechanism
* for creating {@link Connection} instances for various protocols (HTTP, SSL, SPDY, etc).</p>
* for creating {@link Connection} instances for various protocols (HTTP, SSL, etc).</p>
*
* <h2>Connector Services</h2>
* The abstract connector manages the dependent services needed by all specific connector instances:
@ -70,7 +70,7 @@ import org.eclipse.jetty.util.thread.Scheduler;
*
* <h2>Connection Factories</h2>
* The connector keeps a collection of {@link ConnectionFactory} instances, each of which are known by their
* protocol name. The protocol name may be a real protocol (eg http/1.1 or spdy/3) or it may be a private name
* protocol name. The protocol name may be a real protocol (e.g. "http/1.1" or "h2") or it may be a private name
* that represents a special connection factory. For example, the name "SSL-http/1.1" is used for
* an {@link SslConnectionFactory} that has been instantiated with the {@link HttpConnectionFactory} as it's
* next protocol.
@ -87,7 +87,7 @@ import org.eclipse.jetty.util.thread.Scheduler;
* <p>
* Each Connection factory type is responsible for the configuration of the protocols that it accepts. Thus to
* configure the HTTP protocol, you pass a {@link HttpConfiguration} instance to the {@link HttpConnectionFactory}
* (or the SPDY factories that can also provide HTTP Semantics). Similarly the {@link SslConnectionFactory} is
* (or other factories that can also provide HTTP Semantics). Similarly the {@link SslConnectionFactory} is
* configured by passing it a {@link SslContextFactory} and a next protocol name.
*
* <h4>Connection Factory Operation</h4>
@ -104,16 +104,16 @@ import org.eclipse.jetty.util.thread.Scheduler;
* to run over the SSL connection.
* <p>
* {@link ConnectionFactory}s may also create temporary {@link Connection} instances that will exchange bytes
* over the connection to determine what is the next protocol to use. For example the NPN protocol is an extension
* of SSL to allow a protocol to be specified during the SSL handshake. NPN is used by the SPDY protocol to
* negotiate the version of SPDY or HTTP that the client and server will speak. Thus to accept a SPDY connection, the
* connector will be configured with {@link ConnectionFactory}s for "SSL-NPN", "NPN", "spdy/3", "spdy/2", "http/1.1"
* with the default protocol being "SSL-NPN". Thus a newly accepted connection uses "SSL-NPN", which specifies a
* SSLConnectionFactory with "NPN" as the next protocol. Thus an SslConnection instance is created chained to an NPNConnection
* instance. The NPN connection then negotiates with the client to determined the next protocol, which could be
* "spdy/3", "spdy/2" or the default of "http/1.1". Once the next protocol is determined, the NPN connection
* calls {@link #getConnectionFactory(String)} to create a connection instance that will replace the NPN connection as
* the connection chained to the SSLConnection.
* over the connection to determine what is the next protocol to use. For example the ALPN protocol is an extension
* of SSL to allow a protocol to be specified during the SSL handshake. ALPN is used by the HTTP/2 protocol to
* negotiate the protocol that the client and server will speak. Thus to accept a HTTP/2 connection, the
* connector will be configured with {@link ConnectionFactory}s for "SSL-ALPN", "h2", "http/1.1"
* with the default protocol being "SSL-ALPN". Thus a newly accepted connection uses "SSL-ALPN", which specifies a
* SSLConnectionFactory with "ALPN" as the next protocol. Thus an SSL connection instance is created chained to an ALPN
* connection instance. The ALPN connection then negotiates with the client to determined the next protocol, which
* could be "h2" or the default of "http/1.1". Once the next protocol is determined, the ALPN connection
* calls {@link #getConnectionFactory(String)} to create a connection instance that will replace the ALPN connection as
* the connection chained to the SSL connection.
* <p>
* <h2>Acceptors</h2>
* The connector will execute a number of acceptor tasks to the {@link Exception} service passed to the constructor.
@ -128,7 +128,7 @@ import org.eclipse.jetty.util.thread.Scheduler;
* </nl>
* The default number of acceptor tasks is the minimum of 1 and half the number of available CPUs. Having more acceptors may reduce
* the latency for servers that see a high rate of new connections (eg HTTP/1.0 without keep-alive). Typically the default is
* sufficient for modern persistent protocols (HTTP/1.1, SPDY etc.)
* sufficient for modern persistent protocols (HTTP/1.1, HTTP/2 etc.)
*/
@ManagedObject("Abstract implementation of the Connector Interface")
public abstract class AbstractConnector extends ContainerLifeCycle implements Connector, Dumpable

View File

@ -32,11 +32,11 @@ import org.eclipse.jetty.io.EndPoint;
* A ConnectionFactory has a protocol name that represents the protocol of the Connections
* created. Example of protocol names include:<dl>
* <dt>http</dt><dd>Creates a HTTP connection that can handle multiple versions of HTTP from 0.9 to 1.1</dd>
* <dt>spdy/2</dt><dd>Creates a HTTP connection that handles a specific version of the SPDY protocol</dd>
* <dt>h2</dt><dd>Creates a HTTP/2 connection that handles the HTTP/2 protocol</dd>
* <dt>SSL-XYZ</dt><dd>Create an SSL connection chained to a connection obtained from a connection factory
* with a protocol "XYZ".</dd>
* <dt>SSL-http</dt><dd>Create an SSL connection chained to a HTTP connection (aka https)</dd>
* <dt>SSL-npn</dt><dd>Create an SSL connection chained to a NPN connection, that uses a negotiation with
* <dt>SSL-ALPN</dt><dd>Create an SSL connection chained to a ALPN connection, that uses a negotiation with
* the client to determine the next protocol.</dd>
* </dl>
*/

View File

@ -32,7 +32,7 @@ import org.eclipse.jetty.util.annotation.ManagedObject;
* <p>This class is a holder of HTTP configuration for use by the
* {@link HttpChannel} class. Typically a HTTPConfiguration instance
* is instantiated and passed to a {@link ConnectionFactory} that can
* create HTTP channels (eg HTTP, AJP or SPDY).</p>
* create HTTP channels (e.g. HTTP, AJP or FCGI).</p>
* <p>The configuration held by this class is not for the wire protocol,
* but for the interpretation and handling of HTTP requests that could
* be transported by a variety of protocols.

View File

@ -47,7 +47,7 @@ import org.eclipse.jetty.util.thread.Scheduler;
/**
* This {@link Connector} implementation is the primary connector for the
* Jetty server over TCP/IP. By the use of various {@link ConnectionFactory} instances it is able
* to accept connections for HTTP, SPDY and WebSocket, either directly or over SSL.
* to accept connections for HTTP, HTTP/2 and WebSocket, either directly or over SSL.
* <p>
* The connector is a fully asynchronous NIO based implementation that by default will
* use all the commons services (eg {@link Executor}, {@link Scheduler}) of the

View File

@ -21,7 +21,6 @@ package org.eclipse.jetty;
import java.io.File;
import java.io.IOException;
import java.lang.management.ManagementFactory;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
@ -93,42 +92,6 @@ public class TestServer
httpConnector.setIdleTimeout(30000);
server.addConnector(httpConnector);
/*
// SSL configurations
SslContextFactory sslContextFactory = new SslContextFactory();
sslContextFactory.setKeyStorePath(jetty_root + "/jetty-server/src/main/config/etc/keystore");
sslContextFactory.setKeyStorePassword("OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4");
sslContextFactory.setKeyManagerPassword("OBF:1u2u1wml1z7s1z7a1wnl1u2g");
sslContextFactory.setTrustStorePath(jetty_root + "/jetty-server/src/main/config/etc/keystore");
sslContextFactory.setTrustStorePassword("OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4");
sslContextFactory.setExcludeCipherSuites(
"SSL_RSA_WITH_DES_CBC_SHA",
"SSL_DHE_RSA_WITH_DES_CBC_SHA",
"SSL_DHE_DSS_WITH_DES_CBC_SHA",
"SSL_RSA_EXPORT_WITH_RC4_40_MD5",
"SSL_RSA_EXPORT_WITH_DES40_CBC_SHA",
"SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA",
"SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA");
// Spdy Connector
SPDYServerConnectionFactory.checkNPNAvailable();
PushStrategy push = new ReferrerPushStrategy();
HTTPSPDYServerConnectionFactory spdy2 = new HTTPSPDYServerConnectionFactory(2,config,push);
spdy2.setInputBufferSize(8192);
spdy2.setInitialWindowSize(32768);
HTTPSPDYServerConnectionFactory spdy3 = new HTTPSPDYServerConnectionFactory(3,config,push);
spdy2.setInputBufferSize(8192);
NPNServerConnectionFactory npn = new NPNServerConnectionFactory(spdy3.getProtocol(),spdy2.getProtocol(),http.getProtocol());
npn.setDefaultProtocol(http.getProtocol());
npn.setInputBufferSize(1024);
SslConnectionFactory ssl = new SslConnectionFactory(sslContextFactory,npn.getProtocol());
ServerConnector spdyConnector = new ServerConnector(server,ssl,npn,spdy3,spdy2,http);
spdyConnector.setPort(8443);
spdyConnector.setIdleTimeout(15000);
server.addConnector(spdyConnector);
*/
// Handlers
HandlerCollection handlers = new HandlerCollection();