geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dblev...@apache.org
Subject svn commit: r498950 - /geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
Date Tue, 23 Jan 2007 08:18:58 GMT
Author: dblevins
Date: Tue Jan 23 00:18:56 2007
New Revision: 498950

URL: http://svn.apache.org/viewvc?view=rev&rev=498950
Log:
if failure occurs assume module is not an ejb module rather than halting deployment

Modified:
    geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java

Modified: geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java?view=diff&rev=498950&r1=498949&r2=498950
==============================================================================
--- geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
Tue Jan 23 00:18:56 2007
@@ -150,28 +150,33 @@
                 return null;
             }
 
-            final ClassFinder classFinder = new ClassFinder(Thread.currentThread().getContextClassLoader(),
moduleUrl);
+            try {
+                final ClassFinder classFinder = new ClassFinder(Thread.currentThread().getContextClassLoader(),
moduleUrl);
 
-            // DMB: getting this via reflection is a temporary fix.  Just want to avoid having
to
-            // make Geronimo dependent on an xbean snapshot right before we do the release.
-            // afterwards we can clean this up.
-            Map<String, List> annotated = (Map<String, List>) AccessController.doPrivileged(new
PrivilegedAction() {
-                public Object run() {
-                    try {
-                        Field field = ClassFinder.class.getDeclaredField("annotated");
-                        field.setAccessible(true);
-                        return field.get(classFinder);
-                    } catch (Exception e2) {
+                // DMB: getting this via reflection is a temporary fix.  Just want to avoid
having to
+                // make Geronimo dependent on an xbean snapshot right before we do the release.
+                // afterwards we can clean this up.
+                Map<String, List> annotated = (Map<String, List>) AccessController.doPrivileged(new
PrivilegedAction() {
+                    public Object run() {
+                        try {
+                            Field field = ClassFinder.class.getDeclaredField("annotated");
+                            field.setAccessible(true);
+                            return field.get(classFinder);
+                        } catch (Exception e2) {
+                        }
+                        return null;
                     }
+                });
+
+                List<String> beans = new ArrayList<String>();
+                beans.addAll(annotated.get(javax.ejb.Stateless.class.getName()));
+                beans.addAll(annotated.get(javax.ejb.Stateful.class.getName()));
+                beans.addAll(annotated.get(javax.ejb.MessageDriven.class.getName()));
+                if (beans.size() <= 0){
                     return null;
                 }
-            });
-
-            List<String> beans = new ArrayList<String>();
-            beans.addAll(annotated.get(javax.ejb.Stateless.class.getName()));
-            beans.addAll(annotated.get(javax.ejb.Stateful.class.getName()));
-            beans.addAll(annotated.get(javax.ejb.MessageDriven.class.getName()));
-            if (beans.size() <= 0){
+            } catch (Throwable e) {
+                // how does one log this?
                 return null;
             }
         }



Mime
View raw message