web stats
How to manage WebService Sender failover - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 05-11-2018, 04:07 AM
eliancitomix eliancitomix is offline
Mirth Newb
 
Join Date: Apr 2018
Posts: 7
eliancitomix is on a distinguished road
Default How to manage WebService Sender failover

Hi,

Iīm in Mirth 3.5.2 and have the next scenario:

1 Channel with:

Destination #1: WebService Sender
Destination #2: File Writer Connector

I perform a WS call, and manage the responseMap.getMessage() value from destination #1 in the destination #2.

But I donīt know how to manage the error returned from destination #1 when the WS is down.

Can anybody help me with this?

Thanks in advance.
Reply With Quote
  #2  
Old 05-11-2018, 05:17 AM
siddharth siddharth is offline
Mirth Guru
 
Join Date: Feb 2013
Posts: 724
siddharth is on a distinguished road
Default

Since you are using the inbuilt Web Service Sender, I recommend turn on queue on failure. That way when the WSDL is down, the message can get queued to be retried after few seconds, and again until it is clear without manual intervention.

The other way to get that done is through manually setting the status to QUEUED from the response transformer with a script.

Code:
if(responseStatus == ERROR) 
responseStatus=QUEUED;
Notice that, ERROR, QUEUED, SENT are enums so they need be typed exactly like that.
There are many things you could do apart from this in the response transformer though.

Forgot to mention, the second destination need to be waiting on the first. Otherwise, it will execute regardless of the status in the first destination.
__________________
HL7v2.7 Certified Control Specialist!

Last edited by siddharth; 05-11-2018 at 05:19 AM. Reason: foo
Reply With Quote
  #3  
Old 05-15-2018, 03:50 AM
eliancitomix eliancitomix is offline
Mirth Newb
 
Join Date: Apr 2018
Posts: 7
eliancitomix is on a distinguished road
Default

Thanks it solved it!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 10:27 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Mirth Corporation