XTA: API Reference for C language

xta_mysql_xa_resource.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2009-2019, Christian Ferrari <tiian@users.sourceforge.net>
3  * All rights reserved.
4  *
5  * This file is part of LIXA.
6  *
7  * LIXA is free software: you can redistribute this file and/or modify
8  * it under the terms of the GNU Lesser General Public License version 2.1 as
9  * published by the Free Software Foundation.
10  *
11  * LIXA is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with LIXA. If not, see <http://www.gnu.org/licenses/>.
18  */
19 #ifndef MYSQL_XA_RESOURCE_H
20 # define MYSQL_XA_RESOURCE_H
21 
22 
23 
24 /* MySQL front-end */
25 #include <mysql.h>
26 /* XTA includes */
28 /* LIXA includes */
29 #include "lixa_sw.h"
30 
31 
32 
36 typedef struct {
37  union {
40  };
44  MYSQL *connection;
49  struct lixa_sw_status_rm_s lssr;
51 
52 
53 
54 #ifdef __cplusplus
55 extern "C" {
56 #endif /* __cplusplus */
57 
58 
59 
72  const char *name,
73  const char *open_info);
74 
75 
76 
82 
83 
84 
98  MYSQL *connection,
99  const char *name, const char *open_info);
100 
101 
102 
110 
111 
112 
125  int xta_mysql_xa_close(xta_xa_resource_t *context, char *xa_info,
126  int rmid, long flags);
127 
128 
129 
140  int xta_mysql_xa_commit(xta_xa_resource_t *context, const XID *xid,
141  int rmid, long flags);
142 
143 
144 
156  int xta_mysql_xa_end(xta_xa_resource_t *context, const XID *xid,
157  int rmid, long flags);
158 
159 
160 
171  int xta_mysql_xa_forget(xta_xa_resource_t *context, const XID *xid,
172  int rmid, long flags);
173 
174 
175 
188  int xta_mysql_xa_open(xta_xa_resource_t *context, char *xa_info,
189  int rmid, long flags);
190 
191 
192 
203  int xta_mysql_xa_prepare(xta_xa_resource_t *context, const XID *xid,
204  int rmid, long flags);
205 
206 
207 
222  XID *xids, long count, int rmid, long flags);
223 
224 
225 
236  int xta_mysql_xa_rollback(xta_xa_resource_t *context, const XID *xid,
237  int rmid, long flags);
238 
239 
240 
251  int xta_mysql_xa_start(xta_xa_resource_t *context, const XID *xid,
252  int rmid, long flags);
253 
254 
255 
256 #ifdef __cplusplus
257 }
258 #endif /* __cplusplus */
259 
260 
261 
262 #endif /* MYSQL_XA_RESOURCE_H */
int xta_mysql_xa_recover(xta_xa_resource_t *context, XID *xids, long count, int rmid, long flags)
int xta_mysql_xa_open(xta_xa_resource_t *context, char *xa_info, int rmid, long flags)
int xta_mysql_xa_rollback(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
int xta_mysql_xa_start(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
xta_mysql_xa_resource_t * xta_mysql_xa_resource_new(MYSQL *connection, const char *name, const char *open_info)
void xta_mysql_xa_resource_delete(xta_mysql_xa_resource_t *xa_resource)
int xta_mysql_xa_prepare(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
int xta_mysql_xa_end(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
int xta_mysql_xa_resource_init(xta_mysql_xa_resource_t *xa_resource, MYSQL *connection, const char *name, const char *open_info)
int xta_mysql_xa_forget(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
Definition: xa.h:28
int xta_mysql_xa_close(xta_xa_resource_t *context, char *xa_info, int rmid, long flags)
xta_acquired_xa_resource_t acquired_xa_resource
int xta_mysql_xa_commit(xta_xa_resource_t *context, const XID *xid, int rmid, long flags)
void xta_mysql_xa_resource_clean(xta_mysql_xa_resource_t *xa_resource)

Copyright © 2009-2019, Christian Ferrari tiian@users.sourceforge.net http://www.tiian.org/