diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-08-12 18:23:42 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-08-12 18:25:35 +0300 |
commit | be33124c9dc284c4409d02e5405de568b467a167 (patch) | |
tree | 7188f6effdace66ce24af17fd1bd0d89f5b76999 /sql/sql_class.h | |
parent | fe8181aca13cf7ba1835fa6c89f297a1d0e79856 (diff) | |
parent | 15c1ab52a9f2827724c5d007ce7b8c607dc8f0a9 (diff) | |
download | mariadb-git-be33124c9dc284c4409d02e5405de568b467a167.tar.gz |
Merge 10.1 into 10.2
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 40 |
1 files changed, 26 insertions, 14 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index fdb24097159..b490c44d816 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -2399,6 +2399,20 @@ public: /* container for handler's private per-connection data */ Ha_data ha_data[MAX_HA]; + /** + Bit field for the state of binlog warnings. + + The first Lex::BINLOG_STMT_UNSAFE_COUNT bits list all types of + unsafeness that the current statement has. + + This must be a member of THD and not of LEX, because warnings are + detected and issued in different places (@c + decide_logging_format() and @c binlog_query(), respectively). + Between these calls, the THD->lex object may change; e.g., if a + stored routine is invoked. Only THD persists between the calls. + */ + uint32 binlog_unsafe_warning_flags; + #ifndef MYSQL_CLIENT binlog_cache_mngr * binlog_setup_trx_data(); @@ -2508,20 +2522,6 @@ private: */ enum_binlog_format current_stmt_binlog_format; - /** - Bit field for the state of binlog warnings. - - The first Lex::BINLOG_STMT_UNSAFE_COUNT bits list all types of - unsafeness that the current statement has. - - This must be a member of THD and not of LEX, because warnings are - detected and issued in different places (@c - decide_logging_format() and @c binlog_query(), respectively). - Between these calls, the THD->lex object may change; e.g., if a - stored routine is invoked. Only THD persists between the calls. - */ - uint32 binlog_unsafe_warning_flags; - /* Number of outstanding table maps, i.e., table maps in the transaction cache. @@ -4165,6 +4165,18 @@ public: } void leave_locked_tables_mode(); int decide_logging_format(TABLE_LIST *tables); + /* + In Some cases when decide_logging_format is called it does not have all + information to decide the logging format. So that cases we call decide_logging_format_2 + at later stages in execution. + One example would be binlog format for IODKU but column with unique key is not inserted. + We dont have inserted columns info when we call decide_logging_format so on later stage we call + decide_logging_format_low + + @returns 0 if no format is changed + 1 if there is change in binlog format + */ + int decide_logging_format_low(TABLE *table); enum need_invoker { INVOKER_NONE=0, INVOKER_USER, INVOKER_ROLE}; void binlog_invoker(bool role) { m_binlog_invoker= role ? INVOKER_ROLE : INVOKER_USER; } |