/** * called by the service startup code before the recovery module is added to the recovery managers * module list */ public void install() { // the manager is needed by both the participant or the coordinator recovery modules so whichever // one gets there first creates it. No synchronization is needed as modules are only ever // installed in a single thread XTSATRecoveryManager atRecoveryManager = XTSATRecoveryManager.getRecoveryManager(); if (atRecoveryManager == null) { atRecoveryManager = new XTSATRecoveryManagerImple(_recoveryStore); XTSATRecoveryManager.setRecoveryManager(atRecoveryManager); } // Subordinate Coordinators register durable participants with their parent transaction so // we need to add an XTSATRecoveryModule which knows about the registered participants subordinateRecoveryModule = new XTSATSubordinateRecoveryModule(); atRecoveryManager.registerRecoveryModule(subordinateRecoveryModule); }
/** * Tests if there may be unknown coordinator entries in the recovery log. * * @return false if there may be unknown coordinator entries in the recovery log. */ private static boolean areRecoveryLogEntriesAccountedFor() { return XTSATRecoveryManager.getRecoveryManager().isCoordinatorRecoveryStarted(); } }
/** * called by the service shutdown code after the recovery module is removed from the recovery managers * module list */ public void uninstall() { XTSATRecoveryManager.getRecoveryManager().unregisterRecoveryModule(subordinateRecoveryModule); }
XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); else if (!recoveryManager.isParticipantRecoveryStarted()) { WSTLogger.i18NLogger.warn_wst11_messaging_ParticipantProcessorImpl_rollback_4(instanceIdentifier.toString()); else if (recoveryManager.findParticipantRecoveryRecord(instanceIdentifier.getInstanceIdentifier()) != null) { WSTLogger.i18NLogger.warn_wst11_messaging_ParticipantProcessorImpl_rollback_5(instanceIdentifier.toString());
} else { XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); boolean isRecoveryScanStarted = recoveryManager.isSubordinateCoordinatorRecoveryStarted();
if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) {
XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); if (!recoveryManager.isParticipantPresent(recoverUid)) { participantRecord.restoreState(inputState); XTSATRecoveryManager.getRecoveryManager().addParticipantRecoveryRecord(recoverUid, participantRecord); } catch (ClassNotFoundException cnfe) {
if (!XTSATRecoveryManager.getRecoveryManager().writeParticipantRecoveryRecord(recoveryRecord)) { if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) { if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) {
/** * called by the service startup code before the recovery module is added to the recovery managers * module list */ public void install() { // the manager is needed by both the participant or the coordinator recovery modules so whichever // one gets there first creates it. No synchronization is needed as modules are only ever // installed in a single thread XTSATRecoveryManager atRecoveryManager = XTSATRecoveryManager.getRecoveryManager(); if (atRecoveryManager == null) { atRecoveryManager = new XTSATRecoveryManagerImple(_recoveryStore); XTSATRecoveryManager.setRecoveryManager(atRecoveryManager); } Implementations.install(); }
private void processTransactionsStatus() { // Process the Vector of transaction Uids Enumeration transactionUidEnum = _transactionUidVector.elements() ; while ( transactionUidEnum.hasMoreElements() ) { Uid currentUid = (Uid) transactionUidEnum.nextElement(); try { if ( _recoveryStore.currentState( currentUid, _transactionType ) != StateStatus.OS_UNKNOWN ) { doRecoverTransaction( currentUid ) ; } } catch ( ObjectStoreException ex ) { RecoveryLogger.i18NLogger.warn_coordinator_at_SubordinateATCoordinatorRecoveryModule_3(currentUid, ex); } } XTSATRecoveryManager.getRecoveryManager().setSubordinateCoordinatorRecoveryStarted(); }
private void processTransactionsStatus() { // Process the Vector of transaction Uids Enumeration transactionUidEnum = _transactionUidVector.elements() ; while ( transactionUidEnum.hasMoreElements() ) { Uid currentUid = (Uid) transactionUidEnum.nextElement(); try { if ( _recoveryStore.currentState( currentUid, _transactionType ) != StateStatus.OS_UNKNOWN ) { doRecoverTransaction( currentUid ) ; } } catch ( ObjectStoreException ex ) { RecoveryLogger.i18NLogger.warn_coordinator_at_ATCoordinatorRecoveryModule_3(currentUid, ex); } } XTSATRecoveryManager.getRecoveryManager().setCoordinatorRecoveryStarted(); }
private void processParticipantsStatus() { if (_participantUidVector != null) { // Process the Vector of transaction Uids Enumeration participantUidEnum = _participantUidVector.elements() ; while ( participantUidEnum.hasMoreElements() ) { Uid currentUid = (Uid) participantUidEnum.nextElement(); try { if ( _recoveryStore.currentState( currentUid, _participantType) != StateStatus.OS_UNKNOWN ) { doRecoverParticipant( currentUid ) ; } } catch ( ObjectStoreException ex ) { RecoveryLogger.i18NLogger.warn_participant_at_ATParticipantRecoveryModule_3(currentUid, ex); } } } // now get the AT recovery manager to try to activate recovered participants XTSATRecoveryManager.getRecoveryManager().recoverParticipants(); }
/** * MC lifecycle callback, used to unregister components from the recovery manager. */ public void stop() { txbridgeLogger.i18NLogger.info_ibrm_stop(); xtsATRecoveryManager.unregisterRecoveryModule(this); acRecoveryManager.removeModule(this, false); XARecoveryModule xaRecoveryModule = getXARecoveryModule(); xaRecoveryModule.removeXAResourceOrphanFilter(this); }
/** * MC lifecycle callback, used to register components with the recovery manager. */ public void start() { txbridgeLogger.i18NLogger.info_ibrm_start(); xtsATRecoveryManager.registerRecoveryModule(this); acRecoveryManager.addModule(this); XARecoveryModule xaRecoveryModule = getXARecoveryModule(); xaRecoveryModule.addXAResourceOrphanFilter(this); }
XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); else if (!recoveryManager.isParticipantRecoveryStarted()) { WSTLogger.i18NLogger.warn_wst11_messaging_ParticipantProcessorImpl_rollback_4(instanceIdentifier.toString()); else if (recoveryManager.findParticipantRecoveryRecord(instanceIdentifier.getInstanceIdentifier()) != null) { WSTLogger.i18NLogger.warn_wst11_messaging_ParticipantProcessorImpl_rollback_5(instanceIdentifier.toString());
} else { XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); boolean isRecoveryScanStarted = recoveryManager.isSubordinateCoordinatorRecoveryStarted();
if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) {
XTSATRecoveryManager recoveryManager = XTSATRecoveryManager.getRecoveryManager(); if (!recoveryManager.isParticipantPresent(recoverUid)) { participantRecord.restoreState(inputState); XTSATRecoveryManager.getRecoveryManager().addParticipantRecoveryRecord(recoverUid, participantRecord); } catch (ClassNotFoundException cnfe) {
if (!XTSATRecoveryManager.getRecoveryManager().writeParticipantRecoveryRecord(recoveryRecord)) { if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) { if (!XTSATRecoveryManager.getRecoveryManager().deleteParticipantRecoveryRecord(id)) {
/** * called by the service startup code before the recovery module is added to the recovery managers * module list */ public void install() { // the manager is needed by both the participant or the coordinator recovery modules so whichever // one gets there first creates it. No synchronization is needed as modules are only ever // installed in a single thread XTSATRecoveryManager atRecoveryManager = XTSATRecoveryManager.getRecoveryManager(); if (atRecoveryManager == null) { atRecoveryManager = new XTSATRecoveryManagerImple(_recoveryStore); XTSATRecoveryManager.setRecoveryManager(atRecoveryManager); } Implementations.install(); }