java.lang.Object
org.opendaylight.controller.cluster.raft.client.messages.FindLeaderReply
All Implemented Interfaces:
Serializable

public final class FindLeaderReply extends Object implements Serializable
Reply to FindLeader message, containing the address of the leader actor, as known to the raft actor which sent the message. If the responding actor does not have knowledge of the leader, leaderActorPath() will return null.

This message is intended for testing purposes only.

See Also:
  • Constructor Details

    • FindLeaderReply

      public FindLeaderReply(@Nullable String leaderActorPath)
      Default constructor. Takes an ActorPath in its string form.
      Parameters:
      leaderActorPath - an ActorPath's toString()
    • FindLeaderReply

      public FindLeaderReply(@Nullable org.apache.pekko.actor.ActorPath leaderActorPath)
      Convenience constructor translating an ActorPath to its string form.
      Parameters:
      leaderActorPath - the optional ActorPath
  • Method Details

    • leaderActorPath

      public @Nullable String leaderActorPath()
      Returns the actor reference to the leader, or null if no leader is known.
      Returns:
      the actor reference to the leader, or null if no leader is known
    • getLeaderActor

      @Deprecated(since="1.0.0", forRemoval=true) @NonNull public Optional<String> getLeaderActor()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use leaderActorPath() instead.
      return the actor reference to the leader, or empty if no leader is known.
      Returns:
      the actor reference to the leader, or empty if no leader is known