synapse-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asan...@apache.org
Subject svn commit: r603985 - in /webservices/synapse/trunk/java/modules: core/src/main/java/org/apache/synapse/core/axis2/ transports/src/main/java/org/apache/synapse/transport/base/ transports/src/main/java/org/apache/synapse/transport/vfs/
Date Thu, 13 Dec 2007 19:04:22 GMT
Author: asankha
Date: Thu Dec 13 11:04:18 2007
New Revision: 603985

URL: http://svn.apache.org/viewvc?rev=603985&view=rev
Log:
allow an xpath xprn to even extract the whole document
do not throw an error if VFS file is not text
minor improvement of error handling for VFS

Modified:
    webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2MessageContext.java
    webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/base/AbstractTransportListener.java
    webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/vfs/VFSUtils.java

Modified: webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2MessageContext.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2MessageContext.java?rev=603985&r1=603984&r2=603985&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2MessageContext.java
(original)
+++ webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2MessageContext.java
Thu Dec 13 11:04:18 2007
@@ -22,6 +22,7 @@
 import org.apache.axiom.om.OMElement;
 import org.apache.axiom.om.impl.llom.OMElementImpl;
 import org.apache.axiom.om.impl.llom.OMTextImpl;
+import org.apache.axiom.om.impl.llom.OMDocumentImpl;
 import org.apache.axiom.om.xpath.AXIOMXPath;
 import org.apache.axiom.soap.SOAPEnvelope;
 import org.apache.axiom.soap.SOAPHeader;
@@ -475,6 +476,8 @@
                                 s = o.toString();
                             }
                             textValue.append(s);
+                        } else if (o instanceof OMDocumentImpl) {
+                            textValue.append(((OMDocumentImpl) o).getOMDocumentElement().toString());
                         }
                     }
                 } else {

Modified: webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/base/AbstractTransportListener.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/base/AbstractTransportListener.java?rev=603985&r1=603984&r2=603985&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/base/AbstractTransportListener.java
(original)
+++ webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/base/AbstractTransportListener.java
Thu Dec 13 11:04:18 2007
@@ -194,7 +194,7 @@
      */
     public void handleIncomingMessage(
         MessageContext msgCtx, Map trpHeaders,
-        String soapAction, String contentType) {
+        String soapAction, String contentType) throws AxisFault {
 
         // set the soapaction if one is available via a transport header
         if (soapAction != null) {
@@ -219,6 +219,7 @@
                 }
         } catch (AxisFault axisFault) {
             logException("Error processing received message", axisFault);
+            throw axisFault;
         }
     }
 

Modified: webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/vfs/VFSUtils.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/vfs/VFSUtils.java?rev=603985&r1=603984&r2=603985&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/vfs/VFSUtils.java
(original)
+++ webservices/synapse/trunk/java/modules/transports/src/main/java/org/apache/synapse/transport/vfs/VFSUtils.java
Thu Dec 13 11:04:18 2007
@@ -73,8 +73,10 @@
                 getBytesFromInputStream(getInputStream(message),
                 (int) ((FileContent) message).getSize()));
         } catch (Exception e) {
-            handleException("Error reading message payload as text for : " +
+            if (log.isDebugEnabled()) {
+                log.debug("Error reading message payload as text for : " +
                 ((FileContent) message).getFile().getName(), e);
+            }
         }
         return null;
     }



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


Mime
View raw message