You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@synapse.apache.org by Abid Khan-EXT <Ab...@jeppesen.com> on 2010/09/24 20:13:12 UTC

HTTP 400s & 500s not handled properly

Hello all,

I am running in a scenario where I need to retry sending if the send mediator failed to send, it appears that if the receiver sends 400 or 500 http error code synapse seem to believe that is a valid response and considers the message has been delivered, hence does not invoke "onError" sequence.

If above is supported out of the box, I need to know what am I doing wrong.

Thanks & Regards,

Abid Khan
Java Consultant
Jeppesen (Software Product Development)
Desk: 303.328.6554 | Cell: 720.480.3523
<Promotor of simple solutions, even rocket science can be simplified.>



Re: HTTP 400s & 500s not handled properly

Posted by Rajika Kumarasiri <ra...@wso2.com>.
On Fri, Sep 24, 2010 at 11:43 PM, Abid Khan-EXT <Ab...@jeppesen.com>wrote:

> Hello all,
>
> I am running in a scenario where I need to retry sending if the send
> mediator failed to send, it appears that if the receiver sends 400 or 500
> http error code synapse seem to believe that is a valid response and
> considers the message has been delivered, hence does not invoke "onError"
> sequence.
>

400, 500 are valid reposes for Synpase so what it does is it'll forward the
messages to the client back. What actually Synapse detects as errors are
connection refused, connection time out etc.. See the constants class for
valid error codes[1]. Upon receiving one of these errors Synapse will
execute the fault/onError sequence.

Rajika

[1] -
https://svn.apache.org/repos/asf/synapse/trunk/java/modules/transports/core/nhttp/src/main/java/org/apache/synapse/transport/nhttp/NhttpConstants.java


>
> If above is supported out of the box, I need to know what am I doing wrong.
>
> Thanks & Regards,
>
> Abid Khan
> Java Consultant
> Jeppesen (Software Product Development)
> Desk: 303.328.6554 | Cell: 720.480.3523
> <Promotor of simple solutions, even rocket science can be simplified.>
>
>
>