TransactionInterop.GetExportCookie(Transaction, Byte[]) Method

Definition

Transforms a transaction object into an export transaction cookie.

C#
public static byte[] GetExportCookie(System.Transactions.Transaction transaction, byte[] whereabouts);

Parameters

transaction
Transaction

The Transaction object to be marshaled.

whereabouts
Byte[]

An address that describes the location of the destination transaction manager. This permits two transaction managers to communicate with one another and thereby propagate a transaction from one system to the other.

Returns

Byte[]

An export transaction cookie representing the specified Transaction object.

Remarks

Call this method if you want to export a transaction. The transaction that is passed along is marshaled into a transaction cookie. You can then send the transaction cookie to the destination process. This is referred to as propagating the transaction between processes or systems. The propagation is considered to be a push model where the local transaction is pushed to the destination. Therefore, information contained in whereabouts must describe the destination transaction manager.

For more information on different propagation models, see the Remarks section of the TransactionInterop class.

Applies to

Product Versions
.NET Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1