This example shows how you can perform all the message processing for a message in an LLP Listener script. This solution is only suitable when you have very simple processing and want to keep everything in the one script (with your custom ACK code). The advantage is you only have a single script to maintain.
To do this you simply do all the processing in LLP Listener, before you send the ACK message.
Tip: See the articles in the Architecture Section for best practices on structuring your interfaces
Using the Code [top]
- Import the HL7: Process immediately channel from the Builtin: Iguana Protocols repository
- Experiment with the code to find out how it works
- Adapt the code to your own requirements
- Add any processing code in the LLP Listener script, before you send the ACK message
- Interactive scripting help is included for this module
This is the github code for the main module:
How it works [top]
This is basically a way to keep all the message processing code in one place, in the LLP Listener script. This is only recommended for very basic processing requirements, if you have more complex requirements it is better to queue messages and process them in the Filter and/or Destination components.
A picture is worth a thousand words, your LLP Listener script would look similar to this: