Package fish.payara.nucleus.notification
Class NotificationService
- java.lang.Object
-
- fish.payara.nucleus.notification.NotificationService
-
- All Implemented Interfaces:
NotifierManager,EventListener,ConfigListener
@Service(name="notification-service") @RunLevel(10) @MessageReceiver public class NotificationService extends Object implements NotifierManager, EventListener, ConfigListener
Main service class that receivednotify(PayaraNotification)HK2 events, and distributes them to notifiers discovered by the service.- Author:
- mertcaliskan, Matthew Gill
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.glassfish.api.event.EventListener
EventListener.Event<T>
-
-
Constructor Summary
Constructors Constructor Description NotificationService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbootstrapNotificationService()UnprocessedChangeEventschanged(PropertyChangeEvent[] events)Notification that @Configured objects that were injected have changedvoidevent(EventListener.Event<?> event)Process a Glassfish/Payara eventvoidnotify(PayaraNotification event)voidreconfigureNotifier(PayaraNotifierConfiguration configuration)Alert the notification service that a notifier configuration has been updated with the --dynamic flag, so the notifier needs updating dynamically.voidshutdownNotificationService()
-
-
-
Method Detail
-
event
public void event(EventListener.Event<?> event)
Description copied from interface:EventListenerProcess a Glassfish/Payara event- Specified by:
eventin interfaceEventListener
-
shutdownNotificationService
public void shutdownNotificationService()
-
bootstrapNotificationService
public void bootstrapNotificationService()
-
notify
public void notify(@SubscribeTo PayaraNotification event)
-
reconfigureNotifier
public void reconfigureNotifier(PayaraNotifierConfiguration configuration)
Description copied from interface:NotifierManagerAlert the notification service that a notifier configuration has been updated with the --dynamic flag, so the notifier needs updating dynamically.- Specified by:
reconfigureNotifierin interfaceNotifierManager- Parameters:
configuration- the configuration that was updated
-
changed
public UnprocessedChangeEvents changed(PropertyChangeEvent[] events)
Description copied from interface:ConfigListenerNotification that @Configured objects that were injected have changed- Specified by:
changedin interfaceConfigListener- Parameters:
events- list of changes- Returns:
- the list of unprocessed events (requiring a restart) or null if all reconfiguration was processed successfully
-
-