Class ZKCuratorManager.HadoopZookeeperFactory

java.lang.Object
org.apache.hadoop.util.curator.ZKCuratorManager.HadoopZookeeperFactory
All Implemented Interfaces:
org.apache.curator.utils.ZookeeperFactory
Enclosing class:
ZKCuratorManager

public static class ZKCuratorManager.HadoopZookeeperFactory extends Object implements org.apache.curator.utils.ZookeeperFactory
  • Field Details

  • Constructor Details

    • HadoopZookeeperFactory

      public HadoopZookeeperFactory(String zkPrincipal)
      Constructor for the helper class to configure the ZooKeeper client connection.
      Parameters:
      zkPrincipal - Optional.
    • HadoopZookeeperFactory

      public HadoopZookeeperFactory(String zkPrincipal, String kerberosPrincipal, String kerberosKeytab)
      Constructor for the helper class to configure the ZooKeeper client connection.
      Parameters:
      zkPrincipal - Optional.
      kerberosPrincipal - Optional. Use along with kerberosKeytab.
      kerberosKeytab - Optional. Use along with kerberosPrincipal.
    • HadoopZookeeperFactory

      public HadoopZookeeperFactory(String zkPrincipal, String kerberosPrincipal, String kerberosKeytab, boolean sslEnabled, SecurityUtil.TruststoreKeystore truststoreKeystore)
      Constructor for the helper class to configure the ZooKeeper client connection.
      Parameters:
      zkPrincipal - Optional.
      kerberosPrincipal - Optional. Use along with kerberosKeytab.
      kerberosKeytab - Optional. Use along with kerberosPrincipal.
      sslEnabled - Flag to enable SSL/TLS ZK client connection for each component independently.
      truststoreKeystore - TruststoreKeystore object containing the keystoreLocation, keystorePassword, truststoreLocation, truststorePassword for SSL/TLS connection when sslEnabled is set to true.
  • Method Details

    • newZooKeeper

      public org.apache.zookeeper.ZooKeeper newZooKeeper(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher, boolean canBeReadOnly) throws Exception
      Specified by:
      newZooKeeper in interface org.apache.curator.utils.ZookeeperFactory
      Throws:
      Exception
    • newZooKeeper

      public org.apache.zookeeper.ZooKeeper newZooKeeper(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher, boolean canBeReadOnly, org.apache.zookeeper.client.ZKClientConfig zkClientConfig) throws Exception
      Specified by:
      newZooKeeper in interface org.apache.curator.utils.ZookeeperFactory
      Throws:
      Exception