geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r530150 - /geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java
Date Wed, 18 Apr 2007 20:45:03 GMT
Author: dims
Date: Wed Apr 18 13:45:02 2007
New Revision: 530150

URL: http://svn.apache.org/viewvc?view=rev&rev=530150
Log:
log error first, then try to send the fault back (and don't print fault on output stream when
you are trying to send back the fault)

Modified:
    geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java

Modified: geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java?view=diff&rev=530150&r1=530149&r2=530150
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java
(original)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/main/java/org/apache/geronimo/axis2/Axis2WebServiceContainer.java
Wed Apr 18 13:45:02 2007
@@ -198,6 +198,8 @@
 
             doService2(request, response, msgContext);
         } catch (Throwable e) {
+            String msg = "Exception occurred while trying to invoke service method doService()";
+            log.error(msg, e);
             try {
                 AxisEngine engine = new AxisEngine(this.configurationContext);
 
@@ -210,12 +212,6 @@
                     response.setStatusCode(202);
                 } else {
                     response.setStatusCode(500);
-                    response.setHeader(HTTPConstants.HEADER_CONTENT_TYPE, "text/plain");
-                    PrintWriter pw = new PrintWriter(response.getOutputStream());
-                    e.printStackTrace(pw);
-                    pw.flush();
-                    String msg = "Exception occurred while trying to invoke service method
doService()";
-                    log.error(msg, e);
                 }
                 engine.sendFault(faultContext);
             } catch (Exception ex) {
@@ -227,7 +223,6 @@
                     PrintWriter pw = new PrintWriter(response.getOutputStream());
                     ex.printStackTrace(pw);
                     pw.flush();
-                    String msg = "Exception occurred while trying to invoke service method
doService()";
                     log.error(msg, ex);
                 }
             }



Mime
View raw message