Class PersistedJobStatusObserverImpl

  • All Implemented Interfaces:
    PersistedJobStatusObserver

    public class PersistedJobStatusObserverImpl
    extends java.lang.Object
    implements PersistedJobStatusObserver
    Observer of persisted entities modifications that publishes events on the event bus to be consumed asynchronously by interested consumers.
    Since:
    4.0.0
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void notify​(java.lang.String jobId, JobStatus previousStatus, JobStatus currentStatus)
      Handle a notification of job status change after the latter was successfully committed to persistent storage.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • PersistedJobStatusObserverImpl

        public PersistedJobStatusObserverImpl​(GenieEventBus genieEventBus)
        Constructor.
        Parameters:
        genieEventBus - the genie event bus
    • Method Detail

      • notify

        public void notify​(java.lang.String jobId,
                           @Nullable
                           JobStatus previousStatus,
                           JobStatus currentStatus)
        Handle a notification of job status change after the latter was successfully committed to persistent storage.
        Specified by:
        notify in interface PersistedJobStatusObserver
        Parameters:
        jobId - the job unique id
        previousStatus - the previous job status, or null if this job was just created and persisted
        currentStatus - the job status that was just persisted. Guaranteed to be different than the previous.