Class FHIRNotificationNATSPublisher
- java.lang.Object
-
- org.linuxforhealth.fhir.server.notifications.nats.FHIRNotificationNATSPublisher
-
- All Implemented Interfaces:
FHIRNotificationSubscriber
public class FHIRNotificationNATSPublisher extends java.lang.Object implements FHIRNotificationSubscriber
This class implements the FHIR server notification service via a NATS channel.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedFHIRNotificationNATSPublisher()FHIRNotificationNATSPublisher(java.lang.String clusterId, java.lang.String channelName, java.lang.String clientId, java.lang.String servers, java.util.Properties tlsProps)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidnotify(FHIRNotificationEvent event)Publishes an event to NATS.voidshutdown()Performs any necessary "shutdown" logic to disconnect from the channel.
-
-
-
Constructor Detail
-
FHIRNotificationNATSPublisher
protected FHIRNotificationNATSPublisher()
-
FHIRNotificationNATSPublisher
public FHIRNotificationNATSPublisher(java.lang.String clusterId, java.lang.String channelName, java.lang.String clientId, java.lang.String servers, java.util.Properties tlsProps)
-
-
Method Detail
-
shutdown
public void shutdown()
Performs any necessary "shutdown" logic to disconnect from the channel.
-
notify
public void notify(FHIRNotificationEvent event) throws FHIRNotificationException
Publishes an event to NATS.- Specified by:
notifyin interfaceFHIRNotificationSubscriber- Throws:
FHIRNotificationException
-
-