Class JcaExecutorServiceManagedConnection
- java.lang.Object
-
- org.camunda.bpm.container.impl.threading.ra.outbound.JcaExecutorServiceManagedConnection
-
- All Implemented Interfaces:
javax.resource.spi.ManagedConnection
public class JcaExecutorServiceManagedConnection extends java.lang.Object implements javax.resource.spi.ManagedConnection
- Author:
- Daniel Meyer
-
-
Field Summary
Fields Modifier and Type Field Description protected JcaExecutorServiceConnectionImpl
connection
protected ExecutorService
delegate
protected java.util.List<javax.resource.spi.ConnectionEventListener>
listeners
protected java.io.PrintWriter
logwriter
protected JcaExecutorServiceManagedConnectionFactory
mcf
-
Constructor Summary
Constructors Constructor Description JcaExecutorServiceManagedConnection()
JcaExecutorServiceManagedConnection(JcaExecutorServiceManagedConnectionFactory mcf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
void
associateConnection(java.lang.Object connection)
void
cleanup()
void
destroy()
java.lang.Object
getConnection(javax.security.auth.Subject subject, javax.resource.spi.ConnectionRequestInfo cxRequestInfo)
java.lang.Runnable
getExecuteJobsRunnable(java.util.List<java.lang.String> jobIds, ProcessEngineImpl processEngine)
javax.resource.spi.LocalTransaction
getLocalTransaction()
java.io.PrintWriter
getLogWriter()
javax.resource.spi.ManagedConnectionMetaData
getMetaData()
javax.transaction.xa.XAResource
getXAResource()
void
removeConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
boolean
schedule(java.lang.Runnable runnable, boolean isLongRunning)
void
setLogWriter(java.io.PrintWriter out)
-
-
-
Field Detail
-
logwriter
protected java.io.PrintWriter logwriter
-
mcf
protected JcaExecutorServiceManagedConnectionFactory mcf
-
listeners
protected java.util.List<javax.resource.spi.ConnectionEventListener> listeners
-
connection
protected JcaExecutorServiceConnectionImpl connection
-
delegate
protected ExecutorService delegate
-
-
Constructor Detail
-
JcaExecutorServiceManagedConnection
public JcaExecutorServiceManagedConnection()
-
JcaExecutorServiceManagedConnection
public JcaExecutorServiceManagedConnection(JcaExecutorServiceManagedConnectionFactory mcf)
-
-
Method Detail
-
getConnection
public java.lang.Object getConnection(javax.security.auth.Subject subject, javax.resource.spi.ConnectionRequestInfo cxRequestInfo) throws javax.resource.ResourceException
- Specified by:
getConnection
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
associateConnection
public void associateConnection(java.lang.Object connection) throws javax.resource.ResourceException
- Specified by:
associateConnection
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
cleanup
public void cleanup() throws javax.resource.ResourceException
- Specified by:
cleanup
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
destroy
public void destroy() throws javax.resource.ResourceException
- Specified by:
destroy
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
addConnectionEventListener
public void addConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
- Specified by:
addConnectionEventListener
in interfacejavax.resource.spi.ManagedConnection
-
removeConnectionEventListener
public void removeConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
- Specified by:
removeConnectionEventListener
in interfacejavax.resource.spi.ManagedConnection
-
getLogWriter
public java.io.PrintWriter getLogWriter() throws javax.resource.ResourceException
- Specified by:
getLogWriter
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
setLogWriter
public void setLogWriter(java.io.PrintWriter out) throws javax.resource.ResourceException
- Specified by:
setLogWriter
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
getLocalTransaction
public javax.resource.spi.LocalTransaction getLocalTransaction() throws javax.resource.ResourceException
- Specified by:
getLocalTransaction
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
getXAResource
public javax.transaction.xa.XAResource getXAResource() throws javax.resource.ResourceException
- Specified by:
getXAResource
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
getMetaData
public javax.resource.spi.ManagedConnectionMetaData getMetaData() throws javax.resource.ResourceException
- Specified by:
getMetaData
in interfacejavax.resource.spi.ManagedConnection
- Throws:
javax.resource.ResourceException
-
schedule
public boolean schedule(java.lang.Runnable runnable, boolean isLongRunning)
-
getExecuteJobsRunnable
public java.lang.Runnable getExecuteJobsRunnable(java.util.List<java.lang.String> jobIds, ProcessEngineImpl processEngine)
-
-