wood burning stoves 2.0*
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes Transaction attributes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "Transaction attributes" Watch "Transaction attributes" New topic
Author

Transaction attributes

Sven Thor
Ranch Hand

Joined: Jan 31, 2004
Posts: 34
It says in the EJB spec (about CMT) that for entity beans and session beans there are certain methods that must be assigned transaction attributes. However, the <assembly-descriptor> part of ejb-jar.xml is optional. And the appserver I am using does not complain or give a warning when I deploy a set of beans without the <assembly-descriptor> part.

How does the container know which transaction-attributes to use? Does it use default configuration or no transactions at all ?

Br,
Sven
sawan parihar
Ranch Hand

Joined: Aug 24, 2004
Posts: 250
Hello,
The application server will use the default transaction attribute. In case of weblogic it will use supports as the default transaction attribute if the trans attribute is not specified. Also it will give a warning message that no transaction attribute is specified . Which application server you are using?. Have you check the logs that there is no warning.

It may be the reason that some application servers expect the transaction attributes to be specified but all the intelligent and good app servers will use a default transaction attribute.

Hope it helps.


Sawan<br />SCJP,SCWCD,SCBCD<br /> <br />Every exit is an entry somewhere.
Sven Thor
Ranch Hand

Joined: Jan 31, 2004
Posts: 34
Thanks.

I am using JBoss. I am not able to find any info in the log files.

ST
sawan parihar
Ranch Hand

Joined: Aug 24, 2004
Posts: 250
Hi,
Not sure but you can have a look and see if this info helps.

http://wiki.jboss.org/wiki/Wiki.jsp?page=AOPTransactionDemarcation
 
Consider Paul's rocket mass heater.
 
subject: Transaction attributes
 
Similar Threads
Problem deploying ejbs in weblogic
"default" CMT behavior if trans attributes not specified
Handling of Transactions in EJB 2.1 version
Transaction confusion
HFE Pg 576 Assembly Descriptor function