[jboss-user] [JBoss AOP] - Re: Transaction Demarcation and JBoss AOP 2.0

mwringe do-not-reply at jboss.com
Mon Nov 24 12:06:06 EST 2008


A more details description of the issue in the hope that someone will have an answer:

If an class is specified through aop to have a transaction requirement (http://www.jboss.org/community/docs/DOC-9034) when aop alters the class it will change the constructor. This change to the constructor will cause the class to search for the constructor when its created, and will fail if the constructor is not found.

If this class is an mbean and specified in SAR's jboss-service.xml, when the sar is being deployed it will create the class before even looking at any dependencies for the class. So adding jboss:service=TransactionManager doesn't do any good if the class requires the transaction manager when its constructed.

In JBoss AS5, the transaction manger is no longer started at startup and gets deployed after SARs are deployed.

So, if a SAR uses aop for transaction demarcation for an mbean specified in jboss-service.xml on JBoss AS5, it will fail since the constructor of the mbean requires the transaction manager to be already started.

Should I start opening bugs for this? Open other forum topics in another more proper channel?

I can provide stack traces and more information if needed.

It works fine in versions of JBoss AS before 5 because of when the transaction manager starts.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4191822#4191822

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4191822



More information about the jboss-user mailing list