Class Hl7v2Protocol


public final class Hl7v2Protocol extends Protocol
Inbound HL7 v2 source: runs an MLLP server, parses received ORU/ADT messages and publishes their observations onto the bus in the standard "<className>.<deviceID>.<channelID>.parsed" convention, so existing reactors and dispatchers consume external data transparently.
  • Constructor Details

    • Hl7v2Protocol

      public Hl7v2Protocol(String id, EventBus eventBus, int port, String mappingPath, String inboundDeviceId, boolean ingestADT)
      Parameters:
      id - the service id
      eventBus - the event bus
      port - MLLP listen port (0 for an ephemeral port; see getPort())
      mappingPath - path to the interop mapping JSON
      inboundDeviceId - device id used for inbound channels whose mapping key has no device
      ingestADT - whether to publish ADT patient demographics
  • Method Details

    • connect

      public void connect()
      Description copied from class: Protocol
      Establishes a connection using the specific protocol implementation and starts the configured data export. Concrete subclasses must provide the logic for connecting.
      Specified by:
      connect in class Protocol
    • getPort

      public int getPort()
      Returns:
      the actual bound port (useful when constructed with port 0).
    • stop

      public void stop()
      Description copied from class: Service
      Stops the service.

      By default, this method logs a message indicating that no stop logic is implemented. Subclasses should override this method to provide custom shutdown behavior when necessary.

      Overrides:
      stop in class Service