TransactionManager.Reenlist(Guid, Byte[], IEnlistmentNotification) 메서드

정의

트랜잭션에서 지속성 참가자를 다시 목록에 추가합니다.

public:
 static System::Transactions::Enlistment ^ Reenlist(Guid resourceManagerIdentifier, cli::array <System::Byte> ^ recoveryInformation, System::Transactions::IEnlistmentNotification ^ enlistmentNotification);
public static System.Transactions.Enlistment Reenlist(Guid resourceManagerIdentifier, byte[] recoveryInformation, System.Transactions.IEnlistmentNotification enlistmentNotification);
static member Reenlist : Guid * byte[] * System.Transactions.IEnlistmentNotification -> System.Transactions.Enlistment
Public Shared Function Reenlist (resourceManagerIdentifier As Guid, recoveryInformation As Byte(), enlistmentNotification As IEnlistmentNotification) As Enlistment

매개 변수

resourceManagerIdentifier
Guid

Guid 리소스 관리자를 고유하게 식별하는 A입니다.

recoveryInformation
Byte[]

복구 정보에 대한 추가 정보를 포함합니다.

enlistmentNotification
IEnlistmentNotification

알림을 수신하도록 구현하는 IEnlistmentNotification 리소스 개체입니다.

반품

Enlistment 인리스트먼트를 설명하는 것입니다.

예외

recoveryInformation 가 잘못되었습니다.

-또는-

트랜잭션 관리자 정보가 recoveryInformation 구성된 트랜잭션 관리자와 일치하지 않습니다.

-또는-

recoveryInformation 에서 인식할 수 System.Transactions없습니다.

RecoveryComplete(Guid) 지정된 resourceManagerIdentifier에 대해 이미 호출되었습니다. 재등록이 거부됩니다.

resourceManagerIdentifier 있는 지정된 복구 정보의 recoveryInformation내용과 일치하지 않습니다.

설명

중요합니다

신뢰할 수 없는 데이터로 이 메서드를 호출하는 것은 보안 위험입니다. 신뢰할 수 있는 데이터로만 이 메서드를 호출합니다. 자세한 내용은 모든 입력 유효성 검사참조하세요.

리소스 관리자는 리소스 실패 후 트랜잭션 참가자를 재등록하여 트랜잭션의 내구성 있는 등록 문제를 해결하는 데 도움을 줍니다.

resourceManagerIdentifier 매개 변수는 리소스 오류가 발생할 경우 트랜잭션 참가자에게 일관되게 레이블을 지정하는 데 사용됩니다. 메서드를 호출할 Reenlist 때 리소스 관리자는 원래 인리스트먼트 중에 메서드를 호출 EnlistDurable 하거나 TransactionException throw할 때 사용한 것과 동일하게 resourceManagerIdentifier 제공해야 합니다.

이 메서드를 사용하여 참가자를 다시 목록에 추가하면 트랜잭션의 결과(즉, CommitRollback또는 InDoubt )에 해당하는 2단계 메서드 IEnlistmentNotification 가 적절하게 호출됩니다.

참가자가 성공적으로 다시 등록되면 호출 RecoveryComplete 하여 복구를 완료해야 합니다.

리소스 관리자가 실패에서 다시 시작하는 경우에만 이 메서드를 호출해야 합니다. 또한 2단계 커밋의 초기 준비 단계에서 리소스 관리자가 기록한 해결되지 않은 트랜잭션만 다시 등록해야 합니다. 잘못된 시간에 이 메서드를 호출하려고 하면 잘못된 결과가 발생할 수 있습니다.

트랜잭션 관리자가 실패하고 리소스 관리자가 Two-Phase 커밋 프로토콜의 1단계에서 인리스트먼트에서 메서드를 호출 Prepared 한 후 잠시 후에만 복구를 수행하는 경우 리소스 관리자가 콜백을 받거나 Rollback 콜백을 받을 InDoubt 수 있습니다.

적용 대상