ReadOnlyEnlistment function (ktmw32.h)

Requests that the specified enlistment be converted to a read-only enlistment. A read-only enlistment cannot participate in the outcome of the transaction and is not durably recorded for recovery.

Syntax

BOOL ReadOnlyEnlistment(
  [in] HANDLE         EnlistmentHandle,
  [in] PLARGE_INTEGER TmVirtualClock
);

Parameters

[in] EnlistmentHandle

A handle to the enlistment.

[in] TmVirtualClock

The latest virtual clock value received for this enlistment. If you specify NULL, the virtual clock value is not changed. See LARGE_INTEGER.

To change the virtual clock value, this value must be greater than the current value returned in the COMMIT notification.

Return value

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero (0). To get extended error information, call the GetLastError function.

The following list identifies the possible error codes:

Remarks

If a resource manager no longer needs to participate in a transaction without rolling back the transaction, it should call ReadOnlyEnlistment prior to closing the enlistment handle.

Requirements

Requirement Value
Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
Target Platform Windows
Header ktmw32.h
Library Ktmw32.lib
DLL Ktmw32.dll

See also

GetCurrentClockTransactionManager

Kernel Transaction Manager Functions

ReadOnlyEnlistment