Testing

Finally, you can either test your example by starting Mule® from the command line or, more easily, start your schema directly from Saddle:

The project for this tutorial contains three different workflows (our use cases). For starting a workflow from Saddle, the tab containing the workflow has to be visible.

Each workflow communicates with external applications via MLLP. These external applications have to be simulated for testing our workflows. If an external application acts as a source, it has to be simulated by an MLLP client, otherwise as MLLP server.

In your Saddle installation, you will find a sub-folder called utilities. This subfolder contains a command line tool called “HL7Tester”, which is able to simulate an MLLP client or server.

A sample call of HL7Tester in client mode:
java -cp HL7Tester.jar lu.tudor.santec.hl7.HL7Client -host localhost -port 12345 -file ”ADT_A01_M.txt” -save ”D:\Response.txt”

A sample call of HL7Tester in server mode:
java -cp HL7Tester.jar lu.tudor.santec.hl7.HL7Server -port 54321 -file ”ACK.txt”

Calling java -cp HL7Tester.jar lu.tudor.santec.hl7.HL7Client or java -cp HL7Tester.jar lu.tudor.santec.hl7.HL7Server with the parameter -h will print a help text, detailing the available options for the client and server.

The folder of this tutorial contains a subfolder called “TestMessages”. This folder contains 3 sample HL7 messages that can be used with HL7Tester:

Name Description
ACK Sample Acknowledgement (Acceptance)
ADT_A01_F Sample ADT-A01 message (Admission) for a female patient
 ADT_A01_M Sample ADT-A01 message (Admission) for a male patient

The HL7 inbound endpoints of our workflows are configured to listen at port 12345. The HL7 outbound endpoints will connect to port 54321.

  1. Open the workflow you like to start with Mule by double-clicking it.
  2. Press the “Launch Mule”-button () in the button bar to start the configuration in Mule. The stop button () next to it stops the running Mule instance.
  3. If required by the configuration, start an instance of the HL7Tester in server mode.
  4. Start an instance of the HL7Tester in client mode.

 

Workflow Client mode message Server mode message
Message modification ADT_A01_F or ADT_A01_M ACK
Message and ACK modification ADT_A01_F or ADT_A01_M ACK
 ACK generation in service

ADT_A01_F  to receive ACK
ADT_A01_M to receive NAK

-

 

Saddle provides both Mule’s server and application log in the output console, don’t hesitate to have a look.