Class StandaloneLeaderRetrievalService

  • All Implemented Interfaces:
    LeaderRetrievalService

    public class StandaloneLeaderRetrievalService
    extends Object
    implements LeaderRetrievalService
    Standalone implementation of the LeaderRetrievalService. This implementation assumes that there is only a single contender for leadership (e.g., a single JobManager or ResourceManager process) and that this process is reachable under a constant address.

    As soon as this service is started, it immediately notifies the leader listener of the leader contender with the pre-configured address.

    • Constructor Detail

      • StandaloneLeaderRetrievalService

        @Deprecated
        public StandaloneLeaderRetrievalService​(String leaderAddress)
        Creates a StandaloneLeaderRetrievalService with the given leader address. The leaderId will be null.
        Parameters:
        leaderAddress - The leader's pre-configured address
      • StandaloneLeaderRetrievalService

        public StandaloneLeaderRetrievalService​(String leaderAddress,
                                                UUID leaderId)
        Creates a StandaloneLeaderRetrievalService with the given leader address.
        Parameters:
        leaderAddress - The leader's pre-configured address
        leaderId - The constant leaderId.