[JBoss Seam] - jbpm as external sar seam configuration
by Jabberwocky
I am a newbie in this staff.
I've got jbpm as external SAR and I need to use it in a seam application.
Now I am using jbpm this way:
| JbpmConfiguration jbpmConf = (JbpmConfiguration) new InitialContext().lookup("java:/jbpm/JbpmConfiguration");
| JbpmContext jbpmContext = jbpmConf.createJbpmContext();
| GraphSession graphSession = jbpmContext.getGraphSession();
| ProcessDefinition processDefinition =
| graphSession.findLatestProcessDefinition("MyProcess");
| ProcessInstance processInstance =
| new ProcessInstance(processDefinition);
|
I'd like to use @CreateProcess annotation.
How should I configure it, to point out Seam using my configuration of jbpm.
Configuration below is not convenient, because process definition not in the seam application.
| <component class="org.jboss.seam.core.Jbpm">
| <property name="processDefinitions">
| documentLifecycle.jpdl.xml
| </property>
| </component>
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979583#3979583
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979583
19 years, 8 months
[JBoss AOP] - Re: Call to Stateless Session Bean within interceptor ends t
by c.greshake
Hi Gareth,
since RC7 i have the same problem. Have you solved it?
"garethevans" wrote : Hi,
|
| I have an issue regarding an transaction ending to early that i believe is caused by jbossaop. My setup is JBossAS4.0.4, JBossAOP and JBossWS1.0.1. The problem is that I am applying an interceptor around a method within a stateless session bean as marked by an annotation (RequiresLogin)
|
| e.g.
|
|
| | @Stateless
| | public class UserService {
| | @RequiresLogin // my custom annotation
| | public List<User> getAllUsers() ....
| | }
| |
|
| The interceptor looks like
|
|
| | public LoginInterceptor implements Interceptor {
| | public Object invoke(Invocation invocation) throws Throwable {
| | String sessionIdentifier = // get session id from method args
| | HandheldService handheldService = // lookup handheld service
| | boolean isLoggedIn = handheldService.checkLogin( sessionIdentifier );
| | // handle if not logged in
| |
| | return invocation.invokeNext();
| | }
| | }
| |
|
| The call to handheldService.checkLogin works correctly but I am presuming that when the method completes then the transaction is closed and when the call to getAllUsers is made that the transaction does not exist?
|
| The exception that is thrown is as follows:
|
|
| 11:17:48,502 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: null
| | 11:17:48,502 ERROR [JDBCExceptionReporter] Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=susannew.msoft.dev/17, BranchQual=, lo
| | calId=17]; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=susannew.msoft.
| | dev/17, BranchQual=, localId=17])
| | 11:17:48,510 ERROR [SOAPFaultExceptionHelper] SOAP request exception
| | javax.ejb.EJBTransactionRolledbackException: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: Cannot open connection
| | at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:93)
| | at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130)
| | at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:201)
| | at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| | at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
| |
| | ....
| |
| | Caused by: org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=susannew.msoft.dev/17, BranchQual=,
| | localId=17]; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=susannew.mso
| | ft.dev/17, BranchQual=, localId=17])
| | at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:94)
| | at org.hibernate.connection.DatasourceConnectionProvider.getConnection(DatasourceConnectionProvider.java:69)
| | at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:417)
| | ... 109 more
| | Caused by: javax.resource.ResourceException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=susannew.msoft.dev/17, BranchQual=,
| | localId=17]
| | at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:290)
| | at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:379)
| | at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:812)
| |
| |
|
| If i comment out the interceptor call to checkLogin every thing works as expected!
|
| Any Ideas,
|
| Thanks Gareth
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979579#3979579
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979579
19 years, 8 months
[EJB/JBoss] - Re: TransactionTimeOut issue-urgent
by boobalan_kj
thanks for your reply...
I will try to modify web appl/.timeout issue.
but I need clear idea about JBoss Transaction timeout issues..I am using default container configuration(Standard)..when my clients trying to delete particular case, most of the people are getting "Unable to delete case" message...in error log I am seeing the following stack trace like..
-----------------------------
13:13:11,725 INFO [STDOUT] Transaction marked for rollback, possibly a timeout; CausedByException is:
Transaction marked for rollback, possibly a timeout
13:13:19,741 ERROR [BeanLock] Saw rolled back tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=pc-boobalan/197, BranchQual=, localId=197]
13:13:19,741 ERROR [LogInterceptor] TransactionRolledbackLocalException in method: public abstract com.isfsdc.wwm.mt.interfaces.CaseValue com.isfsdc.wwm.mt.interfaces.CaseLocal.getCaseValue(), causedBy:
java.lang.RuntimeException: Transaction marked for rollback, possibly a timeout
at org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.doSchedule(QueuedPessimisticEJBLock.java:208)
at org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.schedule(QueuedPessimisticEJBLock.java:180)
at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:85)
-----------------------------
I used retrycount logic ,that means if i found TransactionRolledBackException I resent that request for N times to do again...
how do i allow all users operations without fails
pls help me out
millions of Thanks in advance
Bala
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979578#3979578
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979578
19 years, 8 months