1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-07 02:42:49 +03:00

10 Commits

Author SHA1 Message Date
Georg Richter
1acb81e11c Build fixes:
- Fixed build error, which was previously introduced by commit
c8ca89112e

- Treat warnings as errors
2023-08-16 14:09:34 +02:00
Georg Richter
c8ca89112e Fix for CONC-659:
When checking for a semi sync indication header, we need also check if
the undocumented session variable @rpl_semi_sync_slave was set.
Otherwise the timestamp of the event could contain values which match
the 2 bytes of the semi sync header.

Since the variable rpl_semi_sync_slave and it's behavior is not documented,
a new option MARIADB_RPL_SEMI_SYNC was added.
2023-08-11 10:14:26 +02:00
Georg Richter
dbb4d8d93b Fixed segfault:
Use rpl->host and port instead of mysql->options.
2023-02-22 11:32:21 +01:00
Georg Richter
fcce4a8c76 CONC-592: Register replica with host and port
Added new option MARIADB_OPT_RPL_REGISTER_REPLICA which expects
two parameters, host and port. When this option was set, rpl_open
will send a COM_REGISTER_SLAVE command with server_id, host and
port to the connected server. This information can be retrieved
by "SHOW SLAVE STATUS" command.

Example:

rc= mysql_optionsv(mysql, MARIADB_OPT_RPL_REGISTER_REPLICA,
                   "myhost", 123);
2022-05-23 14:05:06 +02:00
Georg Richter
e8fc259320 CONC-467: Rotate event doesn't handle filename correctly
When receiving a ROTATE event, the offset of filename
was not computed correctly. Similiar to the
BINLOG_CHECK_POINT event filename will also be stored
in MARIADB_RPL handle
2021-10-09 10:44:04 +02:00
Georg Richter
004f9d4217 CONC-470: Support for semi synchronous replication
Beside already supported asynchronous replication
the replication/binlog API now supports semi
synchronous replication:

If an event contains a semi synchronous indicator (0xEF)
behind status byte and acknowledgement flag is set,
mariadb_rpl_fetch() automatically sends an acknowledge
message to the connected primary server.
2021-10-09 08:26:15 +02:00
Georg Richter
c098613d28 Moved rpl_api test to manual tests, since there is an endless loop
for now without timeout.
2019-06-14 13:48:31 +02:00
Sergei Golubchik
4ac8030b33 fix memory leaks to keep LeakSanitizer happy 2019-03-05 20:21:32 +01:00
Sergei Golubchik
cdf5eab4cc compiler warnings - unused variables 2019-02-04 16:05:27 +01:00
Georg Richter
1888c141f7 Manual merge from CONC-325 branch: Initial implementation for binlog/replication API 2018-12-02 18:28:38 +01:00