3.8.7.7 Phase One Complete
The Phase One Complete event MUST be signaled with the following arguments:
An Enlistment object.
A value indicating the outcome of Phase One. The value MUST be set to one of the following values:
Read Only
Prepared
Committed
Aborted
In Doubt
If the Phase One Complete event is signaled, the Subordinate Transaction Manager Facet (section 3.8) MUST perform the following actions:
If the provided outcome is Read Only:
Send a PARTNERTM_PROPAGATE_MTAG_PREPAREREQDONE (section 2.2.9.1.1.1.7) message using the provided enlistment's connection:
Set the prepareReqDone field to PARTNERTM_PROPAGATE_PREPAREREQDONE_READ_ONLY.
Set the guidReason field to the value provided by the higher-layer business logic, as specified in section 2.2.9.1.1.1.7.
Set the connection state to Ended.
Otherwise, if the provided outcome is Prepared:
Send a PARTNERTM_PROPAGATE_MTAG_PREPAREREQDONE (section 2.2.9.1.1.1.7) message using the provided enlistment's connection:
Set the prepareReqDone field to PARTNERTM_PROPAGATE_PREPAREREQDONE_OK.
Set the connection state to Ended.
Otherwise, if the provided outcome is Committed:
Send a PARTNERTM_PROPAGATE_MTAG_PREPAREREQDONE (section 2.2.9.1.1.1.7) message using the connection:
Set the prepareReqDone field to PARTNERTM_PROPAGATE_PREPAREREQDONE_SINGLEPHASE_COMMIT.
Set the connection state to Ended.
Otherwise, if the provided outcome is Aborted:
Send a PARTNERTM_PROPAGATE_MTAG_PREPAREREQDONE (section 2.2.9.1.1.1.7) message using the connection:
Set the prepareReqDone field MUST to PARTNERTM_PROPAGATE_PREPAREREQDONE_ABORT.
Set the connection state to Ended.
Otherwise, if the provided outcome is In Doubt (section 3.2.1.3.12):
Send a PARTNERTM_PROPAGATE_MTAG_PREPAREREQDONE (section 2.2.9.1.1.1.7) message using the connection:
Set the prepareReqDone field MUST to PARTNERTM_PROPAGATE_PREPAREREQDONE_SINGLEPHASE_INDOUBT.
Set the connection state to Ended.