我有bean管理的事务无状态Bean和方法是这样的:UserTransaction如何传播?
@Stateless
@TransactionManagement(TransactionManagementType.BEAN)
public class ... {
@Resource
private UserTransaction ut;
@EJB
private OtherStatelessBeanLocal other;
public void invokeSomeMethods()
ut.begin();
...
// invoke other bean's methods here.
other.method();
...
ut.commit();
}
}
那么如何UserTransaction
传播到OtherStatelessBeanLocal
豆?
好它没有,对吧? – 2014-11-11 22:32:17