开发者

Mirth: How to send ACK message to sender host and port

I am receiving lab HL7 messages from a static host and a dynamic port. For each message received I need to send a ACK message back to this host and port.

I have a destination TCP Writer channel with the correct message in there. Though the port number has to be fixed.

How do I tell Mirth to send开发者_StackOverflow社区 this message to the sending host and port?

Thanks in advance Abhi


You should configure your channel to use the LLP Listener instead, which has the option to reply with a custom HL7 ACK message. The message will be send back on the same connection so you don't have to keep track of the address of the sending system.


In Mirth you send a customized ACK message.

In Scripts, select the Postprocessor (This script executes once after a message has been processed)

and write this code

var ackString = ""; //build a javascript string for your custom ack
var ackResponse = ResponseFactory.getSuccessReponse(ackString);
responseMap.put("Custom ACK", ackResponse);

Mirth will then parse the Postprocessor script, and discovers the reponseMap code. On the source tab, go to the Send ACK radio list, you can now select "Respond from" and "Custom ACK" from the options in the dropdownlist avaiable.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜