Class UnifiedConnectionFactory
- java.lang.Object
-
- org.eclipse.jetty.util.component.AbstractLifeCycle
-
- org.eclipse.jetty.util.component.ContainerLifeCycle
-
- org.eclipse.jetty.server.AbstractConnectionFactory
-
- org.apache.zookeeper.server.admin.UnifiedConnectionFactory
-
- All Implemented Interfaces:
org.eclipse.jetty.server.ConnectionFactory
,org.eclipse.jetty.util.component.Container
,org.eclipse.jetty.util.component.Destroyable
,org.eclipse.jetty.util.component.Dumpable
,org.eclipse.jetty.util.component.Dumpable.DumpableContainer
,org.eclipse.jetty.util.component.LifeCycle
public class UnifiedConnectionFactory extends org.eclipse.jetty.server.AbstractConnectionFactory
The purpose of this class is to dynamically determine whether to create a plaintext or SSL connection whenever newConnection() is called. It works in conjunction with ReadAheadEndpoint to inspect bytes on the incoming connection.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
org.eclipse.jetty.util.component.AbstractLifeCycle.AbstractLifeCycleListener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.server.ConnectionFactory
org.eclipse.jetty.server.ConnectionFactory.Detecting, org.eclipse.jetty.server.ConnectionFactory.Upgrading
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.Container
org.eclipse.jetty.util.component.Container.InheritedListener, org.eclipse.jetty.util.component.Container.Listener
-
-
Constructor Summary
Constructors Constructor Description UnifiedConnectionFactory(String nextProtocol)
UnifiedConnectionFactory(org.eclipse.jetty.util.ssl.SslContextFactory factory, String nextProtocol)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doStart()
org.eclipse.jetty.io.Connection
newConnection(org.eclipse.jetty.server.Connector connector, org.eclipse.jetty.io.EndPoint realEndPoint)
protected org.eclipse.jetty.io.ssl.SslConnection
newSslConnection(org.eclipse.jetty.server.Connector connector, org.eclipse.jetty.io.EndPoint endPoint, SSLEngine engine)
String
toString()
-
Methods inherited from class org.eclipse.jetty.server.AbstractConnectionFactory
configure, findNextProtocol, findNextProtocol, getFactories, getInputBufferSize, getProtocol, getProtocols, setInputBufferSize
-
Methods inherited from class org.eclipse.jetty.util.component.ContainerLifeCycle
addBean, addBean, addEventListener, addManaged, contains, destroy, doStop, dump, dump, dump, dump, dump, dumpBeans, dumpObject, dumpObjects, dumpStdErr, dumpThis, getBean, getBeans, getBeans, getContainedBeans, getContainedBeans, isAuto, isManaged, isUnmanaged, manage, removeBean, removeBeans, removeEventListener, setBeans, setStopTimeout, start, stop, unmanage, updateBean, updateBean, updateBeans
-
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
addLifeCycleListener, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop
-
-
-
-
Method Detail
-
doStart
protected void doStart() throws Exception
- Overrides:
doStart
in classorg.eclipse.jetty.util.component.ContainerLifeCycle
- Throws:
Exception
-
newConnection
public org.eclipse.jetty.io.Connection newConnection(org.eclipse.jetty.server.Connector connector, org.eclipse.jetty.io.EndPoint realEndPoint)
-
newSslConnection
protected org.eclipse.jetty.io.ssl.SslConnection newSslConnection(org.eclipse.jetty.server.Connector connector, org.eclipse.jetty.io.EndPoint endPoint, SSLEngine engine)
-
toString
public String toString()
- Overrides:
toString
in classorg.eclipse.jetty.server.AbstractConnectionFactory
-
-