Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoakim Erdfelt2015-10-07 17:40:01 -0400
committerJoakim Erdfelt2015-10-07 17:40:01 -0400
commitf2e0a46058934bcdac1f1171def00c57393aea7f (patch)
treef8c6d58d3428340e26590a87f63d3ad3b1e5e1da
parent29e64f5b1ce4d0e0322497feb10c8ce3cf93a9b1 (diff)
downloadorg.eclipse.jetty.project-f2e0a46058934bcdac1f1171def00c57393aea7f.tar.gz
org.eclipse.jetty.project-f2e0a46058934bcdac1f1171def00c57393aea7f.tar.xz
org.eclipse.jetty.project-f2e0a46058934bcdac1f1171def00c57393aea7f.zip
478752 - Clarify support for HttpServletRequest.upgrade()
+ Indicating lack of upgrade() support with ServletException
-rw-r--r--jetty-server/src/main/java/org/eclipse/jetty/server/Request.java21
1 files changed, 1 insertions, 20 deletions
diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/Request.java b/jetty-server/src/main/java/org/eclipse/jetty/server/Request.java
index 0c8a463c67..d92cb3a03e 100644
--- a/jetty-server/src/main/java/org/eclipse/jetty/server/Request.java
+++ b/jetty-server/src/main/java/org/eclipse/jetty/server/Request.java
@@ -2435,25 +2435,6 @@ public class Request implements HttpServletRequest
@Override
public <T extends HttpUpgradeHandler> T upgrade(Class<T> handlerClass) throws IOException, ServletException
{
- if (getContext() == null)
- throw new ServletException ("Unable to instantiate "+handlerClass);
-
- try
- {
- //Instantiate an instance and inject it
- T h = getContext().createInstance(handlerClass);
-
- //TODO handle the rest of the upgrade process
-
- return h;
- }
- catch (Exception e)
- {
- if (e instanceof ServletException)
- throw (ServletException)e;
- throw new ServletException(e);
- }
+ throw new ServletException("HttpServletRequest.upgrade() not supported in Jetty");
}
-
-
}

Back to the top