From: James A. <ja...@ja...> - 2014-03-05 15:07:16
|
Hi Tom, Your first question is well timed. The new 2.2 release just introduced the ability for you to configure servers to not send any ACK/NAK message in response when an application exception is detected in the processing code. This wasn't designed with your exact use case in mind, but I believe it should meet your needs. Unfortunately enhanced mode support is not great in HAPI. I think there is some support that was contributed at one point in the deprocated .protocol.* packages but I haven't ever used it. Possibly someone else on the list could speak to that.. Really what would be idea would be for someone to have a go at adding support into the main server implementation. I imagine it wouldn't be too hard, but it wouldn't be trivial either. Help welcome! :) Cheers, James On Tue, Mar 4, 2014 at 5:49 PM, Tom Wilson <tw...@su...> wrote: > > > Hi. I am trying to implement enhanced ACK mode with HAPI and encountered > the same problem described here: > > > > > https://www.mail-archive.com/hl7api-devel%40lists.sourceforge.net/msg01398.html > > > > I am testing a system which receives ORU messages, does some processing, > and sends an asynchronous ACK (enhanced mode) back to the sending system. > > > > Two things I want to accomplish: > > > > 1) Implement a HAPI server which will receive ORU messages, and > optionally return an accept ACK. It appears that it is not possible to omit > the accept ACK. How do I implement the processMessage method to not send an > accept ACK? If I simply return null, HAPI throws an exception and returns > its own NACK: > MSH|^~\&|||||20140304142506.948-0800||ACK^R01^ACK|502|D|2.5.1 > MSA|AE|2013101516464300008 > ERR|||207^Application internal error^HL70357^^^^^^Message may not be null|E > > 2) For testing purposes I have several "dummy" HAPI servers which: > > a. Send HL7 ORU messages and receive ACKs asynchronously > > b. Receive HL7 ORU messages and send ACKs synchronously > > c. Print everything to stdout > > > > I don't care so much about data integrity (this is checked manually during > testing). In fact, it would be easier if I had one HAPI server that > receives ACKs and prints them to stdout without caring if the message > control ID matches a previously sent message. > > > > So is enhanced ACK mode supported? And how would that work? > > > Thanks in advance, > > > > -tom > |