InboundHL7 V2 Collaboration - Part 2
TheCollaboration receives the HL7 V2 message from the external using
receiveHL7message().If an exception occurs due to incomplete data and the adapter fails to
readthe data within the congured number of retries, the associated recourse action is taken. If
theexception is due to no response, the associated recourse action is taken.
Ifno exception occurs, validateHL7Message() is called, which validates the message to
determinewhether to ACK or NAK the message. Other helper methods are also called to
validatethe HL7 V2 message.
Ifthe HL7 V2 message does not pass validation, the Collaboration calls makeNak() and
sendHL7Nak()to create and send the NAK to the external system. The HL7 V2 message, with
theNAK, is archived to the error queue. If the number of consecutive NAKs sent surpasses the
maximumnumber of retries, the associated recourse action is taken.
Ifthe HL7 V2 message passes validation, the Collaboration calls makeAck() and sendHL7Ack()
tocreate and send the ACK to the external.
AboutTCP/IPHL7 V2 Collaborations
SunAdapterfor TCP/IP HL7 User's Guide • Oc tober 2009112