Package org.apache.bookkeeper.meta.zk
Class ZKMetadataBookieDriver
- java.lang.Object
-
- org.apache.bookkeeper.meta.zk.ZKMetadataDriverBase
-
- org.apache.bookkeeper.meta.zk.ZKMetadataBookieDriver
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,MetadataBookieDriver
public class ZKMetadataBookieDriver extends ZKMetadataDriverBase implements MetadataBookieDriver
ZooKeeper based metadata bookie driver.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) ServerConfiguration
serverConf
-
Fields inherited from class org.apache.bookkeeper.meta.zk.ZKMetadataDriverBase
acls, conf, disableHealthCheckPath, layoutManager, ledgersRootPath, lmFactory, metadataServiceAvailable, ownZKHandle, SCHEME, statsLogger, zk
-
-
Constructor Summary
Constructors Constructor Description ZKMetadataBookieDriver()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
RegistrationManager
createRegistrationManager()
Create the registration manager used for registering/unregistering bookies.MetadataBookieDriver
initialize(ServerConfiguration conf, StatsLogger statsLogger)
Initialize the metadata driver.(package private) ZKRegistrationManager
newZKRegistrationManager(ServerConfiguration serverConf, org.apache.zookeeper.ZooKeeper zk)
-
Methods inherited from class org.apache.bookkeeper.meta.zk.ZKMetadataDriverBase
disableHealthCheck, enableHealthCheck, getLayoutManager, getLedgerManagerFactory, getScheme, getZk, getZKServersFromServiceUri, initialize, isHealthCheckEnabled, resolveLedgerManagerFactory, resolveZkLedgersRootPath, resolveZkServers, setZk
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.bookkeeper.meta.MetadataBookieDriver
disableHealthCheck, enableHealthCheck, getLayoutManager, getLedgerManagerFactory, getScheme, isHealthCheckEnabled
-
-
-
-
Field Detail
-
serverConf
ServerConfiguration serverConf
-
-
Method Detail
-
initialize
public MetadataBookieDriver initialize(ServerConfiguration conf, StatsLogger statsLogger) throws MetadataException
Description copied from interface:MetadataBookieDriver
Initialize the metadata driver.- Specified by:
initialize
in interfaceMetadataBookieDriver
- Parameters:
conf
- configurationstatsLogger
- stats logger- Returns:
- metadata driver
- Throws:
MetadataException
-
createRegistrationManager
public RegistrationManager createRegistrationManager()
Description copied from interface:MetadataBookieDriver
Create the registration manager used for registering/unregistering bookies.- Specified by:
createRegistrationManager
in interfaceMetadataBookieDriver
- Returns:
- the registration manager used for registering/unregistering bookies.
-
newZKRegistrationManager
ZKRegistrationManager newZKRegistrationManager(ServerConfiguration serverConf, org.apache.zookeeper.ZooKeeper zk)
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfaceMetadataBookieDriver
- Overrides:
close
in classZKMetadataDriverBase
-
-