Transaction.EnlistPromotableSinglePhase Método

Definición

Inscribe a un administrador de recursos que tiene una transacción interna mediante una Inscripción de fase única promocionable (PSPE).

Sobrecargas

EnlistPromotableSinglePhase(IPromotableSinglePhaseNotification)

Inscribe a un administrador de recursos que tiene una transacción interna mediante una Inscripción de fase única promocionable (PSPE).

EnlistPromotableSinglePhase(IPromotableSinglePhaseNotification, Guid)

Inscribe a un administrador de recursos que tiene una transacción interna mediante una Inscripción de fase única promocionable (PSPE).

EnlistPromotableSinglePhase(IPromotableSinglePhaseNotification)

Source:
Transaction.cs
Source:
Transaction.cs
Source:
Transaction.cs

Inscribe a un administrador de recursos que tiene una transacción interna mediante una Inscripción de fase única promocionable (PSPE).

public:
 bool EnlistPromotableSinglePhase(System::Transactions::IPromotableSinglePhaseNotification ^ promotableSinglePhaseNotification);
public bool EnlistPromotableSinglePhase (System.Transactions.IPromotableSinglePhaseNotification promotableSinglePhaseNotification);
member this.EnlistPromotableSinglePhase : System.Transactions.IPromotableSinglePhaseNotification -> bool
Public Function EnlistPromotableSinglePhase (promotableSinglePhaseNotification As IPromotableSinglePhaseNotification) As Boolean

Parámetros

promotableSinglePhaseNotification
IPromotableSinglePhaseNotification

Interfaz IPromotableSinglePhaseNotification implementada por el participante.

Devoluciones

Implementación de interfaz SinglePhaseEnlistment que describe la inscripción.

Comentarios

Las inscripciones en una transacción son volátiles; es decir, no sobrevive al fracaso del participante. Además, este método solo sugiere al administrador de transacciones que escale el control, pero no se garantiza la extensión en sí. Si se produce un error en la extensión, el usuario no se notifica y se revierte la transacción.

El parámetro promotableSinglePhaseNotification se usa para comunicar al administrador de transacciones el resultado de intentar confirmar la transacción interna del administrador de recursos. Si se notifican datos incoherentes, el administrador de transacciones produce una excepción. Si se notifica un InDoubt resultado, el administrador de transacciones busca la notificación de resultados en su propia inscripción interna y omite la respuesta notificada.

Para obtener más información sobre las inscripciones y la escalación de una transacción, consulte Escalación de administración de transacciones. Para obtener más información sobre PSPE, consulte Optimización mediante confirmación de fase única y notificación de fase única promocional.

Se aplica a

EnlistPromotableSinglePhase(IPromotableSinglePhaseNotification, Guid)

Source:
Transaction.cs
Source:
Transaction.cs
Source:
Transaction.cs

Inscribe a un administrador de recursos que tiene una transacción interna mediante una Inscripción de fase única promocionable (PSPE).

public:
 bool EnlistPromotableSinglePhase(System::Transactions::IPromotableSinglePhaseNotification ^ promotableSinglePhaseNotification, Guid promoterType);
public bool EnlistPromotableSinglePhase (System.Transactions.IPromotableSinglePhaseNotification promotableSinglePhaseNotification, Guid promoterType);
member this.EnlistPromotableSinglePhase : System.Transactions.IPromotableSinglePhaseNotification * Guid -> bool
Public Function EnlistPromotableSinglePhase (promotableSinglePhaseNotification As IPromotableSinglePhaseNotification, promoterType As Guid) As Boolean

Parámetros

promotableSinglePhaseNotification
IPromotableSinglePhaseNotification

Interfaz IPromotableSinglePhaseNotification implementada por el participante.

promoterType
Guid

Tipo de procesador de la transacción distribuida.

Devoluciones

Implementación de interfaz SinglePhaseEnlistment que describe la inscripción.

Comentarios

Si el valor especificado para el promoterType parámetro es TransactionInterop.PromoterTypeDtc, MSDTC debe promover la transacción y el byte[] devuelto desde el IPromotableSinglePhaseNotification.Promote método debe ser un token de propagación de transacciones MSDTC.

Si el valor especificado para el promoterType parámetro noTransactionInterop.PromoterTypeDTC es , MSDTC no promoverá la transacción, sino la implementación del autor de la llamada de IPromotableSinglePhaseNotification. Si esta llamada se realiza correctamente, hay un conjunto de operaciones posteriores en la transacción que devolverá un TransactionPromotionException. Estas operaciones son:

  • Transaction.EnlistDurable

  • TransactionInterop.GetDtcTransaction

  • TransactionInterop.GetExportCookie

  • TransactionInterop.GetTransmitterPropagationToken

  • Serialización de un objeto Transaction

Se aplica a