Fix bug 1711781 (Redundant GTID unsafe mark for CREATE/DROP TEMPORARY… #1929
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
… TABLE in RBR/MBR)
After fixing bug 1668602, bug 1539504, and bug 1313901, CREATE
TEMPORARY TABLE is only logged under statement binary log mode, and
DROP TEMPORARY TABLE is only logged if the corresponding CREATE
TEMPORARY TABLE has been logged. However, a corresponding
enforce_gtid_consistency check in THD::is_ddl_gtid_compatible has not
been relaxed accordingly. This resulted that CREATE/DROP TEMPORARY
TABLE statements were forbidden incorrectly in transactional contexts,
including function and trigger calls, even when they required no
binary logging at all.
Fix by keeping only the CREATE TEMPORARY TABLE check in
THD::is_ddl_gtid_compatible and lifting its restriction for row/mixed
binary log modes. For DROP TEMPORARY TABLE, since its check requires
knowing the binlog format at the corresponding CREATE TEMPORARY TABLE,
move it to mysql_rm_table.
Convert binlog.binlog_enforce_gtid_consistency test to an include file
that is shared between two new binlog format-dependent tests
binlog_stm_enforce_gtid_consistency and
binlog_row_mix_enforce_gtid_consistency.
http://jenkins.percona.com/job/percona-server-5.6-param/1988/