There two way using trasanction in EJB(Session Bean). One way is that I can handle transaction by UserTransaction through JNDI or by configuring transaction attribute in ejb-jar.xml. When should I use first way ? when should I use the second way?
The second question is:Can I use UserTransaction in javabean by JNDI lookup , suppose that the javabean run inside application server?
Thanks