java.lang.Object
org.apache.sling.discovery.base.connectors.announcement.CachedAnnouncement

public class CachedAnnouncement extends Object
With SLING-3389 the Announcement itself doesn't use the created (ie timeout) field anymore (it still has it currently for backwards compatibility on the wire-level) - hence that's why there's this small in-memory wrapper object which contains an Announcement and carries a lastHeartbeat property.
  • Method Details

    • hasExpired

      public final boolean hasExpired()
    • getLastPing

      public final long getLastPing()
    • getFirstPing

      public final long getFirstPing()
    • getSecondsUntilTimeout

      public final long getSecondsUntilTimeout()
      Returns the second until the next heartbeat is expected, otherwise the timeout will hit
    • getAnnouncement

      public final Announcement getAnnouncement()