void IEnlistmentNotificationInternal.Prepare( IPromotedEnlistment preparingEnlistment ) { _promotedEnlistment = preparingEnlistment; _twoPhaseNotifications.Prepare(PreparingEnlistment); }
void IEnlistmentNotificationInternal.InDoubt( IPromotedEnlistment enlistment ) { _promotedEnlistment = enlistment; _twoPhaseNotifications.InDoubt(Enlistment); }
void IEnlistmentNotificationInternal.Prepare( IPromotedEnlistment preparingEnlistment ) { this.promotedEnlistment = preparingEnlistment; this.twoPhaseNotifications.Prepare(this.PreparingEnlistment); }
void IEnlistmentNotificationInternal.Rollback( IPromotedEnlistment enlistment ) { this.promotedEnlistment = enlistment; this.twoPhaseNotifications.Rollback(this.Enlistment); }
void IEnlistmentNotificationInternal.InDoubt( IPromotedEnlistment enlistment ) { this.promotedEnlistment = enlistment; this.twoPhaseNotifications.InDoubt(this.Enlistment); }
void IEnlistmentNotificationInternal.Rollback( IPromotedEnlistment enlistment ) { _promotedEnlistment = enlistment; _twoPhaseNotifications.Rollback(Enlistment); }
void IEnlistmentNotificationInternal.Prepare( IPromotedEnlistment preparingEnlistment ) { Debug.Assert(_twoPhaseNotifications != null); _promotedEnlistment = preparingEnlistment; _twoPhaseNotifications.Prepare(PreparingEnlistment); }
internal override void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { // Save the promoted enlistment because future notifications must be sent here. enlistment.PromotedEnlistment = promotedEnlistment; // The transaction is being promoted promote the enlistment as well EnlistmentStatePromoted.EnterState(enlistment); }
void IEnlistmentNotificationInternal.InDoubt( IPromotedEnlistment enlistment ) { Debug.Assert(_twoPhaseNotifications != null); _promotedEnlistment = enlistment; _twoPhaseNotifications.InDoubt(Enlistment); }
internal virtual bool PromoteDurable(InternalTransaction tx) { if (tx.durableEnlistment != null) { InternalEnlistment durableEnlistment = tx.durableEnlistment; IPromotedEnlistment promotedEnlistment = tx.PromotedTransaction.EnlistDurable(durableEnlistment.ResourceManagerIdentifier, (DurableInternalEnlistment)durableEnlistment, durableEnlistment.SinglePhaseNotification != null, EnlistmentOptions.None); tx.durableEnlistment.State.ChangeStatePromoted(tx.durableEnlistment, promotedEnlistment); } return(true); }
void ISinglePhaseNotificationInternal.SinglePhaseCommit(IPromotedEnlistment singlePhaseEnlistment) { bool spcCommitted = false; _promotedEnlistment = singlePhaseEnlistment; try { _singlePhaseNotifications.SinglePhaseCommit(SinglePhaseEnlistment); spcCommitted = true; } finally { if (!spcCommitted) { SinglePhaseEnlistment.InDoubt(); } } }
void ISinglePhaseNotificationInternal.SinglePhaseCommit(IPromotedEnlistment singlePhaseEnlistment) { bool flag = false; this.promotedEnlistment = singlePhaseEnlistment; try { this.singlePhaseNotifications.SinglePhaseCommit(this.SinglePhaseEnlistment); flag = true; } finally { if (!flag) { this.SinglePhaseEnlistment.InDoubt(); } } }
internal IPromotedEnlistment EnlistVolatile(ISinglePhaseNotificationInternal singlePhaseNotification, EnlistmentOptions enlistmentOptions) { if (DiagnosticTrace.Verbose) { MethodEnteredTraceRecord.Trace(System.Transactions.SR.GetString("TraceSourceOletx"), "OletxTransaction.EnlistVolatile( ISinglePhaseNotificationInternal )"); } if ((this.realOletxTransaction == null) || this.realOletxTransaction.TooLateForEnlistments) { throw TransactionException.Create(System.Transactions.SR.GetString("TraceSourceOletx"), System.Transactions.SR.GetString("TooLate"), null); } IPromotedEnlistment enlistment = this.realOletxTransaction.EnlistVolatile(singlePhaseNotification, enlistmentOptions, this); if (DiagnosticTrace.Verbose) { MethodExitedTraceRecord.Trace(System.Transactions.SR.GetString("TraceSourceOletx"), "OletxTransaction.EnlistVolatile( ISinglePhaseNotificationInternal )"); } return(enlistment); }
internal virtual void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { Debug.Assert(false, string.Format(null, "Invalid Event for InternalEnlistment State; Current State: {0}", GetType())); throw TransactionException.CreateEnlistmentStateException(null, enlistment == null ? Guid.Empty : enlistment.DistributedTxId); }
public override void InDoubt(IPromotedEnlistment en) { _promotedEnlistment = en; PoolableInDoubt(this); }
public override void Commit(IPromotedEnlistment en) { _promotedEnlistment = en; PoolableCommit(this); }
internal virtual void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { throw TransactionException.CreateEnlistmentStateException(System.Transactions.SR.GetString("TraceSourceLtm"), null); }
internal virtual void ChangeStatePromoted( InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment ) { Debug.Assert( false, string.Format( null, "Invalid Event for InternalEnlistment State; Current State: {0}", this.GetType() )); throw TransactionException.CreateEnlistmentStateException( SR.GetString( SR.TraceSourceLtm ), null ); }
void ISinglePhaseNotificationInternal.SinglePhaseCommit( IPromotedEnlistment singlePhaseEnlistment ) { bool spcCommitted = false; this.promotedEnlistment = singlePhaseEnlistment; try { this.singlePhaseNotifications.SinglePhaseCommit(this.SinglePhaseEnlistment); spcCommitted = true; } finally { if (!spcCommitted) { this.SinglePhaseEnlistment.InDoubt(); } } }
public abstract void Rollback(IPromotedEnlistment en);
// Fanout Preprepare notifications public abstract void Prepare(IPromotedEnlistment en);
public abstract void InDoubt(IPromotedEnlistment en);
public abstract void Commit(IPromotedEnlistment en);
internal virtual void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { Debug.Fail($"Invalid Event for InternalEnlistment State; Current State: {GetType()}"); throw TransactionException.CreateEnlistmentStateException(null, enlistment == null ? Guid.Empty : enlistment.DistributedTxId); }
public override void Rollback(IPromotedEnlistment en) { base.oletxEnlistment = en; VolatileDemultiplexer.PoolableRollback(this); }
// Fanout Preprepare notifications public override void Prepare(IPromotedEnlistment en) { _preparingEnlistment = en; PoolablePrepare(this); }
public override void Rollback(IPromotedEnlistment en) { _promotedEnlistment = en; PoolableRollback(this); }
internal override void ChangeStatePromoted( InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment ) { // Save the promoted enlistment because future notifications must be sent here. enlistment.PromotedEnlistment = promotedEnlistment; // The transaction is being promoted promote the enlistment as well _EnlistmentStatePromoted.EnterState( enlistment ); }
public override void InDoubt(IPromotedEnlistment en) { base.oletxEnlistment = en; VolatileDemultiplexer.PoolableInDoubt(this); }
public override void Prepare(IPromotedEnlistment en) { base.preparingEnlistment = en; VolatileDemultiplexer.PoolablePrepare(this); }
internal override void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { enlistment.PromotedEnlistment = promotedEnlistment; EnlistmentState._EnlistmentStatePromoted.EnterState(enlistment); }
internal virtual void ChangeStatePromoted(InternalEnlistment enlistment, IPromotedEnlistment promotedEnlistment) { Debug.Assert(false, string.Format(null, "Invalid Event for InternalEnlistment State; Current State: {0}", this.GetType())); throw TransactionException.CreateEnlistmentStateException(SR.GetString(SR.TraceSourceLtm), null); }