Why would you send an unexpected ACK back to the server?

On 31 July 2017 at 17:00, Tom Chiverton <t...@extravision.com> wrote:

> *AH HA*.
>
> There's a 3 year old bug with HAPI [1] where it throws away messages if
> they are unexpected replies.
>
> I don't see a way to replace the Receiver instance in use by SimpleServer ?
>
> Tom
>
> [1] https://sourceforge.net/p/hl7api/feature-requests/88/?limit=25
>
> On 31/07/17 14:51, Tom Chiverton wrote:
>
> Hi,
>
> Sorry I wasn't clear, but further down my RecivingApplication
> implementation I do have that :
>
> public Message processMessage(Message theMessage, Map<String, Object>
> theMetadata) throws ReceivingApplicationException, HL7Exception {
>         String encodedMessage = new DefaultHapiContext().
> getPipeParser().encode(theMessage);
>         System.out.println("Received message:\n" + encodedMessage +
> "\n\n");
>
> }
>
> This never outputs.
>
> Tom
>
> On 31/07/17 14:46, Jens Villadsen wrote:
>
> Take a look at the example found at http://hl7api.sourceforge.
> net/xref/ca/uhn/hl7v2/examples/SendAndReceiveAMessage.html and
> http://hl7api.sourceforge.net/xref/ca/uhn/hl7v2/examples/
> ExampleReceiverApplication.html
>
> What you probably would like to look at is the "processMessage"
>
>
>
>
> On 31 July 2017 at 12:05, Tom Chiverton <t...@extravision.com> wrote:
>
>> Given
>>
>>
>> public class EvReceiverApplication implements ReceivingApplication {
>>
>>     public boolean canProcess(Message theIn) {
>>         System.out.println("Received message: canProcess true");
>>         return true;
>>     }
>>
>> ....
>>
>>
>> I never see this output when a message is received. So it's like the
>> receiver is not registered ?
>>
>>
>> I am doing
>>
>>
>> HL7Service server = context.newServer(port, useTls);
>>
>> ReceivingApplication handler = new EvReceiverApplication();
>>
>> server.registerApplication("*", "*", handler);
>>
>> server.startAndWait();
>>
>> Tom
>>
>>
>> On 31/07/17 10:24, Tom Chiverton wrote:
>>
>> I have used
>> http://hl7api.sourceforge.net/xref/ca/uhn/hl7v2/examples/Sen
>> dAndReceiveAMessage.html
>>
>> to build a simple app that should listen for all messages, and echo them
>> to the console ( server.registerApplication("*", "*", handler); ).
>>
>>
>> However, although I get a line from the connectionReceived method, and
>> none from an output I added to the exceptionHandler, I do not get anything
>> from my processMessage() code.
>>
>>
>> Java 1.8 on Ubuntu Server, with the latest HAPI library. I can confirm I
>> am getting a message  (admittedly it's MSA is "MSA|AA|245635223|Failure")
>> with a Wireshark packet capture.
>>
>>
>> Any ideas what could be up ?
>> --
>> *Tom Chiverton*
>> Lead Developer
>> e:  t...@extravision.com
>> p:  0161 817 2922
>> t:  @extravision <http://www.twitter.com/extravision>
>> w:  www.extravision.com
>> [image: Extravision - email worth seeing] <http://www.extravision.com/>
>> Registered in the UK at: First floor, Tomorrow, MediaCityUK, Manchester,
>> M50 2AB.
>> Company Reg No: 0‌‌5017214 VAT: GB 8‌‌24 5386 19 <24%2053%2086%2019>
>>
>> This e-mail is intended solely for the person to whom it is addressed and
>> may contain confidential or privileged information.
>> Any views or opinions presented in this e-mail are solely of the author
>> and do not necessarily represent those of Extravision Ltd.
>>
>> ______________________________________________________________________
>> This email has been scanned by the Symantec Email Security.cloud service.
>> For more information please visit http://www.symanteccloud.com
>> ______________________________________________________________________
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>
>>
>>
>> _______________________________________________
>> Hl7api-devel mailing 
>> listHl7api-devel@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/hl7api-devel
>>
>>
>>
>> ------------------------------------------------------------
>> ------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Hl7api-devel mailing list
>> Hl7api-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/hl7api-devel
>>
>>
>
>
> --
>
> Med venlig hilsen / Kind regards
>
> *Jens Kristian Villadsen*
> cand.polyt
>
> Stålhøjen 24
> 8240 Risskov
> Denmark
>
> Mobile +4523373806 <23%2037%2038%2006>
> jenskristianvillad...@gmail.com
>
> ______________________________________________________________________
> This email has been scanned by the Symantec Email Security.cloud service.
> For more information please visit http://www.symanteccloud.com
> ______________________________________________________________________
>
>
>
> ______________________________________________________________________
> This email has been scanned by the Symantec Email Security.cloud service.
> For more information please visit http://www.symanteccloud.com
> ______________________________________________________________________
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> Hl7api-devel mailing 
> listHl7api-devel@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/hl7api-devel
>
>
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Hl7api-devel mailing list
> Hl7api-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/hl7api-devel
>
>


-- 

Med venlig hilsen / Kind regards

*Jens Kristian Villadsen*
cand.polyt

Stålhøjen 24
8240 Risskov
Denmark

Mobile +4523373806
jenskristianvillad...@gmail.com
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Hl7api-devel mailing list
Hl7api-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hl7api-devel

Reply via email to