Class SHARED_LOOPBACK_PING

All Implemented Interfaces:
Lifecycle

public class SHARED_LOOPBACK_PING extends Discovery
Discovery protocol running over SHARED_LOOPBACK only. Doesn't send discovery requests and responses, but fetches discovery information directly from SHARED_LOOPBACK. Used mainly by unit test.
Since:
3.5
  • Constructor Details

    • SHARED_LOOPBACK_PING

      public SHARED_LOOPBACK_PING()
  • Method Details

    • init

      public void init() throws Exception
      Description copied from class: Protocol
      Called after a protocol has been created and before the protocol is started. Attributes are already set. Other protocols are not yet connected and events cannot yet be sent.
      Specified by:
      init in interface Lifecycle
      Overrides:
      init in class Discovery
      Throws:
      Exception - Thrown if protocol cannot be initialized successfully. This will cause the ProtocolStack to fail, so the the channel constructor will throw an exception
    • isDynamic

      public boolean isDynamic()
      Specified by:
      isDynamic in class Discovery
    • findMembers

      public void findMembers(List<Address> members, boolean initial_discovery, Responses responses)
      Description copied from class: Discovery
      Fetches information (e.g. physical address, logical name) for the given member addresses. Needs to add responses to the Responses object. If Discovery.async_discovery is true, this method will be called in a separate thread, otherwise the caller's thread will be used.
      Specified by:
      findMembers in class Discovery
      Parameters:
      members - A list of logical addresses (typically UUIDs). If null, then information for all members is fetched
      initial_discovery - Set to true if this is for the initial membership discovery. Some protocols (e.g. file based ones) may return only the information for the coordinator(s).
      responses - The list to which responses should be added