Let's I have Stateless
bean with CMT. I have 3 methods in bean, 2 with TransactionAttributeType.REQUIRED
. And both method are called from third method. How can I check when transaction is active? i want check
@Stateless
@TransactionManagement(TransactionManagementType.CONTAINER)
public class MyBean
{
public RetType methodA()
{
methodB();
//.... is CMT active there?
methodC();
}
@TransactionAttribute(TransactionAttributeType.REQUIRED)
public RetType methodB(){}
@TransactionAttribute(TransactionAttributeType.REQUIRED)
public RetType methodC(){}
}