AdminServerFactory (Apache ZooKeeper - Server 3.7.0 API)
Date: 2021-03-17

org.apache.zookeeper.server.admin

## Class AdminServerFactory

- java.lang.Object
- - org.apache.zookeeper.server.admin.AdminServerFactory

-     public class AdminServerFactory
      extends Object

  Factory class for creating an AdminServer.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AdminServerFactory()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static AdminServer` | `createAdminServer()` This method encapsulates the logic for whether we should use a JettyAdminServer (i.e., the AdminServer is enabled) or a DummyAdminServer (i.e., the AdminServer is disabled).

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AdminServerFactory

          public AdminServerFactory()

  - ### Method Detail

    - #### createAdminServer

          public static AdminServer createAdminServer()

      This method encapsulates the logic for whether we should use a JettyAdminServer (i.e., the AdminServer is enabled) or a DummyAdminServer (i.e., the AdminServer is disabled). It uses reflection when attempting to create a JettyAdminServer, rather than referencing the class directly, so that it's ok to omit Jetty from the classpath if a user doesn't wish to pull in Jetty with ZooKeeper.

Copyright © 2008–2021 The Apache Software Foundation. All rights reserved.