AnsweredAssumed Answered

EAR with activiti-cdi jar in Lib could NOT be deployed on JBoss WildFly

Question asked by sankarts on Nov 14, 2014
Latest reply on Nov 27, 2014 by pkonyves
I am trying to deploy an EAR on JBoss Wildfly 8.1.0 Final App Server.
In which I have written a CDI maanged bean using activiti-cdi. The bean shall look like

public class MyBean implements JavaDelegate, Serializable {

   private static final long serialVersionUID = 1L;
   private static final Logger logger = Logger.getLogger("MyBean.class");
   public void execute(DelegateExecution execution) throws Exception {

The EAR contains all the "Activiti" dependencies in the lib folder including activiti-cdi-5.16.1.jar.
The structire of EAR looks like
lib folder - Includes all activiti dependencies activiti-engine-5.16.1.jar, activiti-cdi-5.16.1.jar etc
META-INF - Has beans.xml, application.xml etc
My Application jar & war files

The exception thrown is
{"JBAS014671: Failed services" => {"jboss.deployment.unit.\"MyEAR.ear\".WeldStartService" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"MyEAR.ear\".WeldStartService: Failed to start service
    Caused by: org.jboss.weld.exceptions.DeploymentException: WELD-001414: Bean name is ambiguous. Name taskId resolves to beans:
  - Producer Method [String] with qualifiers [@TaskId @Any @Named] declared as [[BackedAnnotatedMethod] @Produces @Named @TaskId public org.activiti.cdi.CurrentProcessInstance.getTaskId()],
  - Producer Method [String] with qualifiers [@TaskId @Any @Named] declared as [[BackedAnnotatedMethod] @Produces @Named @TaskId public org.activiti.cdi.CurrentProcessInstance.getTaskId()]"}}

Any idea what is causing this issue?