web stats
Send messages with error to a different channel - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 11-23-2011, 02:30 PM
santony santony is offline
Mirth Newb
 
Join Date: Aug 2011
Location: Ellicott City
Posts: 7
santony is on a distinguished road
Default Send messages with error to a different channel

I'm trying to redirect all messages with errors from my channel to a different channel.
My source connector has 1 filter and 17 transformers (both mapper and javascript)
1 destination.
I tried researching the forum and haven't found a good method to do it.

Progress:
I've been able to capture errors from the destination by using the postprocessor. However I've no idea how to capture errors from transformers in the source connector.

Since in the configuration there is setting which asks me to 'save only error messages', I believe there is an easy way to do this.
Could someone point me in the right direction?
Thanks,
Sandeep
Reply With Quote
  #2  
Old 11-24-2011, 12:10 AM
asulis asulis is offline
Mirth Guru
 
Join Date: Dec 2006
Location: Cagliari, Sardinia, Italy
Posts: 210
asulis is an unknown quantity at this point
Default

Hi santony,
I suppose that you are talking about errors that are not dependent by the destination but at your transformer level. One solution, but I don't think if it fits with your situation, could be to control exceptions with a try/catch in your javascript code, then throw an exception when needed, redirecting all information causing the error in the transformer to the other channel using the route message to channel function.

Regards
Alessandro
Reply With Quote
Reply

Tags
error handling

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 07:29 AM.


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