Author: indika Date: Wed Dec 17 21:44:36 2008 New Revision: 27204 URL: http://wso2.org/svn/browse/wso2?view=rev&revision=27204
Log: avoid marking suspend when a leaf endpoint is too the root endpoint as leaf endpoint cannot retry itself Modified: branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/AddressEndpoint.java branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/WSDLEndpoint.java Modified: branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/AddressEndpoint.java URL: http://wso2.org/svn/browse/wso2/branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/AddressEndpoint.java?rev=27204&r1=27203&r2=27204&view=diff ============================================================================== --- branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/AddressEndpoint.java (original) +++ branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/AddressEndpoint.java Wed Dec 17 21:44:36 2008 @@ -30,12 +30,15 @@ public class AddressEndpoint extends AbstractEndpoint { public void onFault(MessageContext synCtx) { - - // is this really a fault or a timeout/connection close etc? - if (isTimeout(synCtx)) { - getContext().onTimeout(); - } else if (isSuspendFault(synCtx)) { - getContext().onFault(); + + // is this an actual leaf endpoint + if (getParentEndpoint() != null) { + // is this really a fault or a timeout/connection close etc? + if (isTimeout(synCtx)) { + getContext().onTimeout(); + } else if (isSuspendFault(synCtx)) { + getContext().onFault(); + } } // this should be an ignored error if we get here setErrorOnMessage(synCtx, null, null); Modified: branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/WSDLEndpoint.java URL: http://wso2.org/svn/browse/wso2/branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/WSDLEndpoint.java?rev=27204&r1=27203&r2=27204&view=diff ============================================================================== --- branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/WSDLEndpoint.java (original) +++ branches/synapse/1.2.wso2v1/modules/core/src/main/java/org/apache/synapse/endpoints/WSDLEndpoint.java Wed Dec 17 21:44:36 2008 @@ -40,12 +40,17 @@ private String portName; public void onFault(MessageContext synCtx) { - // is this really a fault or a timeout/connection close etc? - if (isTimeout(synCtx)) { - getContext().onTimeout(); - } else if (isSuspendFault(synCtx)) { - getContext().onFault(); + + // is this an actual leaf endpoint + if (getParentEndpoint() != null) { + // is this really a fault or a timeout/connection close etc? + if (isTimeout(synCtx)) { + getContext().onTimeout(); + } else if (isSuspendFault(synCtx)) { + getContext().onFault(); + } } + setErrorOnMessage(synCtx, null, null); super.onFault(synCtx); } _______________________________________________ Esb-java-dev mailing list [email protected] https://wso2.org/cgi-bin/mailman/listinfo/esb-java-dev
