AnsweredAssumed Answered

Using Activiti in an JEE environment

Question asked by chris.joelly on Jul 28, 2011
Latest reply on May 29, 2017 by idireneyoucef
Hello,

i just try to figure out how to use Activiti engine in an JEE application running on an JEE server.

The server in question is Apache Geronimo which provides things like JPA and JSF, which i want
to use for an application, and for some parts of that application i want to use Activiti as process
engine.

I read through the Activiti documentation regarding some topics and the following questions arose
which i can not answer myself from the documentation, and trying all seems to be some effort so
if anybody has experience or knowledge about this issues i would be very glad to hear about it :)

How can i initialize and start the process engine in an JEE/EAR based application? In JEE6 there is
a new type of session bean, singleton session bean which may be used for this issue. But what in
an JEE5 environment? Is there something similar?

Activiti is able to use JPA driven entities as process variables, but how needs Activiti to be configured
to use a datasource provided by the JEE server? Within an EJB module a persistence.xml needs to
be provided which configures JPA and a datasource can be referenced which is provided by the
JEE server. When Activiti is configured with a persistence unit from that persistence.xml, is this
sufficient for Activiti to be able to use the JPA driven entities from the EJB module?

Activiti is distributed with various tools like Explorer which provides a frontend to the tasks created
using the life time of a process. Can the process engine and the processes and tasks be managed
without Explorer, e.g. when building an own user interface around the Activiti engine? Is the REST
interface of Activiti the interface for such integration?

What about CDI? This is only available in JEE6 environments? Can this solve the initialization and
starting of the process engine with the @Inject ProcessEngine annotation? And are the JPA,
datasource, transaction and persistence unit issues too solvable using CDI in an JEE6 environment?

Thanks for any answer

Chris

Outcomes