private void resumeSuspendedLTC ( LocalTransactionCurrent ltCurrent , Object txConfig ) throws ServletException { //Check for any suspended LTC that needs to be resumed if ( txConfig instanceof TxCollaboratorConfig ) { Object suspended = ( ( TxCollaboratorConfig ) txConfig ) . getSuspendTx ( ) ; if ( suspended instanceof LocalTransactionCoordinator ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Resuming previously suspended LTC coord:" + suspended ) ; Tr . debug ( tc , "Registering LTC callback" ) ; } try { ltCurrent . resume ( ( ( LocalTransactionCoordinator ) suspended ) ) ; } catch ( IllegalStateException ex ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "IllegalStateException" , ex ) ; } try { // Clean-up the Tx ltCurrent . cleanup ( ) ; } catch ( InconsistentLocalTranException iltex ) { // Absorb any exception from cleanup - it doesn't really // matter if there are inconsistencies in cleanup. if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "InconsistentLocalTranException" , iltex ) ; } } catch ( RolledbackException rbe ) { // We need to inform the user that completion // was affected by a call to setRollbackOnly // so rethrow as a ServletException. ServletException se = new ServletException ( "LocalTransaction rolled-back due to setRollbackOnly" , rbe ) ; throw se ; } } } } }
Resumes the LTC that was suspended during preInvoke if one was suspended .