protected Object _invoke(Method callMethod, InterceptorStack interceptorStack, Object [] args, Object bean, ThreadContext callContext) throws OpenEJBException {
TransactionPolicy txPolicy = callContext.getDeploymentInfo().getTransactionPolicy(callMethod);
TransactionContext txContext = new TransactionContext(callContext, transactionManager);
try {
txPolicy.beforeInvoke(bean, txContext);
} catch (ApplicationException e) {
if (e.getRootCause() instanceof TransactionRequiredException ||
e.getRootCause() instanceof RemoteException) {
instanceManager.poolInstance(callContext, bean);