|
CUBRID Engine
latest
|
#include "cas_common.h"#include "cas.h"#include "cas_net_buf.h"#include "cas_network.h"#include "cas_log.h"#include "cas_function.h"#include "cas_execute.h"#include "cas_db_inc.h"#include "xa.h"
Go to the source code of this file.
Macros | |
| #define | CAS_SUPPORT_XA |
| #define | MAX_GTRIDS 100 |
Functions | |
| static int | net_arg_get_xid (XID *xid, char *buf) |
| static void | net_buf_cp_xid (T_NET_BUF *net_buf, XID *xid) |
| static int | compare_xid (XID *xid1, XID *xid2) |
| FN_RETURN | fn_xa_prepare (SOCKET sock_fd, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
| FN_RETURN | fn_xa_recover (SOCKET sock_fd, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
| FN_RETURN | fn_xa_end_tran (SOCKET sock_fd, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
| bool | is_xa_prepared (void) |
| void | set_xa_prepare_flag (void) |
| void | unset_xa_prepare_flag (void) |
Variables | |
| static bool | xa_prepare_flag = false |
| #define MAX_GTRIDS 100 |
Definition at line 43 of file cas_xa.c.
Referenced by fn_xa_end_tran(), and fn_xa_recover().
Definition at line 260 of file cas_xa.c.
References xid_t::bqual_length, xid_t::data, xid_t::formatID, and xid_t::gtrid_length.
Referenced by fn_xa_end_tran().

| FN_RETURN fn_xa_end_tran | ( | SOCKET | sock_fd, |
| int | argc, | ||
| void ** | argv, | ||
| T_NET_BUF * | net_buf, | ||
| T_REQ_INFO * | req_info | ||
| ) |
Definition at line 143 of file cas_xa.c.
References CAS_ER_ARGS, CAS_ER_NOT_IMPLEMENTED, CAS_ER_TRAN_TYPE, CAS_ERROR_INDICATOR, cas_log_write(), compare_xid(), cubregex::count(), db_2pc_attach_transaction(), db_2pc_prepared_transactions(), db_get_global_transaction_info(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, FN_CLOSE_CONN, FN_KEEP_CONN, i, MAX_GTRIDS, net_arg_get_char, net_arg_get_xid(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, set_xa_prepare_flag(), and ux_end_tran().
| FN_RETURN fn_xa_prepare | ( | SOCKET | sock_fd, |
| int | argc, | ||
| void ** | argv, | ||
| T_NET_BUF * | net_buf, | ||
| T_REQ_INFO * | req_info | ||
| ) |
Definition at line 54 of file cas_xa.c.
References CAS_ER_ARGS, CAS_ER_NOT_IMPLEMENTED, CAS_ERROR_INDICATOR, cas_log_write(), db_2pc_prepare_transaction(), db_2pc_start_transaction(), db_set_global_transaction_info(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, FN_KEEP_CONN, net_arg_get_xid(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, and set_xa_prepare_flag().
| FN_RETURN fn_xa_recover | ( | SOCKET | sock_fd, |
| int | argc, | ||
| void ** | argv, | ||
| T_NET_BUF * | net_buf, | ||
| T_REQ_INFO * | req_info | ||
| ) |
Definition at line 104 of file cas_xa.c.
References CAS_ER_NOT_IMPLEMENTED, CAS_ERROR_INDICATOR, cas_log_write(), cubregex::count(), db_2pc_prepared_transactions(), db_get_global_transaction_info(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, FN_KEEP_CONN, i, MAX_GTRIDS, net_buf_cp_int(), net_buf_cp_xid(), NET_BUF_ERR_SET, and NULL.
| bool is_xa_prepared | ( | void | ) |
Definition at line 273 of file cas_xa.c.
References xa_prepare_flag.
Referenced by cas_main(), and shard_cas_main().

|
static |
Definition at line 218 of file cas_xa.c.
References xid_t::bqual_length, xid_t::data, xid_t::formatID, xid_t::gtrid_length, i, and ntohl().
Referenced by fn_xa_end_tran(), and fn_xa_prepare().

Definition at line 250 of file cas_xa.c.
References xid_t::bqual_length, xid_t::data, xid_t::formatID, xid_t::gtrid_length, net_buf_cp_int(), net_buf_cp_str(), and NULL.
Referenced by fn_xa_recover().

| void set_xa_prepare_flag | ( | void | ) |
Definition at line 279 of file cas_xa.c.
References xa_prepare_flag.
Referenced by fn_xa_end_tran(), and fn_xa_prepare().

| void unset_xa_prepare_flag | ( | void | ) |
Definition at line 285 of file cas_xa.c.
References xa_prepare_flag.
Referenced by ux_end_tran().

|
static |
Definition at line 51 of file cas_xa.c.
Referenced by is_xa_prepared(), set_xa_prepare_flag(), and unset_xa_prepare_flag().