org.jbpm.enterprise.impl
Class CommandExecutorSLSB
java.lang.Object
org.jbpm.enterprise.impl.CommandExecutorSLSB
- All Implemented Interfaces:
- java.io.Serializable, javax.ejb.EnterpriseBean, javax.ejb.SessionBean
public class CommandExecutorSLSB
- extends java.lang.Object
- implements javax.ejb.SessionBean
Stateless session command executor.
Configuration
In order to provide commands an environment in which to run, the command
executor builds an environment factory from a configuration file loaded as a
classpath resource. The environment entry ConfigurationResource
specifies the name of the resource to access; the default is
enterprise.environment.cfg.xml
.
JNDI-bound environment factory
To avoid parsing the configuration file multiple times, the command executor
attempts to bind the environment factory to the name specified in the
EnvironmentFactoryName
environment entry, defaulting to
java:jbpm/EnvironmentFactory
. If the binding fails, the
command executor will still work; however, each instance will build its own
environment factory from the configuration.
- Author:
- Jim Rigsbee, Tom Baeyens, Alejandro Guizar
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CommandExecutorSLSB
public CommandExecutorSLSB()
execute
public <T> T execute(Command<T> command)
setSessionContext
public void setSessionContext(javax.ejb.SessionContext sessionContext)
- Specified by:
setSessionContext
in interface javax.ejb.SessionBean
ejbCreate
public void ejbCreate()
throws javax.ejb.CreateException
- Creates a command executor that will be used to execute the commands that
are passed in the execute method.
- Throws:
javax.ejb.CreateException
ejbRemove
public void ejbRemove()
- Specified by:
ejbRemove
in interface javax.ejb.SessionBean
ejbActivate
public void ejbActivate()
- Specified by:
ejbActivate
in interface javax.ejb.SessionBean
ejbPassivate
public void ejbPassivate()
- Specified by:
ejbPassivate
in interface javax.ejb.SessionBean