Export (0) Print
Expand All

ISinglePhaseNotification.SinglePhaseCommit Method

Represents the resource manager's implementation of the callback for the single phase commit optimization.

Namespace: System.Transactions
Assembly: System.Transactions (in system.transactions.dll)

void SinglePhaseCommit (
	SinglePhaseEnlistment singlePhaseEnlistment
)
void SinglePhaseCommit (
	SinglePhaseEnlistment singlePhaseEnlistment
)
function SinglePhaseCommit (
	singlePhaseEnlistment : SinglePhaseEnlistment
)
Not applicable.

Parameters

singlePhaseEnlistment

A SinglePhaseEnlistment used to send a response to the transaction manager.

It is the transaction manager's choice as to whether two phase commit or the single phase commit optimization is used with this resource manager. For more information on single phase and two phase commit, see Single-Phase and Multi-Phase Transactions.

Therefore, on this enlistment of the resource manager, either the SinglePhaseCommit method is called, or the two phase commit methods defined in ther IEnlistmentNotification interface are called.

Your implementation of this method should call either the Committed method or the Aborted method of the singlePhaseEnlistment parameter to indicate whether the transaction should be committed or rolled back.

The transaction manager calls this method when there is only one volatile enlistment that supports single phase commit, or when there are zero or more volatile enlistments and one durable enlistment. In the latter case, the volatile enlistments receive Prepare notifications for two-phase-commit, and the sole durable enlistment receives a single-phase commit notification.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft