Announcement

Collapse

NextGen (Mirth) Connect 3.10.0 Released!

NextGen (Mirth) Connect 3.10.0 is now available as an appliance update and on our GitHub page. This release includes better SQL Server database support, security improvements through fixes and library updates, and improvements for the Advanced Clustering plugin with a focus on improving performance of many of the tasks that are carried out on a frequent interval. See the release notes for the list of fixes and updates.

Download | See What's New | Upgrade Guide | Release Notes

For discussion on this release, see this thread.
See more
See less

Questions on Channel Writer

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Questions on Channel Writer

    Hey guys

    I've been reading up on the Channel Writer in the forums but the information is limited. What does its exactly do? It seems that it can redirect the response of the channel to another channel by modifying the response map. I guess my question is how do I do that?

    This is my setup....

    1st channel
    LLP listener ---> Database Writer

    2nd channel
    Database writer ---> Channel Writer set to None(I think it should be)

    So I need to send the response of the 2nd channel to the same socket that the LLP connection in the first channel is listening to, even if its via a Custom ACK. I read post about Custom ACKs but those are done on the same Channel the listening is done.

    Thanks guys

  • #2
    Re:Questions on Channel Writer

    UPDATE:

    Looks like I can use something like this. Of course I'm not getting a ACK though.

    Code:
    var responseVal = responseMap.get('Mirth_2_Gateway');
    globalMap.put('custom_ack', ResponseFactory.getSuccessResponse('responseVal'));
    I put this in a Javascript Transformer under Destinations tab. I now see "custom_ack" in the drop down menu "Response From", under the other channel I want for to send this message to go to, But I do not get a ACK. Is "var responseVal = responseMap.get('Mirth_2_Gateway') ;" the rite way to get the encoded data to pass to the globalMap?

    Thanks

    Comment


    • #3
      Re:Questions on Channel Writer

      This is the code I use to generate a Response:

      soapResponseObject=ResponseFactory.getFailureRespo nse('someFailureMessage');
      responseMap.put('Soap Response',soapResponseObject);

      If you look in the mappings tab in the dashboard for your destination you should see the set response - which is the one you put in the dropdown....

      Looking at your first post I think you want a second destination for the LLP listener and send the response from 1 channel - you can have multiple destinations for a channel - it should then reply on that port.

      Comment

      Working...
      X