GetNotificationResourceManagerAsync function (ktmw32.h)
Requests and receives asynchronous notification for a resource manager (RM). This function is used by the RM register to receive notifications when a transaction changes state.
Syntax
BOOL GetNotificationResourceManagerAsync(
[in] HANDLE ResourceManagerHandle,
[out] PTRANSACTION_NOTIFICATION TransactionNotification,
[in] ULONG TransactionNotificationLength,
[out] PULONG ReturnLength,
[in] LPOVERLAPPED lpOverlapped
);
Parameters
[in] ResourceManagerHandle
A handle to the resource manager.
[out] TransactionNotification
A pointer to a TRANSACTION_NOTIFICATION structure that receives the first available notification.
[in] TransactionNotificationLength
The size of the TransactionNotification buffer, in bytes.
[out] ReturnLength
A pointer to a variable that receives the actual size of the notification received by the TransactionNotification parameter.
[in] lpOverlapped
A pointer to an OVERLAPPED structure that is required for asynchronous operation.
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
All resource managers must register to receive TRANSACTION_NOTIFY_PREPREPARE, TRANSACTION_NOTIFY_PREPARE, and TRANSACTION_NOTIFY_COMMIT notifications, even if they subsequently call ReadOnlyEnlistment to mark an enlistment as read-only. Resource managers can support TRANSACTION_NOTIFY_SINGLE_PHASE_COMMIT, but they must also support the multi-phase pre-prepare, prepare, and commit notifications. For the list of all notifications that resource managers can receive, see TRANSACTION_NOTIFICATION.
Resource managers (RM) may want to call this function more than once to provide multiple buffers for KTM to use when delivering notifications. The number of calls to this function depends on how much load your RM is carrying.
This function must be called after the SetResourceManagerCompletionPort function is called.
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
Kernel Transaction Manager Functions