We have a raw interface that basically forwards messages from Seimens Invision to Cloverleaf on to Seimens Openlink (why? a topic for another day). In any event, our Openlink server is old and very stressed these days. During an Openlink reboot, there is a short time after coming back online that the application itself is unavailable due to system resources being low with lots of stuff happening, yet the interfaces kick back on and start sending ACKs back to Cloverleaf with an AR code. At this point cloverleaf will do the 3 checks and then error until some undetermined time in the future when the application becomes available and processing resumes. This causes a problem with a variable number of messages being skipped to the error db causing the message flow to be out of sync.
From the HL7 standard, it appears the AR code is used for message validation (MSH:9, 12, and 11) but also for a failure to process for any other reason aside from message format (system down or some internal error). It states that the receiving system will be able to receive the messages at a later time.
So my question is, how can the same ACK code of AR mean 2 mutually exclusive things? If the MSH checks fail, thats a bad message and simply resending the message is not going to fix the problem, therefore I would want to skip the message and move on. But on the flipside, if the receiver is sending AR to ask the sender to resend at a later time, how am I supposed to know the difference between the conditions sending the AR? Confused? I am. At this point, my solution involves a new server for Openlink, which should avoid the low system resource situation.