Package com.sun.enterprise.connectors
Class BootstrapContextImpl
- java.lang.Object
-
- com.sun.enterprise.connectors.BootstrapContextImpl
-
- All Implemented Interfaces:
jakarta.resource.spi.BootstrapContext,Serializable
public final class BootstrapContextImpl extends Object implements jakarta.resource.spi.BootstrapContext, Serializable
BootstrapContext implementation.- Author:
- Qingqing Ouyang, Binod P.G
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static intMAX_INSTANCE_LENGTH
-
Constructor Summary
Constructors Constructor Description BootstrapContextImpl(String moduleName)Constructs aBootstrapContextwith default thread pool for work manager.BootstrapContextImpl(String poolId, String moduleName, ClassLoader rarCL)Constructs aBootstrapContextwith a specified thread pool for work manager.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TimercreateTimer()Creates ajava.util.Timerinstance.jakarta.transaction.TransactionSynchronizationRegistrygetTransactionSynchronizationRegistry()jakarta.resource.spi.work.WorkManagergetWorkManager()Retrieves the work manager.jakarta.resource.spi.XATerminatorgetXATerminator()Retrieves theXATerminatorobject.booleanisContextSupported(Class<? extends jakarta.resource.spi.work.WorkContext> aClass)
-
-
-
Field Detail
-
MAX_INSTANCE_LENGTH
public static final int MAX_INSTANCE_LENGTH
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
BootstrapContextImpl
public BootstrapContextImpl(String moduleName) throws ConnectorRuntimeException
Constructs aBootstrapContextwith default thread pool for work manager.- Parameters:
moduleName- resource-adapter name- Throws:
ConnectorRuntimeException- If there is a failure in retrieving WorkManager.
-
BootstrapContextImpl
public BootstrapContextImpl(String poolId, String moduleName, ClassLoader rarCL) throws ConnectorRuntimeException
Constructs aBootstrapContextwith a specified thread pool for work manager.- Parameters:
poolId- thread-pool-idmoduleName- resource-adapter name- Throws:
ConnectorRuntimeException- If there is a failure in retrieving WorkManager.
-
-
Method Detail
-
createTimer
public Timer createTimer()
Creates ajava.util.Timerinstance. This can cause a problem, since the timer threads are not actually under appserver control. We should override the timer later.- Specified by:
createTimerin interfacejakarta.resource.spi.BootstrapContext- Returns:
java.util.Timerobject.
-
isContextSupported
public boolean isContextSupported(Class<? extends jakarta.resource.spi.work.WorkContext> aClass)
- Specified by:
isContextSupportedin interfacejakarta.resource.spi.BootstrapContext
-
getTransactionSynchronizationRegistry
public jakarta.transaction.TransactionSynchronizationRegistry getTransactionSynchronizationRegistry()
- Specified by:
getTransactionSynchronizationRegistryin interfacejakarta.resource.spi.BootstrapContext
-
getWorkManager
public jakarta.resource.spi.work.WorkManager getWorkManager()
Retrieves the work manager.- Specified by:
getWorkManagerin interfacejakarta.resource.spi.BootstrapContext- Returns:
WorkManagerinstance.- See Also:
CommonWorkManager,WorkManagerFactoryImpl
-
getXATerminator
public jakarta.resource.spi.XATerminator getXATerminator()
Retrieves theXATerminatorobject.- Specified by:
getXATerminatorin interfacejakarta.resource.spi.BootstrapContext
-
-