Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoakim Erdfelt2014-10-28 16:36:34 +0000
committerJoakim Erdfelt2014-10-28 16:36:34 +0000
commit607a560ebd3ee7fdd5faa50f2907edae7f9c8831 (patch)
treecbfd849f7a41b0b1a63a5b7cf379015349c33507
parent6ff43a0af17f140a16b21241104c9ebbfa2dc5c6 (diff)
parent653cb32ede499319eec9a27e8392ca2e39064e3d (diff)
downloadorg.eclipse.jetty.project-607a560ebd3ee7fdd5faa50f2907edae7f9c8831.tar.gz
org.eclipse.jetty.project-607a560ebd3ee7fdd5faa50f2907edae7f9c8831.tar.xz
org.eclipse.jetty.project-607a560ebd3ee7fdd5faa50f2907edae7f9c8831.zip
Merge branch 'jetty-9.2.x' into cdi-testing
-rw-r--r--VERSION.txt72
-rw-r--r--examples/embedded/pom.xml7
-rw-r--r--jetty-distribution/pom.xml16
-rw-r--r--jetty-distribution/src/main/resources/start.ini41
-rw-r--r--jetty-http/src/main/java/org/eclipse/jetty/http/HttpTester.java (renamed from jetty-http/src/test/java/org/eclipse/jetty/http/HttpTester.java)0
-rw-r--r--jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java2
-rw-r--r--jetty-servlets/pom.xml7
-rw-r--r--jetty-start/src/main/java/org/eclipse/jetty/start/BaseHomeWarning.java34
-rw-r--r--jetty-start/src/main/java/org/eclipse/jetty/start/Main.java60
-rw-r--r--jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java2
-rw-r--r--jetty-start/src/main/resources/org/eclipse/jetty/start/base-home-warning.txt15
-rw-r--r--jetty-websocket/websocket-server/src/main/java/org/eclipse/jetty/websocket/server/WebSocketUpgradeFilter.java3
-rw-r--r--pom.xml1
-rw-r--r--tests/test-integration/pom.xml7
14 files changed, 175 insertions, 92 deletions
diff --git a/VERSION.txt b/VERSION.txt
index 7d48de6846..f009154db3 100644
--- a/VERSION.txt
+++ b/VERSION.txt
@@ -1,3 +1,75 @@
+jetty-9.2.5-SNAPSHOT
+
+jetty-9.2.4.v20141027 - 27 October 2014
+ + 376365 "jetty.sh start" returns 0 on failure
+ + 396569 'bin/jetty.sh stop' reports 'OK' even when jetty was not running
+ + 396572 Starting jetty from cygwin is not working properly
+ + 438387 NullPointerException after ServletUpgradeResponse.sendForbidden is
+ called during WebSocketCreator.createWebSocket
+ + 440729 SSL requests often fail with EOFException or IllegalStateException.
+ + 442419 CrossOriginFilter javadoc says "exposeHeaders", but should be
+ "exposedHeaders"
+ + 442495 Bad Context ClassLoader in JSR356 WebSocket onOpen
+ + 442942 Content sent with status 204 (No Content)
+ + 443529 CrossOriginFilter does not accept wildcard for allowedHeaders
+ + 443530 CrossOriginFilter does not set the Vary header
+ + 444031 Ensure exceptions do not reduce threadpool below minimum
+ + 444124 JSP include with <servlet><jsp-file> can cause infinite recursion
+ + 444214 Socks4Proxy fails when reading less than 8 bytes.
+ + 444222 replace CRLF in header values with whitespace rather than ?
+ + 444415 iterative WriteFlusher
+ + 444416 AsyncProxyServlet recursion.
+ + 444517 Ensure WebSocketUpgradeFilter is always first in filter chain
+ + 444547 Format exception in ResourceCache.Content.toString()
+ + 444595 nosql/mongodb - Cleanup process/Refreshing does not respect encoding
+ of attribute keys
+ + 444617 Expose local and remote socket address to applications
+ + 444676 Goal jetty:deploy-war produces errors with version 9.2.3
+ + 444748 WebSocketClient.stop() does not unregister from ShutdownThread
+ + 444764 HttpClient notifies callbacks for last chunk of content twice.
+ + 444771 JSR356 / EndPointConfig.userProperties are not unique per endpoint
+ upgrade
+ + 444863 ProxyServlet does not filter headers listed by the Connection header.
+ + 444896 Overriding of web-default servlet mapping in web.xml not working with
+ quickstart
+ + 445157 First redeployed servlet leaks WebAppContext
+ + 445258 STOP.WAIT is not really respected
+ + 445374 Reevaluate org.eclipse.jetty.websocket.jsr356 enablement concepts
+ + 445495 Improve Exception message when no jndi resource to bind for a name in
+ web.xml
+ + 445542 Add SecuredRedirectHandler for embedded jetty use to redirect to
+ secure port/scheme
+ + 445821 Error 400 should be logged with RequestLog
+ + 445823 RequestLogHandler at end of HandlerCollection doesn't work
+ + 445830 Support setting environment variables on forked jetty with
+ jetty:run-forked
+ + 445979 jetty.sh fails to start when start-stop-daemon does not exist and the
+ user is not root
+ + 446033 org.eclipse.jetty.websocket.server.WebSocketServerFactory not
+ available in OSGi
+ + 446063 ALPN Fail SSL Handshake if no supported Application Protocols.
+ + 446107 NullPointerException in ProxyServlet when extended by Servlet without
+ a package
+ + 446425 Oracle Sql error on JettySessions table when this table do not exist
+ already
+ + 446506 getAsyncContext ISE before startAsync on async dispatches
+ + 446563 Null HttpChannel.getCurrentHttpChannel() in
+ ServletHandler.doFilter().
+ + 446672 NPN Specification issue in the case no protocols are selected.
+ + 446923 SharedBlockingCallback does not handle connector max idle time of
+ Long.MAX_VALUE; BlockerTimeoutException not serializable
+ + 447381 Disable SSLv3 by default.
+ + 447472 test harness for slow large writes
+ + 447627 MultiPart file always created when "filename" set in
+ Content-Disposition
+ + 447629 getPart()/getParts() fails on Multipart request if getParameter is
+ called in a filter first
+ + 447746 HttpClient is always going to send User-Agent header even though I do
+ not want it to.
+ + 447979 Refactor to make MetaData responsible for progressively ordering
+ web-inf jars
+ + 448156 Fixed INACTIVE race in IteratingCallback
+
jetty-9.2.3.v20140905 - 05 September 2014
+ 347110 renamed class transformer methods
+ 411163 Add embedded jetty code example with JSP enabled
diff --git a/examples/embedded/pom.xml b/examples/embedded/pom.xml
index 453aad9fb9..ec912bc491 100644
--- a/examples/embedded/pom.xml
+++ b/examples/embedded/pom.xml
@@ -105,12 +105,5 @@
<artifactId>jetty-test-helper</artifactId>
<!-- scope>test</scope-->
</dependency>
- <dependency>
- <groupId>org.eclipse.jetty</groupId>
- <artifactId>jetty-http</artifactId>
- <version>${project.version}</version>
- <classifier>tests</classifier>
- <scope>test</scope>
- </dependency>
</dependencies>
</project>
diff --git a/jetty-distribution/pom.xml b/jetty-distribution/pom.xml
index 4a85e9a24f..084ca87ba4 100644
--- a/jetty-distribution/pom.xml
+++ b/jetty-distribution/pom.xml
@@ -559,22 +559,6 @@
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
- <id>setup home</id>
- <phase>process-classes</phase>
- <configuration>
- <mainClass>org.eclipse.jetty.start.Main</mainClass>
- <arguments>
- <argument>jetty.home=${assembly-directory}</argument>
- <argument>jetty.base=${assembly-directory}</argument>
- <argument>--add-to-start=server,deploy,websocket,ext,resources</argument>
- <argument>--add-to-startd=jsp,jstl,http</argument>
- </arguments>
- </configuration>
- <goals>
- <goal>java</goal>
- </goals>
- </execution>
- <execution>
<id>setup demo-base</id>
<phase>process-classes</phase>
<configuration>
diff --git a/jetty-distribution/src/main/resources/start.ini b/jetty-distribution/src/main/resources/start.ini
index 59d94becc0..9d0bdc17c9 100644
--- a/jetty-distribution/src/main/resources/start.ini
+++ b/jetty-distribution/src/main/resources/start.ini
@@ -1,35 +1,16 @@
#===========================================================
-# Jetty start.jar arguments
+# Jetty Home Start INI
#
-# The contents of this file, together with the *.ini
-# files found in start.d directory are used to build
-# the classpath and command line on a call to
-# java -jar start.jar [arg...]
-#
-# Use the following command to see more options
-# java -jar start.jar --help
-#
-# Each line in these files is prepended to the command line
-# as arguments and may be either:
-# + A property like: name=value
-# + A module to enable like: --module=jmx
-# + An XML configuration file like: etc/jetty-feature.xml
-# + A start.jar option like: --dry-run
-#
-# If --exec or --dry-run are used, then this file may also
-# contain lines with:
-# + A JVM option like: -Xmx2000m
-# + A System Property like: -Dcom.sun.management.jmxremote
-#
-# The --add-to-start=module option can be used to append
-# a configuration template for a module to start.ini
-# The --add-to-startd=module option can be used to create
-# a configuration template for a module in start.d/module.ini
-# For example configure and run with SPDY use
-#
-# java -jar start.jar --add-to-startd=spdy
-# $EDITOR start.d/spdy.ini
-# java -jar start.jar
+# It is not recommended to run Jetty from {jetty.home}
+#
+# This configuration simply presents a warning message
+# about this recommendation.
#
+# It is considered an advanced features to run Jetty
+# from {jetty.home}. If you are brave enough to do this
+# then start with a fresh {jetty.home}/start.ini
#===========================================================
+# Show warning message
+-Dmain.class=org.eclipse.jetty.start.BaseHomeWarning
+
diff --git a/jetty-http/src/test/java/org/eclipse/jetty/http/HttpTester.java b/jetty-http/src/main/java/org/eclipse/jetty/http/HttpTester.java
index 537c457cb4..537c457cb4 100644
--- a/jetty-http/src/test/java/org/eclipse/jetty/http/HttpTester.java
+++ b/jetty-http/src/main/java/org/eclipse/jetty/http/HttpTester.java
diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
index 2143d8dc7e..4ee2d5d9d0 100644
--- a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
+++ b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
@@ -105,7 +105,7 @@ import org.eclipse.jetty.util.resource.Resource;
public class ContextHandler extends ScopedHandler implements Attributes, Graceful
{
public final static int SERVLET_MAJOR_VERSION=3;
- public final static int SERVLET_MINOR_VERSION=0;
+ public final static int SERVLET_MINOR_VERSION=1;
public static final Class<?>[] SERVLET_LISTENER_TYPES = new Class[] {ServletContextListener.class,
ServletContextAttributeListener.class,
ServletRequestListener.class,
diff --git a/jetty-servlets/pom.xml b/jetty-servlets/pom.xml
index 574b964b97..bdc9c25a5d 100644
--- a/jetty-servlets/pom.xml
+++ b/jetty-servlets/pom.xml
@@ -109,13 +109,6 @@
<scope>test</scope>
</dependency>
<dependency>
- <groupId>org.eclipse.jetty</groupId>
- <artifactId>jetty-http</artifactId>
- <version>${project.version}</version>
- <classifier>tests</classifier>
- <scope>test</scope>
- </dependency>
- <dependency>
<groupId>org.eclipse.jetty.toolchain</groupId>
<artifactId>jetty-test-helper</artifactId>
<scope>test</scope>
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/BaseHomeWarning.java b/jetty-start/src/main/java/org/eclipse/jetty/start/BaseHomeWarning.java
new file mode 100644
index 0000000000..0c4c6b8a31
--- /dev/null
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/BaseHomeWarning.java
@@ -0,0 +1,34 @@
+//
+// ========================================================================
+// Copyright (c) 1995-2014 Mort Bay Consulting Pty. Ltd.
+// ------------------------------------------------------------------------
+// All rights reserved. This program and the accompanying materials
+// are made available under the terms of the Eclipse Public License v1.0
+// and Apache License v2.0 which accompanies this distribution.
+//
+// The Eclipse Public License is available at
+// http://www.eclipse.org/legal/epl-v10.html
+//
+// The Apache License v2.0 is available at
+// http://www.opensource.org/licenses/apache2.0.php
+//
+// You may elect to redistribute this code under either of these licenses.
+// ========================================================================
+//
+
+package org.eclipse.jetty.start;
+
+
+public class BaseHomeWarning
+{
+ public static void main(String[] args)
+ {
+ if(!Main.printTextResource("org/eclipse/jetty/start/base-home-warning.txt"))
+ {
+ StartLog.warn("It is not recommended to run Jetty from within {jetty.home}");
+ StartLog.warn("Use proper {jetty.base} setup");
+ StartLog.warn("See: http://www.eclipse.org/jetty/documentation/current/startup.html");
+ }
+ System.exit(-1);
+ }
+}
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java b/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
index f755f19f41..47f1c4431c 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
@@ -741,14 +741,25 @@ public class Main
if (!FS.exists(file))
{
- /* Startup should NEVER fail to run on missing content.
- * See Bug #427204
- */
- // args.setRun(false);
- String type=arg.location.endsWith("/")?"directory":"file";
- if (arg.uri!=null)
+ boolean isDir = arg.location.endsWith("/");
+ if (isDir)
{
- StartLog.warn("Required %s '%s' not downloaded from %s. Run with --create-files to download",type,baseHome.toShortForm(file),arg.uri);
+ System.err.println("MKDIR: " + baseHome.toShortForm(file));
+ FS.ensureDirectoryExists(file);
+ /* Startup should not fail to run on missing directories.
+ * See Bug #427204
+ */
+ // args.setRun(false);
+ }
+ else
+ {
+ StartLog.warn("Missing Required File: %s",baseHome.toShortForm(file));
+ args.setRun(false);
+ if (arg.uri != null)
+ {
+ StartLog.warn(" Can be downloaded From: %s",arg.uri);
+ StartLog.warn(" Run start.jar --create-files to download");
+ }
}
}
}
@@ -894,15 +905,26 @@ public class Main
public void usage(boolean exit)
{
StartLog.endStartLog();
- String usageResource = "org/eclipse/jetty/start/usage.txt";
- boolean usagePresented = false;
- try (InputStream usageStream = getClass().getClassLoader().getResourceAsStream(usageResource))
+ if(!printTextResource("org/eclipse/jetty/start/usage.txt"))
+ {
+ System.err.println("ERROR: detailed usage resource unavailable");
+ }
+ if (exit)
+ {
+ System.exit(EXIT_USAGE);
+ }
+ }
+
+ public static boolean printTextResource(String resourceName)
+ {
+ boolean resourcePrinted = false;
+ try (InputStream stream = Thread.currentThread().getContextClassLoader().getResourceAsStream(resourceName))
{
- if (usageStream != null)
+ if (stream != null)
{
- try (InputStreamReader reader = new InputStreamReader(usageStream); BufferedReader buf = new BufferedReader(reader))
+ try (InputStreamReader reader = new InputStreamReader(stream); BufferedReader buf = new BufferedReader(reader))
{
- usagePresented = true;
+ resourcePrinted = true;
String line;
while ((line = buf.readLine()) != null)
{
@@ -912,21 +934,15 @@ public class Main
}
else
{
- System.out.println("No usage.txt ??");
+ System.out.println("Unable to find resource: " + resourceName);
}
}
catch (IOException e)
{
StartLog.warn(e);
}
- if (!usagePresented)
- {
- System.err.println("ERROR: detailed usage resource unavailable");
- }
- if (exit)
- {
- System.exit(EXIT_USAGE);
- }
+
+ return resourcePrinted;
}
// ------------------------------------------------------------
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java b/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
index 0998c36054..ecca0a6afb 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
@@ -574,7 +574,7 @@ public class StartArgs
for (String key : systemPropertyKeys)
{
// ignored keys
- if ("jetty.home".equals(key) || "jetty.base".equals(key))
+ if ("jetty.home".equals(key) || "jetty.base".equals(key) || "main.class".equals(key))
{
// skip
continue;
diff --git a/jetty-start/src/main/resources/org/eclipse/jetty/start/base-home-warning.txt b/jetty-start/src/main/resources/org/eclipse/jetty/start/base-home-warning.txt
new file mode 100644
index 0000000000..c0fa8298ba
--- /dev/null
+++ b/jetty-start/src/main/resources/org/eclipse/jetty/start/base-home-warning.txt
@@ -0,0 +1,15 @@
+WARNING
+-------
+
+While it is possible to run Jetty from within {jetty.home},
+it is not recommended that you run Jetty this way.
+
+Please setup a proper {jetty.base}.
+
+See http://www.eclipse.org/jetty/documentation/current/startup.html
+
+The demo-base has been provided to you for an example of this kind of setup.
+
+ $ cd demo-base
+ $ java -jar ../start.jar
+
diff --git a/jetty-websocket/websocket-server/src/main/java/org/eclipse/jetty/websocket/server/WebSocketUpgradeFilter.java b/jetty-websocket/websocket-server/src/main/java/org/eclipse/jetty/websocket/server/WebSocketUpgradeFilter.java
index 1be0734fa6..2e54154e00 100644
--- a/jetty-websocket/websocket-server/src/main/java/org/eclipse/jetty/websocket/server/WebSocketUpgradeFilter.java
+++ b/jetty-websocket/websocket-server/src/main/java/org/eclipse/jetty/websocket/server/WebSocketUpgradeFilter.java
@@ -20,7 +20,6 @@ package org.eclipse.jetty.websocket.server;
import java.io.IOException;
import java.util.EnumSet;
-
import javax.servlet.DispatcherType;
import javax.servlet.Filter;
import javax.servlet.FilterChain;
@@ -77,6 +76,7 @@ public class WebSocketUpgradeFilter extends ContainerLifeCycle implements Filter
FilterHolder fholder = new FilterHolder(filter);
fholder.setName(name);
+ fholder.setAsyncSupported(true);
fholder.setInitParameter(CONTEXT_ATTRIBUTE_KEY,WebSocketUpgradeFilter.class.getName());
context.addFilter(fholder,pathSpec,dispatcherTypes);
@@ -108,6 +108,7 @@ public class WebSocketUpgradeFilter extends ContainerLifeCycle implements Filter
String urlPatterns[] = { pathSpec };
FilterRegistration.Dynamic dyn = context.addFilter(name,filter);
+ dyn.setAsyncSupported(true);
dyn.setInitParameter(CONTEXT_ATTRIBUTE_KEY,WebSocketUpgradeFilter.class.getName());
dyn.addMappingForUrlPatterns(dispatcherTypes,isMatchAfter,urlPatterns);
diff --git a/pom.xml b/pom.xml
index 9f03a29eaa..8da0837f1e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -26,6 +26,7 @@
<connection>scm:git:http://git.eclipse.org/gitroot/jetty/org.eclipse.jetty.project.git</connection>
<developerConnection>scm:git:ssh://git.eclipse.org/gitroot/jetty/org.eclipse.jetty.project.git</developerConnection>
<url>http://git.eclipse.org/c/jetty/org.eclipse.jetty.project.git/tree</url>
+ <tag>HEAD</tag>
</scm>
<build>
<defaultGoal>install</defaultGoal>
diff --git a/tests/test-integration/pom.xml b/tests/test-integration/pom.xml
index 6640fed17a..8e9b1da9cc 100644
--- a/tests/test-integration/pom.xml
+++ b/tests/test-integration/pom.xml
@@ -117,13 +117,6 @@
<type>pom</type>
</dependency>
<dependency>
- <groupId>org.eclipse.jetty</groupId>
- <artifactId>jetty-http</artifactId>
- <version>${project.version}</version>
- <classifier>tests</classifier>
- <scope>test</scope>
- </dependency>
- <dependency>
<groupId>org.eclipse.jetty.toolchain</groupId>
<artifactId>jetty-test-helper</artifactId>
<scope>test</scope>

Back to the top