axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r479513 - /webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java
Date Mon, 27 Nov 2006 04:28:35 GMT
Author: dims
Date: Sun Nov 26 20:28:34 2006
New Revision: 479513

URL: http://svn.apache.org/viewvc?view=rev&rev=479513
Log:
Part of fix for  AXIS2-1769 - close the xmlstreamreader, add a servlet init param option to
switch it off if someone runs into trouble (to get back old behavior). "

Modified:
    webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java

Modified: webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java?view=diff&rev=479513&r1=479512&r2=479513
==============================================================================
--- webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java
(original)
+++ webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/AxisServlet.java
Sun Nov 26 20:28:34 2006
@@ -39,6 +39,7 @@
 import org.apache.axis2.util.UUIDGenerator;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.axiom.om.impl.builder.StAXBuilder;
 
 import javax.servlet.ServletConfig;
 import javax.servlet.ServletException;
@@ -291,6 +292,19 @@
                 } else {
                     throw new ServletException(t);
                 }
+            }
+        }
+        boolean closeReader = true;
+        String closeReaderParameter = servletConfig.getInitParameter("axis2.close.reader");
+        if (closeReaderParameter != null) {
+            closeReaderParameter = closeReaderParameter.trim();
+            closeReader = JavaUtils.isTrue(closeReaderParameter);
+        }
+        if(closeReader){
+            try {
+                ((StAXBuilder)msgContext.getEnvelope().getBuilder()).close();
+            } catch (Exception e){
+                log.debug(e);
             }
         }
     }



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message