[JBoss Seam] - A performance problem with Seam
by moises_paula
There are a performance problem with Seam, after migration from 1.1.x to 1.2. One of interceptors, ManagedEntityIdentityInterceptor, for each method call in
my backing bean, was calling Transactions.isTransactionMarkedRollback(...), that was trying to lookup for a name (userTransactionName). On tomcat, where
there are no JNDI server started, I see a lot of javax.naming.CommunicationException in my logs. It's not a funtional problem, but it's degrading my
performance for nothing. There are any option to disable that feature, removing the interceptor or caching an information that the lookup is not working?
javax.naming.CommunicationException: Failed to connect to server localhost:1099 [Root exception is javax.naming.ServiceUnavailableException: Failed to
connect to server localhost:1099 [Root exception is java.net.ConnectException: Connection refused: connect]]
at org.jnp.interfaces.NamingContext.getServer(NamingContext.java:208)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1092)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:470)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:463)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at org.jboss.seam.util.Transactions.getUserTransaction(Transactions.java:149)
at org.jboss.seam.util.Transactions.isUTTransactionMarkedRollback(Transactions.java:140)
at org.jboss.seam.util.Transactions.isTransactionMarkedRollback(Transactions.java:67)
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4046284#4046284
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4046284
19 years
[JBoss jBPM] - Re: why
by estaub
Simon,
anonymous wrote : I disagree the persistence behavior of JbpmContext is obvious.
What, exactly, are you expecting that would make it obvious?
A search through the user guide for "transaction" will get you:
anonymous wrote : A JbpmContext typically represents one transaction.
anonymous wrote : The persistence service [exposed by JbpmContext] will obtain a jdbc connection and all the other services will use the same connection to perform their services. So all of you workflow operations are centralized into 1 transaction on A JDBC connection without the need for a transaction manager.
anonymous wrote : By default, jBPM will delegate transaction to hibernate and use the session per transaction pattern. jBPM will begin a hibernate transaction when a hibernate session is opened. This will happen the first time when a persistent operation is invoked on the jbpmContext. The transaction will be committed right before the hibernate session is closed. That will happen inside the jbpmContext.close().
|
| Use jbpmContext.setRollbackOnly() to mark a transaction for rollback. In that case, the transaction will be rolled back right before the session is closed inside of the jbpmContext.close().
There are pages more on transaction handling. While I agree that the docs are weak in a lot of areas, you lose your right to gripe if you won't use what's there!
x: "God, please let me win the lottery. PLEASE let me win the lottery."
God: "Try buying a ticket?"
-Ed Staub
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4046277#4046277
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4046277
19 years