Class IncomingEvent


  • public class IncomingEvent
    extends java.lang.Object
    An event that was received from a connector
    • Constructor Summary

      Constructors 
      Constructor Description
      IncomingEvent​(java.lang.String json, java.lang.String messageId)
      Constructor
    • Constructor Detail

      • IncomingEvent

        public IncomingEvent​(java.lang.String json,
                             java.lang.String messageId)
        Constructor
        Parameters:
        json - the json for the event
        messageId - identifier
    • Method Detail

      • getJson

        public java.lang.String getJson()
        Gets the json for the event
        Returns:
        Json String
      • addAsyncProcessingResult

        public void addAsyncProcessingResult​(org.odpi.openmetadata.repositoryservices.events.future.OMRSFuture future)
        Adds a Future for the processing of this event by some OMRSInstanceEventProcessor
        Parameters:
        future - the Future to add
      • setState

        public void setState​(IncomingEventState state)
        Updates the state of the event
        Parameters:
        state - the new state
      • getCreationTime

        public long getCreationTime()
        Gets the time when this IncomingEvent instance was created. This is different from the time when the message was generated.
        Returns:
        time as a long
      • getMessageId

        public java.lang.String getMessageId()
        Gets the unique message id for this event.
        Returns:
        messageId
      • hasTimeElapsedSinceCreation

        public boolean hasTimeElapsedSinceCreation​(long elapsedTimeMs)
        Checks whether the given amount of time has elapsed since the event was created
        Parameters:
        elapsedTimeMs - the elapsed time to check, in milliseconds
        Returns:
        result
      • isFullyProcessed

        public boolean isFullyProcessed()
        Checks whether all processing for this event has completed.
        Returns:
        whether all processing for this event has completed