geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r510269 - /geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
Date Wed, 21 Feb 2007 22:20:27 GMT
Author: djencks
Date: Wed Feb 21 14:20:27 2007
New Revision: 510269

URL: http://svn.apache.org/viewvc?view=rev&rev=510269
Log:
GERONIMO-2837 3rd try, hopefully the charm.  Move jsp-detecting code to where we look at servlet
vs jsp

Modified:
    geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java

Modified: geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java?view=diff&rev=510269&r1=510268&r2=510269
==============================================================================
--- geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
Wed Feb 21 14:20:27 2007
@@ -90,11 +90,11 @@
 import org.apache.geronimo.xbeans.javaee.WebAppDocument;
 import org.apache.geronimo.xbeans.javaee.WebAppType;
 import org.apache.geronimo.xbeans.javaee.WebResourceCollectionType;
+import org.apache.xbean.finder.ClassFinder;
 import org.apache.xmlbeans.XmlCursor;
 import org.apache.xmlbeans.XmlDocumentProperties;
 import org.apache.xmlbeans.XmlException;
 import org.apache.xmlbeans.XmlObject;
-import org.apache.xbean.finder.ClassFinder;
 
 /**
  * @version $Rev$ $Date$
@@ -176,7 +176,7 @@
      * Some servlets will have multiple url patterns.  However, webservice servlets
      * will only have one, which is what this method is intended for.
      *
-     * @param webApp spec deployment descriptor
+     * @param webApp      spec deployment descriptor
      * @param contextRoot context root for web app from application.xml or geronimo plan
      * @return map of servlet names to path mapped to them.  Possibly inaccurate except for
web services.
      */
@@ -714,30 +714,30 @@
         ServletType[] servlets = webApp.getServletArray();
         for (ServletType servlet : servlets) {
             FullyQualifiedClassType cls = servlet.getServletClass();
-            Class<?> clas;
-            try {
-                clas = classLoader.loadClass(cls.getStringValue());
-            }
-            catch (ClassNotFoundException e) {
-                throw new DeploymentException("WebModuleBuilder: Could not load servlet class:
" + cls.getStringValue());
-            }
-            classes.add(clas);   
-        }
-
-        // Get all the listeners from the deployment descriptor
-        ListenerType[] listeners = webApp.getListenerArray();
-        for (ListenerType listener : listeners) {
-            FullyQualifiedClassType cls = listener.getListenerClass();
             if (cls != null) { //don't try this for jsps
                 Class<?> clas;
                 try {
                     clas = classLoader.loadClass(cls.getStringValue());
                 }
                 catch (ClassNotFoundException e) {
-                    throw new DeploymentException("WebModuleBuilder: Could not load listener
class: " + cls.getStringValue());
+                    throw new DeploymentException("WebModuleBuilder: Could not load servlet
class: " + cls.getStringValue());
                 }
                 classes.add(clas);
             }
+        }
+
+        // Get all the listeners from the deployment descriptor
+        ListenerType[] listeners = webApp.getListenerArray();
+        for (ListenerType listener : listeners) {
+            FullyQualifiedClassType cls = listener.getListenerClass();
+            Class<?> clas;
+            try {
+                clas = classLoader.loadClass(cls.getStringValue());
+            }
+            catch (ClassNotFoundException e) {
+                throw new DeploymentException("WebModuleBuilder: Could not load listener
class: " + cls.getStringValue());
+            }
+            classes.add(clas);
         }
 
         // Get all the filters from the deployment descriptor



Mime
View raw message