geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r774253 - in /geronimo/sandbox/djencks/jetty7: geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/ geronimo-jetty7/src/main...
Date Wed, 13 May 2009 08:52:41 GMT
Author: djencks
Date: Wed May 13 08:52:41 2009
New Revision: 774253

URL: http://svn.apache.org/viewvc?rev=774253&view=rev
Log:
update to latest jetty changes, not really tested yet

Modified:
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/AbstractClusteredPreHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ClusteredSessionHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/WADIClusteredPreHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/JettyEJBWebServiceContext.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ComponentContextHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/InstanceContextHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/JettySecurityHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ThreadClassloaderHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/TwistyWebAppContext.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/UserTransactionHandler.java
    geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/test/java/org/apache/geronimo/jetty7/ApplicationTest.java

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/AbstractClusteredPreHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/AbstractClusteredPreHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/AbstractClusteredPreHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/AbstractClusteredPreHandler.java
Wed May 13 08:52:41 2009
@@ -26,15 +26,16 @@
 import org.apache.geronimo.clustering.ClusteredInvocationException;
 import org.apache.geronimo.jetty7.AbstractPreHandler;
 import org.eclipse.jetty.io.HttpException;
+import org.eclipse.jetty.server.Request;
 
 /**
  * @version $Rev$ $Date$
  */
 public abstract class AbstractClusteredPreHandler extends AbstractPreHandler {
 
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response)
             throws IOException, ServletException {
-        ClusteredInvocation invocation = newClusteredInvocation(target, request, response);
+        ClusteredInvocation invocation = newClusteredInvocation(target, baseRequest, request,
response);
         try {
             invocation.invoke();
         } catch (ClusteredInvocationException e) {
@@ -50,23 +51,25 @@
     }
 
     protected abstract ClusteredInvocation newClusteredInvocation(String target,
-                                                                  HttpServletRequest request,
HttpServletResponse response);
+                                                                  Request baseRequest, HttpServletRequest
request, HttpServletResponse response);
 
 
     protected abstract class WebClusteredInvocation implements ClusteredInvocation {
         protected final String target;
+        protected final Request baseRequest;
         protected final HttpServletRequest request;
         protected final HttpServletResponse response;
 
-        protected WebClusteredInvocation(String target, HttpServletRequest request, HttpServletResponse
response) {
+        protected WebClusteredInvocation(String target, Request baseRequest, HttpServletRequest
request, HttpServletResponse response) {
             this.target = target;
+            this.baseRequest = baseRequest;
             this.request = request;
             this.response = response;
         }
 
         protected void invokeLocally() throws ClusteredInvocationException {
             try {
-                next.handle(target, request, response);
+                next.handle(target, baseRequest, request, response);
             } catch (IOException e) {
                 throw new ClusteredInvocationException(e);
             } catch (ServletException e) {

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ClusteredSessionHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ClusteredSessionHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ClusteredSessionHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/ClusteredSessionHandler.java
Wed May 13 08:52:41 2009
@@ -25,6 +25,7 @@
 import org.apache.geronimo.jetty7.AbstractPreHandler;
 import org.apache.geronimo.jetty7.PreHandler;
 import org.eclipse.jetty.server.session.SessionHandler;
+import org.eclipse.jetty.server.Request;
 
 /**
  *
@@ -44,26 +45,26 @@
     }
     
     @Override
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response)
             throws IOException, ServletException {
         setRequestedId(request);
         try {
-            chainedHandler.handle(target, request, response);
+            chainedHandler.handle(target, baseRequest, request, response);
         } catch (ServletException e) {
             throw (IOException) new IOException().initCause(e);
         }
     }
     
-    protected void doHandle(String target, HttpServletRequest request, HttpServletResponse
response)
+    protected void doHandle(String target, Request baseRequest, HttpServletRequest request,
HttpServletResponse response)
             throws IOException, ServletException {
-        super.handle(target, request, response);
+        super.handle(target, baseRequest, request, response);
     }
 
     private class ActualHandler extends AbstractPreHandler {
 
-        public void handle(String target, HttpServletRequest request, HttpServletResponse
response)
+        public void handle(String target, Request baseRequest, HttpServletRequest request,
HttpServletResponse response)
                 throws IOException, ServletException {
-            doHandle(target, request, response);
+            doHandle(target, baseRequest, request, response);
         }
     }
 

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/WADIClusteredPreHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/WADIClusteredPreHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/WADIClusteredPreHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7-clustering-wadi/src/main/java/org/apache/geronimo/jetty7/cluster/wadi/WADIClusteredPreHandler.java
Wed May 13 08:52:41 2009
@@ -31,6 +31,7 @@
 import org.codehaus.wadi.core.contextualiser.InvocationException;
 import org.codehaus.wadi.core.manager.Manager;
 import org.codehaus.wadi.web.impl.WebInvocation;
+import org.eclipse.jetty.server.Request;
 
 
 /**
@@ -44,16 +45,16 @@
         this.wadiManager = wadiManager;
     }
     
-    protected ClusteredInvocation newClusteredInvocation(String target, HttpServletRequest
request,
+    protected ClusteredInvocation newClusteredInvocation(String target, Request baseRequest,
HttpServletRequest request,
                                                          HttpServletResponse response) {
-        return new WADIWebClusteredInvocation(target, request, response);
+        return new WADIWebClusteredInvocation(target, baseRequest, request, response);
     }
     
     protected class WADIWebClusteredInvocation extends WebClusteredInvocation {
         
-        public WADIWebClusteredInvocation(String target, HttpServletRequest request,
+        public WADIWebClusteredInvocation(String target, Request baseRequest, HttpServletRequest
request,
                                           HttpServletResponse response) {
-            super(target, request, response);
+            super(target, baseRequest, request, response);
         }
 
         public void invoke() throws ClusteredInvocationException {

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/JettyEJBWebServiceContext.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/JettyEJBWebServiceContext.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/JettyEJBWebServiceContext.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/JettyEJBWebServiceContext.java
Wed May 13 08:52:41 2009
@@ -124,9 +124,9 @@
     {
         //TODO
         //do we need to check that this request should be handled by this handler?
-        if (! target.startsWith(contextPath)) {
-            return;
-        }
+//        if (! target.startsWith(contextPath)) {
+//            return;
+//        }
 //        Request jettyRequest = (Request) req;
         Response jettyResponse = (Response) res;
         res.setContentType("text/xml");

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ComponentContextHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ComponentContextHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ComponentContextHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ComponentContextHandler.java
Wed May 13 08:52:41 2009
@@ -27,6 +27,7 @@
 
 import org.apache.geronimo.naming.java.RootContext;
 import org.eclipse.jetty.server.Handler;
+import org.eclipse.jetty.server.Request;
 
 /**
  * @version $Rev$ $Date$
@@ -40,11 +41,11 @@
         this.componentContext = componentContext;
     }
 
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response) throws IOException, ServletException {
         Context oldContext = RootContext.getComponentContext();
         try {
             RootContext.setComponentContext(componentContext);
-            next.handle(target, request, response);
+            next.handle(target, baseRequest, request, response);
         } finally {
             RootContext.setComponentContext(oldContext);
         }

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/InstanceContextHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/InstanceContextHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/InstanceContextHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/InstanceContextHandler.java
Wed May 13 08:52:41 2009
@@ -50,14 +50,14 @@
         this.trackedConnectionAssociator = trackedConnectionAssociator;
     }
 
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response) throws IOException, ServletException {
         DispatcherType dispatch = ((Request)request).getDispatcherType();
         try {
             if (DispatcherType.REQUEST.equals(dispatch)) {
                 ConnectorInstanceContext oldContext = trackedConnectionAssociator.enter(new
SharedConnectorInstanceContext(unshareableResources, applicationManagedSecurityResources,
false));
 
                 try {
-                    next.handle(target, request, response);
+                    next.handle(target, baseRequest, request, response);
                 } finally {
                     trackedConnectionAssociator.exit(oldContext);
                 }
@@ -66,7 +66,7 @@
                 SharedConnectorInstanceContext oldContext = (SharedConnectorInstanceContext)
trackedConnectionAssociator.enter(context);
                 context.share(oldContext);
                 try {
-                    next.handle(target, request, response);
+                    next.handle(target, baseRequest, request, response);
                 } finally {
                     context.hide();
                     trackedConnectionAssociator.exit(oldContext);

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/JettySecurityHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/JettySecurityHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/JettySecurityHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/JettySecurityHandler.java
Wed May 13 08:52:41 2009
@@ -73,7 +73,7 @@
      *      javax.servlet.http.HttpServletRequest,
      *      javax.servlet.http.HttpServletResponse, int)
      */
-    public void handle(String target, HttpServletRequest request,
+    public void handle(String target, Request baseRequest, HttpServletRequest request,
                        HttpServletResponse response) throws IOException,
             ServletException {
         String old_policy_id = PolicyContext.getContextID();
@@ -83,7 +83,7 @@
             PolicyContext.setContextID(policyContextID);
             PolicyContext.setHandlerData(request);
 
-            super.handle(target, request, response);
+            super.handle(target, baseRequest, request, response);
         } finally {
             PolicyContext.setContextID(old_policy_id);
             ContextManager.popCallers(oldCallers);

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ThreadClassloaderHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ThreadClassloaderHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ThreadClassloaderHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/ThreadClassloaderHandler.java
Wed May 13 08:52:41 2009
@@ -25,6 +25,7 @@
 import javax.servlet.http.HttpServletResponse;
 
 import org.eclipse.jetty.server.Handler;
+import org.eclipse.jetty.server.Request;
 
 /**
  * @version $Rev$ $Date$
@@ -38,12 +39,12 @@
         this.classLoader = classLoader;
     }
 
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response) throws IOException, ServletException {
         Thread thread = Thread.currentThread();
         ClassLoader oldClassLoader = thread.getContextClassLoader();
         thread.setContextClassLoader(classLoader);
         try {
-            next.handle(target, request, response);
+            next.handle(target, baseRequest, request, response);
         } finally {
             thread.setContextClassLoader(oldClassLoader);
         }

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/TwistyWebAppContext.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/TwistyWebAppContext.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/TwistyWebAppContext.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/TwistyWebAppContext.java
Wed May 13 08:52:41 2009
@@ -28,6 +28,7 @@
 
 import org.eclipse.jetty.server.Handler;
 import org.eclipse.jetty.server.Server;
+import org.eclipse.jetty.server.Request;
 import org.eclipse.jetty.server.handler.ErrorHandler;
 import org.eclipse.jetty.security.SecurityHandler;
 import org.eclipse.jetty.servlet.ServletHandler;
@@ -56,14 +57,14 @@
     }
 
     @Override
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
-        handler.handle(target, request, response);
+    public void doHandle(String target, Request baseRequest, HttpServletRequest request,
HttpServletResponse response) throws IOException, ServletException {
+        handler.handle(target, baseRequest, request, response);
     }
 
     private class TwistyHandler implements Handler {
 
-        public void handle(String target, HttpServletRequest request, HttpServletResponse
response) throws IOException, ServletException {
-            TwistyWebAppContext.super.handle(target, request, response);
+        public void handle(String target, Request baseRequest, HttpServletRequest request,
HttpServletResponse response) throws IOException, ServletException {
+            TwistyWebAppContext.super.doHandle(target, baseRequest, request, response);
         }
 
         public void setServer(Server server) {

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/UserTransactionHandler.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/UserTransactionHandler.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/UserTransactionHandler.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/main/java/org/apache/geronimo/jetty7/handler/UserTransactionHandler.java
Wed May 13 08:52:41 2009
@@ -45,10 +45,10 @@
         this.userTransaction = userTransaction;
     }
 
-    public void handle(String target, HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
+    public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse
response) throws IOException, ServletException {
         boolean active = isActive();
         try {
-            next.handle(target, request, response);
+            next.handle(target, baseRequest, request, response);
         } finally {
              DispatcherType dispatch = ((Request)request).getDispatcherType();
              if ((!active && isMarkedRollback()) || (DispatcherType.REQUEST.equals(dispatch)
&& isActive())) {

Modified: geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/test/java/org/apache/geronimo/jetty7/ApplicationTest.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/test/java/org/apache/geronimo/jetty7/ApplicationTest.java?rev=774253&r1=774252&r2=774253&view=diff
==============================================================================
--- geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/test/java/org/apache/geronimo/jetty7/ApplicationTest.java
(original)
+++ geronimo/sandbox/djencks/jetty7/geronimo-jetty7/src/test/java/org/apache/geronimo/jetty7/ApplicationTest.java
Wed May 13 08:52:41 2009
@@ -28,6 +28,7 @@
 import javax.servlet.http.HttpServletResponse;
 
 import org.eclipse.jetty.server.session.SessionHandler;
+import org.eclipse.jetty.server.Request;
 
 
 /**
@@ -65,9 +66,9 @@
         public PreHandler createHandler() {
             return new AbstractPreHandler() {
 
-                public void handle(String target, HttpServletRequest request, HttpServletResponse
response)
+                public void handle(String target, Request baseRequest, HttpServletRequest
request, HttpServletResponse response)
                         throws IOException, ServletException {
-                    next.handle(target, request, response);
+                    next.handle(target, baseRequest, request, response);
                 }
 
                 public void addLifeCycleListener(Listener listener) {



Mime
View raw message