Class SubscriptionLink

java.lang.Object
io.aeron.driver.SubscriptionLink
All Implemented Interfaces:
DriverManagedResource

public abstract class SubscriptionLink extends Object implements DriverManagedResource
Subscription registration from a client used for liveness tracking.
  • Method Details

    • channel

      public final String channel()
      Channel URI the subscription is on.
      Returns:
      channel URI the subscription is on.
    • streamId

      public final int streamId()
      Stream id the subscription is on.
      Returns:
      stream id the subscription is on.
    • registrationId

      public final long registrationId()
      Registration id of the subscription.
      Returns:
      registration id of the subscription.
    • close

      public void close()
      Close resources that are not external. This will not call DriverManagedResource.free(). That will need to be called separately at the appropriate time.
      Specified by:
      close in interface DriverManagedResource
    • onTimeEvent

      public void onTimeEvent(long timeNs, long timeMs, DriverConductor conductor)
      Inform resource of timeNs passing and pass it DriverConductor to inform of any state transitions.
      Specified by:
      onTimeEvent in interface DriverManagedResource
      Parameters:
      timeNs - now in nanoseconds.
      timeMs - now in milliseconds for epoch.
      conductor - to inform of any state transitions.
    • hasReachedEndOfLife

      public boolean hasReachedEndOfLife()
      Has resource reached end of its life and should be reclaimed?
      Specified by:
      hasReachedEndOfLife in interface DriverManagedResource
      Returns:
      whether resource has reached end of life or not.
    • toString

      public String toString()
      Overrides:
      toString in class Object