Which statement is true about the result of this method invocation assuming execution reaches Line 12?

FooBean and BarBean are both EJB 3.0 stateless session beans with container-managed
transaction demarcation. All business methods in the two beans have transaction attribute
REQUIRED. The business method foo in FooBean invokes the business method bar in BarBean.
Given :
10. public class BarBean {
11. public void bar0{
12. throw new EJBException(“unexpected error…”);
13.}

Which statement is true about the result of this method invocation assuming execution reaches
Line 12?

FooBean and BarBean are both EJB 3.0 stateless session beans with container-managed
transaction demarcation. All business methods in the two beans have transaction attribute
REQUIRED. The business method foo in FooBean invokes the business method bar in BarBean.
Given :
10. public class BarBean {
11. public void bar0{
12. throw new EJBException(“unexpected error…”);
13.}

Which statement is true about the result of this method invocation assuming execution reaches
Line 12?

A.
Thecontainer mightroll back the transaction.

B.
TheBarBean bean instance is in the ready stateforthe next invocation.

C.
FooBean.foomethod receives javax.ejb.EJBTransactionRolledbackException.

D.
FooBean.foo method receives javax.transaction.InvalidTransactionException.



Leave a Reply 0

Your email address will not be published. Required fields are marked *