public class ZooKeeperLeaderElectionDriverFactory extends Object implements LeaderElectionDriverFactory
ZooKeeperLeaderElectionDriver
.Constructor and Description |
---|
ZooKeeperLeaderElectionDriverFactory(org.apache.flink.shaded.curator5.org.apache.curator.framework.CuratorFramework curatorFramework) |
Modifier and Type | Method and Description |
---|---|
ZooKeeperLeaderElectionDriver |
create(LeaderElectionDriver.Listener leaderElectionListener)
Creates a
LeaderElectionDriver for the given leader contender description. |
public ZooKeeperLeaderElectionDriverFactory(org.apache.flink.shaded.curator5.org.apache.curator.framework.CuratorFramework curatorFramework)
public ZooKeeperLeaderElectionDriver create(LeaderElectionDriver.Listener leaderElectionListener) throws Exception
LeaderElectionDriverFactory
LeaderElectionDriver
for the given leader contender description. Moreover,
it registers the given leader election listener with the service.create
in interface LeaderElectionDriverFactory
leaderElectionListener
- listener for the callbacks of the LeaderElectionDriver
LeaderElectionDriver
instanceException
- if the creation failsCopyright © 2014–2024 The Apache Software Foundation. All rights reserved.