public class DefaultLifecycleEnabledObjectPool extends Object implements LifecyleEnabledObjectPool
LifecycleAdapter instances for implementations of
JavaComponent that require LifecycleAdapter pooling such as PooledJavaComponent.PooledJavaComponent| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
logger
logger used by this class
|
protected AtomicBoolean |
started |
| Constructor and Description |
|---|
DefaultLifecycleEnabledObjectPool(ObjectFactory objectFactory,
org.mule.runtime.api.config.PoolingProfile poolingProfile,
MuleContext muleContext) |
| Modifier and Type | Method and Description |
|---|---|
Object |
borrowObject() |
void |
clear() |
void |
close() |
void |
dispose() |
int |
getMaxActive() |
int |
getNumActive() |
ObjectFactory |
getObjectFactory() |
void |
initialise() |
void |
returnObject(Object object) |
void |
setObjectFactory(ObjectFactory objectFactory) |
void |
start() |
void |
stop() |
protected static final org.slf4j.Logger logger
protected AtomicBoolean started
public DefaultLifecycleEnabledObjectPool(ObjectFactory objectFactory, org.mule.runtime.api.config.PoolingProfile poolingProfile, MuleContext muleContext)
objectFactory - The object factory that should be used to create new
LifecycleAdapter instance for the poolpoolingProfile - The pooling progile ot be used to configure poolmuleContext - public void start()
throws org.mule.runtime.api.exception.MuleException
start in interface org.mule.runtime.api.lifecycle.Startableorg.mule.runtime.api.exception.MuleExceptionpublic void stop()
throws org.mule.runtime.api.exception.MuleException
stop in interface org.mule.runtime.api.lifecycle.Stoppableorg.mule.runtime.api.exception.MuleExceptionpublic Object borrowObject() throws Exception
borrowObject in interface ObjectPoolExceptionpublic void returnObject(Object object)
returnObject in interface ObjectPoolpublic int getNumActive()
getNumActive in interface ObjectPoolpublic int getMaxActive()
getMaxActive in interface ObjectPoolpublic void clear()
clear in interface ObjectPoolpublic void close()
close in interface ObjectPoolpublic void setObjectFactory(ObjectFactory objectFactory)
setObjectFactory in interface ObjectPoolpublic ObjectFactory getObjectFactory()
getObjectFactory in interface ObjectPoolpublic void dispose()
dispose in interface org.mule.runtime.api.lifecycle.Disposablepublic void initialise()
throws org.mule.runtime.api.lifecycle.InitialisationException
initialise in interface org.mule.runtime.api.lifecycle.Initialisableorg.mule.runtime.api.lifecycle.InitialisationExceptionCopyright © 2003–2017 MuleSoft, Inc.. All rights reserved.