From d753311181dfde2a75160d032eba346f448fdbaa Mon Sep 17 00:00:00 2001 From: Greg Wilkins Date: Wed, 23 Feb 2011 05:05:38 +0000 Subject: [PATCH] 318105 Consistent return of null from continuation.getServletResponse git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@2823 7e9141cc-0065-0410-87d8-b60c137991c4 --- VERSION.txt | 1 + .../org/eclipse/jetty/client/ProxyTunnellingTest.java | 8 +++----- .../org/eclipse/jetty/continuation/FauxContinuation.java | 1 - .../java/org/eclipse/jetty/server/AsyncContinuation.java | 3 ++- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/VERSION.txt b/VERSION.txt index f5590d2f519..7d7257ea7d8 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1,5 +1,6 @@ jetty-7.3.1-SNAPSHOT + 316382 Support a more strict SSL option with certificates + + 318105 Consistent return of null from continuation.getServletResponse + 333481 Handle UCS-4 codepoints in decode and encode + 335329 Moved blocking timeout handling to outside try catch + 336668 policy supports cert validation diff --git a/jetty-client/src/test/java/org/eclipse/jetty/client/ProxyTunnellingTest.java b/jetty-client/src/test/java/org/eclipse/jetty/client/ProxyTunnellingTest.java index 6557f535f4c..5bd0eca7ab1 100644 --- a/jetty-client/src/test/java/org/eclipse/jetty/client/ProxyTunnellingTest.java +++ b/jetty-client/src/test/java/org/eclipse/jetty/client/ProxyTunnellingTest.java @@ -1,6 +1,5 @@ package org.eclipse.jetty.client; -import java.io.File; import java.io.IOException; import java.net.URLEncoder; import java.util.concurrent.CountDownLatch; @@ -27,7 +26,6 @@ import org.junit.After; import org.junit.Test; import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; public class ProxyTunnellingTest @@ -41,9 +39,9 @@ public class ProxyTunnellingTest { SslSelectChannelConnector connector = new SslSelectChannelConnector(); String keyStorePath = MavenTestingUtils.getTestResourceFile("keystore").getAbsolutePath(); - connector.setKeystore(keyStorePath); - connector.setPassword("storepwd"); - connector.setKeyPassword("keypwd"); + connector.getSslContextFactory().setKeyStore(keyStorePath); + connector.getSslContextFactory().setKeyStorePassword("storepwd"); + connector.getSslContextFactory().setKeyManagerPassword("keypwd"); startServer(connector, handler); } diff --git a/jetty-continuation/src/main/java/org/eclipse/jetty/continuation/FauxContinuation.java b/jetty-continuation/src/main/java/org/eclipse/jetty/continuation/FauxContinuation.java index cede7e22af4..aec87a1ea57 100644 --- a/jetty-continuation/src/main/java/org/eclipse/jetty/continuation/FauxContinuation.java +++ b/jetty-continuation/src/main/java/org/eclipse/jetty/continuation/FauxContinuation.java @@ -259,7 +259,6 @@ class FauxContinuation implements FilteredContinuation */ public boolean enter(ServletResponse response) { - _response=response; return true; } diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/AsyncContinuation.java b/jetty-server/src/main/java/org/eclipse/jetty/server/AsyncContinuation.java index adb8e0b86d9..bf889baa8e6 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/AsyncContinuation.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/AsyncContinuation.java @@ -791,13 +791,14 @@ public class AsyncContinuation implements AsyncContext, Continuation /* ------------------------------------------------------------ */ /** + * Unlike {@link #getResponse()}, this will return null if {@link #suspend(ServletResponse)} was not called. * @see org.eclipse.jetty.continuation.Continuation#getServletResponse() */ public ServletResponse getServletResponse() { if (_responseWrapped && _event!=null && _event.getResponse()!=null) return _event.getResponse(); - return _connection.getResponse(); + return null; } /* ------------------------------------------------------------ */