Commit graph

10 commits

Author SHA1 Message Date
Monty
546e7aa96f MDEV-8203 Assert in Query_log_event::do_apply_event()
This happens because the master writes a table_map event to the binary log, but no row event.
The slave has a check that there should always be a row event if there was a table_map event, which
causes a crash.

Fixed by remembering in the cache what kind of events are logged
and ignore cached statements which is just a table map event.
2017-04-07 15:58:17 +04:00
Sergei Golubchik
4a5d25c338 Merge branch '10.1' into 10.2 2016-12-29 13:23:18 +01:00
Nirbhay Choubey
9c88a54c10 MDEV-11179: WSREP transaction excceded size limit in Galera cluster
... causes MariaDB to crash

On error, the wsrep replication buffer (binlog) is dumped to a file
to aid investigations. In order to also include the binlog header,
FDLE object is also needed. This object is only available for wsrep-
threads.
Fix: Instantiate an FDLE object for non-wsrep threads.
2016-12-12 08:51:50 -05:00
Monty
b3093073b1 Changed my_thread_id to int64 to fix compilation problem with
my_atomic_add32_explicit on windows
Fixed that server_audit.c also works if one compiles with safemalloc
Fixed compiler warnings
2016-02-08 22:34:41 +02:00
Sergei Golubchik
41d68cabee cleanup: Log_event::write() and MYSQL_BIN_LOG::write_cache()
Introduce Log_event_writer() that encapsulates
writing data to an IO_CACHE with automatic checksum calculation.

Now all events properly checksum themselves as needed.

Use Log_event_writer in MYSQL_BIN_LOG::write_cache() instead
of copy-pasting its logic all over.

Later Log_event_writer will also do encryption.
2015-09-04 10:33:55 +02:00
Nirbhay Choubey
dd4d81ddfd Update read_pos after reading from the cache. 2015-07-14 16:58:38 -04:00
Sergei Golubchik
6309a30dc9 my_b_fill, inline my_b_* functions instead of hairy macros 2015-06-02 18:53:37 +02:00
Sergei Golubchik
196e852983 misc IO_CACHE cleanups
* remove unused (and not implemented) WRITE_NET type
* remove cast in my_b_write() macro. my_b_* macros are
  function-like, casts are responsibility of the caller
* replace hackish _my_b_write(info,0,0) with the explicit
  my_b_flush_io_cache() in my_b_write_byte()
* remove unused my_b_fill_cache()
* replace pbool -> my_bool
* make internal IO_CACHE functions static
* reformat comments, correct typos, remove obsolete comments (ISAM)
* assert valid cache type in init_functions()
* use IO_ROUND_DN() macro where appropriate
* remove unused DBUG_EXECUTE_IF in _my_b_cache_write()
* remove unnecessary __attribute__((unused))
* fix goto error in parse_file.cc
* remove redundant reinit_io_cache() in uniques.cc
* don't do reinit_io_cache() if the cache was not initialized
  in ma_check.c
* extract duplicate functionality from various _my_b_*_read
  functions into a common wrapper. Same for _my_b_*_write
* create _my_b_cache_write_r instead of having if's in
  _my_b_cache_write (similar to existing _my_b_cache_read and
  _my_b_cache_read_r)
* don't call mysql_file_write() from my_b_flush_io_cache(),
  call info->write_function() instead
2015-06-02 18:53:37 +02:00
Nirbhay Choubey
575dd77504 MDEV-7867: Add binlog header to GRA_.log file 2015-04-01 18:25:40 -04:00
Jan Lindström
df4dd593f2 MDEV-6247: Merge 10.0-galera to 10.1.
Merged lp:maria/maria-10.0-galera up to revision 3879.

Added a new functions to handler API to forcefully abort_transaction,
producing fake_trx_id, get_checkpoint and set_checkpoint for XA. These
were added for future possiblity to add more storage engines that
could use galera replication.
2014-08-26 15:43:46 +03:00