cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r580980 - /incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java
Date Mon, 01 Oct 2007 14:52:02 GMT
Author: dkulp
Date: Mon Oct  1 07:52:01 2007
New Revision: 580980

URL: http://svn.apache.org/viewvc?rev=580980&view=rev
Log:
Update to throw the same MissingResourceException if non-j.u.l logger that would be thrown
if j.u.l is used.

Modified:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java

Modified: incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java?rev=580980&r1=580979&r2=580980&view=diff
==============================================================================
--- incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java
(original)
+++ incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/common/logging/LogUtils.java
Mon Oct  1 07:52:01 2007
@@ -175,7 +175,15 @@
                         }
                     } 
                 } else {
-                    return (Logger) cns.newInstance(loggerName, BundleUtils.getBundleName(cls,
name));
+                    try {
+                        return (Logger) cns.newInstance(loggerName, BundleUtils.getBundleName(cls,
name));
+                    } catch (InvocationTargetException ite) {
+                        if (ite.getTargetException() instanceof MissingResourceException)
{
+                            throw (MissingResourceException)ite.getTargetException();
+                        } else {
+                            throw ite;
+                        }
+                    } 
                 }
             } catch (Exception e) {
                 throw new RuntimeException(e);



Mime
View raw message