Class HeartbeatEvent

  • All Implemented Interfaces:
    LoggableEvent, java.io.Serializable

    public class HeartbeatEvent
    extends AdapterLifecycleEvent
    implements LoggableEvent

    Standard Adapter heartbeat event. This class may be sub-classed to meet solution-specific heartbeat information requirements.

    In the adapter configuration file this class is aliased as heartbeat-event which is the preferred alternative to the fully qualified classname when building your configuration.

    See Also:
    Serialized Form
    • Constructor Detail

      • HeartbeatEvent

        public HeartbeatEvent()

        Creates a new instance.

    • Method Detail

      • getHeartbeatTime

        public long getHeartbeatTime()

        Returns the time this event was sent.

        Returns:
        a long representing the time this event was sent
      • setHeartbeatTime

        public void setHeartbeatTime​(long l)

        Sets the time this event was sent.

        Parameters:
        l - a long representing the time this event was sent
      • extractState

        public void extractState​(Adapter adapter)

        Extracts a report on the Adapter's current state.

        Parameters:
        adapter - the Adapter to extract state from
      • getAdapterStateSummary

        public AdapterStateSummary getAdapterStateSummary()

        Return the AdapterStateSummary.

        Returns:
        the AdapterStateSummary
      • setAdapterStateSummary

        public void setAdapterStateSummary​(AdapterStateSummary a)

        Sets the AdapterStateSummary.

        Parameters:
        a - the AdapterStateSummary
      • logEvent

        public void logEvent​(org.slf4j.Logger logger)
        Specified by:
        logEvent in interface LoggableEvent