You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by sl...@apache.org on 2007/07/26 00:34:31 UTC

svn commit: r559635 - /incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java

Author: slaws
Date: Wed Jul 25 15:34:30 2007
New Revision: 559635

URL: http://svn.apache.org/viewvc?view=rev&rev=559635
Log:
TUSCANY-1481
Lookup servlets based on the full patch name as well as path info

Modified:
    incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java

Modified: incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java?view=diff&rev=559635&r1=559634&r2=559635
==============================================================================
--- incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java (original)
+++ incubator/tuscany/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/webapp/TuscanyServlet.java Wed Jul 25 15:34:30 2007
@@ -54,7 +54,12 @@
         String path = ((HttpServletRequest)req).getPathInfo();
         Servlet servlet = servletHost.getServlet(path);
         if (servlet == null) {
-            throw new IllegalStateException("No servlet registered for path: " + path);
+            path = ((HttpServletRequest)req).getRequestURI();
+            servlet = servletHost.getServlet(path);
+            
+            if (servlet == null) {
+                throw new IllegalStateException("No servlet registered for path: " + path);
+            }
         }
 
         servlet.service(req, res);



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org