Info |
---|
...
Iguana’s to LLP can only handle |
...
standard HL7 |
...
ACK messages, and is also |
...
unable to push ACK messages to channels/databases/etc. This article covers how to |
...
handle non standard/custom ACK messages in Iguana. |
Table of Contents |
---|
Design
Diagram: Traditional (From LLP/DB/File → LLP)
Diagram: From LLP/Trans → Filter Translator → Que …. go to other )
Key: net.tcp to receive HL7 ACKBelow is an example of how an old channel design can be modified to handle custom ACKs. The design is flexible and the components can be modified to suit your needs.
The old channel in this example is setup as From File → To LLP. When the to LLP component sends the HL7 file to the receiving server, it receives the custom ACK. The To LLP is only designed to handle standard ACK responses, so it is unable to handle the custom ACK and produces an error.
...
The new channel design makes use of a translator in the filter component. This filter implements the functionality of the previous designs To LLP component, while adding the ability to process custom ACK messages. In this design the channel is setup as From File → Filter → To Channel.
...
Prerequisite
This implementation makes use of iNTERFACEWARE’s llp.lua shared module. Import the LLP custom client channel from the built in Iguana tools repository to add this module to your Iguana. https://help.interfaceware.com/v6/llp-client-custom
Implementation
Instead of using a from/to LLP component, this implementation makes use of the translator environment, and the ability to make LLP calls within the translator (or filter).
...
In this example the ADR response is pushed to the queue, however the ADR response can be handled in many different ways such as writing to a file or saving to a database.
Testing Your Implementation
Creating a channel that sends a pre defined ADR response as the ACK for the purpose of testing can be beneficial to ensure your code works as expected.
...
Code Block |
---|
local FILE_PATH = 'C:\\Program Files\\iNTERFACEWARE\\Iguana\\SampleMessages\\sample_ADR.txt' function main(Data) local ACK = readFile() ack.send(ACK) end function readFile() local file = io.open(FILE_PATH,'r') local content = file:read("*all") return content end |
Limitations
Using the translator to send and receive data over LLP, the is no option to include the following SSL files:
...