Sounds like a Seam 2 question, please ask in that forum.
No, it's a Seam 3 question. And now another question? Why did you think this was a Seam 2 question?
Because you're using components.xml and that doesn't exist in Seam 3. As to the original question, I'll have to delegate to Brian or Stuart, I don't know.
If you want to disable Seam 3 transaction support altogether, just don't include the Seam Persistence jar in your deployment.
Managing transaction at the view level is doen with the @ViewConfig, I think this is written up in the Faces reference docs.
If I just remove persistence.jar from the deployment Faces throws an exception because TransactionPhaseListener depends on SeamTransactions. How do I turn of the TransactionPhaseListener in Faces?
I'll look into the @ViewConfig docs although I seem to remember them to be very brief.
Exactly what I need as well.
We use SEAM 3. Weld, Seam Faces, Security. Looks like Security depends on Persistence.
When we add Seam Security our conversations do not work because the txns are committed at the end of the REQUESThence Session is closed and throws Exception. How do we stop this commit? If I remove Security conversations work well.
[org.jboss.seam.faces.event.PhaseEventBridge] Fired event [javax.faces.event.PhaseEvent[source=com.sun.faces.lifecycle.LifecycleImpl@ddeb15]] with qualifiers [[Ljava.lang.annotation.Annotation;@16d5312] [org.jboss.seam.faces.transaction.TransactionPhaseListener] committing transaction after phase: INVOKE_APPLICATION 5 [org.jboss.seam.transaction.UTTransaction] committing JTA transaction [org.hibernate.event.def.AbstractFlushingEventListener] processing flush-time cascades [org.hibernate.event.def.AbstractFlushingEventListener] dirty checking collections [org.hibernate.jdbc.ConnectionManager] aggressively releasing JDBC connection [com.arjuna.ats.arjuna] ARJUNA-12141 Multiple last resources have been added to the current transaction. This is transactionally unsafe and should not be relied upon. Current resource is com.arjuna.ats.internal.arjuna.abstractrecords.LastResourceRecord@125683e [org.jboss.jpa.deployment.ManagedEntityManagerFactory] ************** closing entity managersession **************
I tried Fernando Montaño's Solution, didnt work. Any help would greatly be appreciated.
It worked for me. Thanks Fernando!
Senthil, did you remember to include the dependency for seam-config? This is the module that makes the magic happen. Put seam-beans.xml in .../WEB-INF/classes/META-INF/ folder with the contents below:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
did you remember to include the dependency for seam-config?
That did the trick alongwith seam-beans.xml
When I didn't include config dependency but included seam-beans.xml, Jboss wasn't complaining, so I thought all is fine but looks like without config, seam-beans.xml config specific entries were ignored.
This has been giving me heart-ache for the last week.
Thanks Champions Fernando and Brian! Much appreciate your time and help.
Just a comment for the lucky users of Seam 3.1.0.Final:
You should use xmlns:sc="urn:java:org.jboss.solder.core" instead of xmlns:sc="urn:java:org.jboss.seam.solder.core" and of course you have to be aware of the fact, that seam-beans.xml and beans.xml files are NOT processed if stored anywhere in WAR, located inside EAR.
Therefore the probably only option to get rid of the exception
JBAS010152: APPLICATION ERROR: transaction still active in request with status 0
which happens during AJAX request done in RichFaces components is to put all seam*.jar and solder*.jar into the EAR/lib directory, and use the EJB JAR seam-beans.xml for the purpose of disabling the buggy TransactionPhaseListener.
In Eclipse/Maven you have to set the seam-faces* dependencies in the WAR pom.xml as "provided", so the seam-faces*.jar will not be twice on the classpath.