Reputation: 103
I hitting multiple url in http requestor in mulesoft
For example:-abc.com
def.com
ghy.com
xyz.com
But in "def.com" I am getting connection time out error(no response code is coming) and i know because site is down but once i got this error my flow got stopped and not going forward for another website i.e "ghy.com" etc..
Can you please tell me how to make flow in continue processing even i got connection time out for particular website
I have tried catch exception strategy but i caught this exception but not able the proceed the flow.
Upvotes: 1
Views: 2242
Reputation: 475
Do the following.
The catch exception should handle the error on private flow, and when it returns to original flow (calling flow), it should continue processing.
EDIT
Here's what I mean. test2Flow is the main flow, then you got foreach
component somewhere there. It will call a private flow.
The private flow does the HTTP request call where the URL comes from payload. It has catch exception strategy to handle errors from this HTTP request.
Here, foreach
loop should not stop when error occurred inside the private flow.
<http:request-config name="HTTP_Request_Configuration" host="#[payload.url]" port="#[payload.port]" doc:name="HTTP Request Configuration"/>
<flow name="test2Flow">
<!--get list -->
<foreach doc:name="For Each">
<flow-ref name="payload" doc:name="Flow Reference"/>
</foreach>
</flow>
<flow name="test2Flow1">
<http:request config-ref="HTTP_Request_Configuration" path="/" method="GET" doc:name="HTTP"/>
<!-- store response -->
<catch-exception-strategy doc:name="Catch Exception Strategy">
<logger level="INFO" doc:name="Logger"/>
</catch-exception-strategy>
</flow>
Upvotes: 1