Author: dkulp
Date: Tue Apr 22 13:37:23 2008
New Revision: 650642
URL: http://svn.apache.org/viewvc?rev=650642&view=rev
Log:
Update the exception log to include the classnames.
Modified:
incubator/cxf/trunk/api/src/main/java/org/apache/cxf/phase/PhaseInterceptorChain.java
Modified:
incubator/cxf/trunk/api/src/main/java/org/apache/cxf/phase/PhaseInterceptorChain.java
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/api/src/main/java/org/apache/cxf/phase/PhaseInterceptorChain.java?rev=650642&r1=650641&r2=650642&view=diff
==============================================================================
---
incubator/cxf/trunk/api/src/main/java/org/apache/cxf/phase/PhaseInterceptorChain.java
(original)
+++
incubator/cxf/trunk/api/src/main/java/org/apache/cxf/phase/PhaseInterceptorChain.java
Tue Apr 22 13:37:23 2008
@@ -31,6 +31,7 @@
import java.util.logging.Logger;
import org.apache.cxf.common.logging.LogUtils;
+import org.apache.cxf.interceptor.Fault;
import org.apache.cxf.interceptor.Interceptor;
import org.apache.cxf.interceptor.InterceptorChain;
import org.apache.cxf.message.FaultMode;
@@ -223,16 +224,23 @@
if (!faultOccurred) {
faultOccurred = true;
-
+
FaultMode mode = message.get(FaultMode.class);
if (mode == FaultMode.CHECKED_APPLICATION_FAULT) {
if (LOG.isLoggable(Level.FINE)) {
LogUtils.log(LOG, Level.FINE,
"Application has thrown exception,
unwinding now", ex);
} else if (LOG.isLoggable(Level.INFO)) {
+ Throwable t = ex;
+ if (ex instanceof Fault
+ && ex.getCause() != null) {
+ t = ex.getCause();
+ }
+
LogUtils.log(LOG, Level.INFO,
- "Application has thrown exception,
unwinding now: "
- + ex.getMessage());
+ "Application has thrown exception,
unwinding now: "
+ + t.getClass().getName()
+ + ": " + ex.getMessage());
}
} else if (LOG.isLoggable(Level.INFO)) {
if (mode == FaultMode.UNCHECKED_APPLICATION_FAULT) {