return factory.getServiceRegistry().getService( JtaPlatform.class ).retrieveTransactionManager();
}
boolean wrapInTransaction() {
final TransactionFactory transactionFactory = factory.getServiceRegistry().getService( TransactionFactory.class );
if ( !transactionFactory.compatibleWithJtaSynchronization() ) {
//Today we only require a TransactionManager on JTA based transaction factories
log.trace( "TransactionFactory does not require a TransactionManager: don't wrap in a JTA transaction" );
return false;
}
final TransactionManager transactionManager = getTransactionManager();