1 2 Previous Next 21 Replies Latest reply on Aug 3, 2015 8:26 AM by clp207 Go to original post
      • 15. Re: CMT, RuntimeEnivronment Configuration
        jimmy001

        Hi,

         

        take a look here: https://developer.jboss.org/thread/253694

         

        There Maciej provided a workaround to be installed in the wildfly module folder. For me this resulted in problems, when using the CDI services, but perhaps that is a configuration problem in my application.

         

        Regards

         

        J.

        • 16. Re: CMT, RuntimeEnivronment Configuration
          franco80

          Hi Jimmy

           

          thanks for your reply. I checked this, and with simple ear (using cdi) it works then but with my ear I recived:

           

          Caused by: java.lang.Error: Unresolved compilation problem:

              The method getStatus() of type FakeUserTransaction must override a superclass method

           

              at org.jbpm.utils.FakeUserTransaction.getStatus(FakeUserTransaction.java:41)

              at org.drools.persistence.jta.JtaTransactionManager.getStatus(JtaTransactionManager.java:258)

              at org.drools.persistence.jta.JtaTransactionManager.begin(JtaTransactionManager.java:193)

              at org.jbpm.services.task.persistence.TaskTransactionInterceptor.execute(TaskTransactionInterceptor.java:50)

              at org.drools.core.command.impl.AbstractInterceptor.executeNext(AbstractInterceptor.java:41)

              at org.drools.persistence.jta.TransactionLockInterceptor.execute(TransactionLockInterceptor.java:67)

              at org.jbpm.services.task.commands.TaskCommandExecutorImpl.execute(TaskCommandExecutorImpl.java:40)

              at org.jbpm.services.task.impl.TaskDeadlinesServiceImpl.initialize(TaskDeadlinesServiceImpl.java:367)

              at org.jbpm.services.task.HumanTaskConfigurator.getTaskService(HumanTaskConfigurator.java:155)

              at org.jbpm.services.cdi.producer.HumanTaskServiceProducer.produceTaskService(HumanTaskServiceProducer.java:108)

           

          do you know this error ?

           

          regards

          • 17. Re: CMT, RuntimeEnivronment Configuration
            jimmy001

            Yes,

            I had the same problem. I changed the provided sources (removed an "override" annotation) and it worked.

            I would attach the jar, if I would know how to attach a file. Haven't found a way to do this in the forum.

             

            Edit: See attached file.

            • 18. Re: CMT, RuntimeEnivronment Configuration
              franco80

              I had write that i solved it but I see that you added solution, anyway thanks !

               

              I added this only and it works then:

               

                   <build>

                      <plugins>

                          <plugin>

                              <groupId>org.apache.maven.plugins</groupId>

                              <artifactId>maven-compiler-plugin</artifactId>

                              <configuration>

                                  <source>1.7</source>

                                  <target>1.7</target>

                              </configuration>

                          </plugin>

                      </plugins>

                  </build>

               

              I'm using WIldfly 8.2 and there is jboss-transaction-api_1.2_spec.jar with UserTransaction but inside fake-ut-bind-1.0.0.jar is jta 1.1. It's not important now but in future may be a compability problem.

               

              instead of:

               

              <dependency>

                  <groupId>javax.transaction</groupId>

                  <artifactId>jta</artifactId>

                  <scope>provided</scope>

                  <version>1.1</version>

                  </dependency>

               

              use this:

               

              <dependency>

                      <groupId>org.jboss.spec.javax.transaction</groupId>

                      <artifactId>jboss-transaction-api_1.2_spec</artifactId>

                      <version>1.0.0.Final</version>

                  </dependency>

               

              anyway works

               

              thanks

              • 19. Re: CMT, RuntimeEnivronment Configuration
                franco80

                next step is same like I had week ago it means that process started, first work item called, and first human task called but after this next task is not created, I saw that you Jimmy have the same problem in your new post. I don't know why it is happening. I tought that changes with FakeUserTransaction will solve that problem but I see that not...

                • 20. Re: CMT, RuntimeEnivronment Configuration
                  jimmy001

                  I am still trying to figure out why this is the case. I can't find the code to trigger the next node.

                  It is obvious how it works, when you start a new process instance. But when completing a node there seems to be no code to call the necessary method.

                  I am thankful for any hints.

                  • 21. Re: CMT, RuntimeEnivronment Configuration
                    clp207

                    Maciej,

                     

                    I am using your fake UserTransaction workaround with jbpm 6.2 running on Wildfly 8.2. My project consists of the rewards CDI example along with your process that uses JPA persistence.  It works fine if I start the process in my @Named jsf backing bean. However, if I move the code into an ejb, I get this error

                     

                    2015-08-03 07:14:48,470 WARN  [com.arjuna.ats.arjuna] (default task-16) ARJUNA012125: TwoPhaseCoordinator.beforeCompletion - failed for SynchronizationImple< 0:ffff7f000001:-6b890fb3:55bf5989:2ed, org.drools.persistence.jta.JtaTransactionSynchronizationAdapter@191faf7 >: java.lang.IllegalStateException: Illegal method call. This session was previously disposed.

                        at org.drools.core.impl.StatefulKnowledgeSessionImpl.checkAlive(StatefulKnowledgeSessionImpl.java:1221) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.impl.StatefulKnowledgeSessionImpl.getId(StatefulKnowledgeSessionImpl.java:1205) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufOutputMarshaller.serializeSession(ProtobufOutputMarshaller.java:214) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufOutputMarshaller.writeSession(ProtobufOutputMarshaller.java:120) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:155) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:140) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.SessionMarshallingHelper.getSnapshot(SessionMarshallingHelper.java:64) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.info.SessionInfo.transform(SessionInfo.java:81) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.TriggerUpdateTransactionSynchronization.beforeCompletion(TriggerUpdateTransactionSynchronization.java:42) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.jta.JtaTransactionSynchronizationAdapter.beforeCompletion(JtaTransactionSynchronizationAdapter.java:39) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        ....

                     

                    2015-08-03 07:14:48,496 ERROR [org.jboss.as.ejb3.invocation] (default task-16) JBAS014134: EJB Invocation failed on component JbpmApiService for method public org.kie.api.runtime.process.ProcessInstance edu.psu.javaee.services.workflow.dw.ejb.JbpmApiService.startProcess(java.lang.String,edu.psu.javaee.services.workflow.dw.model.ItwoAccessRequest): javax.ejb.EJBTransactionRolledbackException: Transaction rolled back

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.handleEndTransactionException(CMTTxInterceptor.java:139) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.endTransaction(CMTTxInterceptor.java:119) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInOurTx(CMTTxInterceptor.java:277) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.required(CMTTxInterceptor.java:340) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.processInvocation(CMTTxInterceptor.java:239) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                       ...

                    Caused by: javax.transaction.RollbackException: ARJUNA016053: Could not commit transaction.

                        at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1178)

                        at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:126)

                        at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)

                        at org.jboss.as.ejb3.tx.CMTTxInterceptor.endTransaction(CMTTxInterceptor.java:93) [wildfly-ejb3-8.2.0.Final.jar:8.2.0.Final]

                        ... 95 more

                    Caused by: java.lang.IllegalStateException: Illegal method call. This session was previously disposed.

                        at org.drools.core.impl.StatefulKnowledgeSessionImpl.checkAlive(StatefulKnowledgeSessionImpl.java:1221) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.impl.StatefulKnowledgeSessionImpl.getId(StatefulKnowledgeSessionImpl.java:1205) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufOutputMarshaller.serializeSession(ProtobufOutputMarshaller.java:214) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufOutputMarshaller.writeSession(ProtobufOutputMarshaller.java:120) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:155) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.core.marshalling.impl.ProtobufMarshaller.marshall(ProtobufMarshaller.java:140) [drools-core-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.SessionMarshallingHelper.getSnapshot(SessionMarshallingHelper.java:64) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.info.SessionInfo.transform(SessionInfo.java:81) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.TriggerUpdateTransactionSynchronization.beforeCompletion(TriggerUpdateTransactionSynchronization.java:42) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at org.drools.persistence.jta.JtaTransactionSynchronizationAdapter.beforeCompletion(JtaTransactionSynchronizationAdapter.java:39) [drools-persistence-jpa-6.2.0.Final.jar:6.2.0.Final]

                        at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:76)

                        at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:358)

                        at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:91)

                        at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:162)

                        at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1166)

                        ... 98 more

                     

                     

                    Any ideas? I've tried setting diferent @Transactional annotations on the EJB method, but still get the same error.

                     

                    Thanks!

                    1 2 Previous Next