Platform SDK: Transaction Server

Life of a Transaction: Resource Manager Startup (Phases)

c1 The resource manager calls the DtcGetTransactionManager procedure in the MS DTC proxy to establish a connection to the transaction manager. The resource manager may either specify the name and location of the transaction manager it chooses to use or it may specify NULL values for these parameters. Normally, the resource manager specifies NULL values for these parameters. This causes the MS DTC proxy to establish a connection with the default MS DTC transaction manager. The name of the default transaction manager is contained in the system registry.
c2 The DtcGetTransactionManager system call is implemented by the MS DTC proxy. The MS DTC proxy returns a pointer to the IUnknown interface of the MS DTC proxy core object.
c3.1 The resource manager invokes the IUnknown::QueryInterface method on the MS DTC proxy core object to obtain the IResourceManagerFactory interface.
c3.2 The resource manager invokes the IResourceManagerFactory::Create method. The resource manager passes its own GUID (guidRM) and string name. The transaction manager will use the resource manager’s string name to label the resource manager. This simplifies system administration by associating a symbolic name with the resource manager.
c4 When the IResourceManagerFactory::Create method is called, the MS DTC proxy calls the Connection Manager to establish a connection to the transaction manager.
c5 The transaction manager creates a internal object that represents the connection between the resource manager and the transaction manager. The transaction manager then returns to the MS DTC proxy.
c6 The MS DTC proxy creates a resource manager object and returns a pointer to the IResourceManager interface of that object to the resource manager. The IResourceManager interface is used by the resource manager to enlist in transactions and to perform transaction recovery.