Share via


msqlsrvxa1

 

Applies To: Windows 10, Windows 7, Windows 8, Windows 8.1, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2, Windows Server Technical Preview, Windows Vista

The msqlsrvxa1 structure exposes the XA routines of MSDTC to an XA transaction manger, so MSDTC can be used as a resource manager for XA transactions. The fields of msqlsrvxa1 contain function pointers that point to the XA routines in MSDTC. msqlsrvxa1 is the MSDTC implementation of the xa_switch_t structure from the XA standard.

Syntax

Here’s how the syntax of xa_switch_t is defined in the XA standard:

struct xa_switch_t {  
   char name[RMNAMESZ];  
   long flags;  
   long version;  
   int (∗xa_open_entry)(char ∗, int, long);  
   int (∗xa_close_entry)(char ∗, int, long);  
   int (∗xa_start_entry)(XID ∗, int, long);  
   int (∗xa_end_entry)(XID ∗, int, long);  
   int (∗xa_rollback_entry)(XID ∗, int, long);  
   int (∗xa_prepare_entry)(XID ∗, int, long);  
   int (∗xa_commit_entry)(XID ∗, int, long);  
   int (∗xa_recover_entry)(XID ∗, long, int, long);  
   int (∗xa_forget_entry)(XID ∗, int, long);  
   int (∗xa_complete_entry)(int ∗, int ∗, int, long);  
};  
  

Members

msqlsrvxa1 contains the following function pointers:

xa_open_entry
A pointer to the xa_open routine.

xa_close_entry
A pointer to the xa_close routine.

xa_start_entry
A pointer to the xa_start routine.

xa_end_entry
A pointer to the xa_end routine.

xa_rollback_entry
A pointer to the xa_rollback routine.

xa_prepare_entry
A pointer to the xa_prepare routine.

xa_commit_entry
A pointer to the xa_commit routine.

xa_recover_entry
A pointer to the xa_recover routine.

xa_forget_entry
A pointer to the xa_forget routine.

xa_complete_entry
A pointer to the xa_complete routine.

Remarks

To use msqlsrvxa1, you must statically link to the xaswitch.lib library, and then add the following code to any C or C++ source files that need to call XA routines.

extern "C"  
{          
   extern struct xa_switch_t msqlsrvxa1;  
}  
  

For more information, see Developing an XA Transaction Manager for MSDTC.

See Also

DTC Structures