public static final class DefaultThriftConnectionPoolImpl.ThriftConnectionFactory extends Object implements org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>
| Constructor and Description |
|---|
ThriftConnectionFactory(java.util.function.Function<ThriftServerInfo,org.apache.thrift.transport.TTransport> transportProvider) |
| Modifier and Type | Method and Description |
|---|---|
void |
activateObject(ThriftServerInfo info,
org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) |
void |
destroyObject(ThriftServerInfo info,
org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) |
org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> |
makeObject(ThriftServerInfo info) |
void |
passivateObject(ThriftServerInfo info,
org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) |
boolean |
validateObject(ThriftServerInfo info,
org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) |
public ThriftConnectionFactory(java.util.function.Function<ThriftServerInfo,org.apache.thrift.transport.TTransport> transportProvider)
transportProvider - public org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> makeObject(ThriftServerInfo info) throws Exception
makeObject in interface org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>Exceptionpublic void destroyObject(ThriftServerInfo info, org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) throws Exception
destroyObject in interface org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>Exceptionpublic boolean validateObject(ThriftServerInfo info, org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p)
validateObject in interface org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>public void activateObject(ThriftServerInfo info, org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) throws Exception
activateObject in interface org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>Exceptionpublic void passivateObject(ThriftServerInfo info, org.apache.commons.pool2.PooledObject<org.apache.thrift.transport.TTransport> p) throws Exception
passivateObject in interface org.apache.commons.pool2.KeyedPooledObjectFactory<ThriftServerInfo,org.apache.thrift.transport.TTransport>ExceptionCopyright © 2015. All rights reserved.