Hallo,
we actually plan following project structure:
We want to separate the taskservice implementation from the process implementation but composite the moduls to one ear. The taskservice should only start a process in a specific transaction. All other dependencies to camunda should be implemented in taskservice-process.war.
The actually generated EAR has following content:
During the deployment on jboss the following error is output:
10:33:07,166 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC00001: Failed to start service jboss.deployment.unit."customer-ear-1.0.0-SNAPSHOT.ear".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.unit."customer-ear-1.0.0-SNAPSHOT.ear".PARSE: JBAS018733: Failed to process phase PARSE of deployment "customer-ear-1.0.0-SNAPSHOT.ear"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:127) [jboss-as-server-7.2.0.Final.jar:7.2.0.Final]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.4.GA.jar:1.0.4.GA]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.4.GA.jar:1.0.4.GA]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_20]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_20]
at java.lang.Thread.run(Thread.java:619) [rt.jar:1.6.0_20]
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: Class org.camunda.bpm.application.impl.ejb.DefaultEjbProcessApplication is annotated with @ProcessApplication but is neither a ServletProcessApplication nor an EJB Session Bean Component.
at org.camunda.bpm.container.impl.jboss.deployment.processor.ProcessApplicationProcessor.detectExistingComponent(ProcessApplicationProcessor.java:189)
at org.camunda.bpm.container.impl.jboss.deployment.processor.ProcessApplicationProcessor.deploy(ProcessApplicationProcessor.java:72)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:120) [jboss-as-server-7.2.0.Final.jar:7.2.0.Final]
... 5 more
Is it possible to access the camunda engine from a ejb modul?
Cheers,
Bernd
<dependency> <!-- client for Java EE application server integration, included in WAR as an alternative to write your own ProcessApplication class -->
<groupId>org.camunda.bpm.javaee</groupId> <artifactId>camunda-ejb-client</artifactId>
<version>7.4.0</version> <type>ejb</type> </dependency>
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-ear-plugin</artifactId> <configuration> <finalName>my-ear</finalName> <version>1</version> <generateApplicationXml>false</generateApplicationXml> <defaultLibBundleDir>lib</defaultLibBundleDir> <modules> <ejbModule>
<groupId>org.camunda.bpm.javaee</groupId> <artifactId>camunda-ejb-client</artifactId>
</ejbModule> </modules> </configuration> </plugin>
<module> <ejb>camunda-ejb-client-7.4.0.jar</ejb> </module>
<ear-subdeployments-isolated>false</ear-subdeployments-isolated>