mariadb/mysql-test/suite
unknown 451cea3f62 The following statements support the CURRENT_USER() where a user is needed.
DROP USER 
RENAME USER CURRENT_USER() ...
GRANT ... TO CURRENT_USER()
REVOKE ... FROM CURRENT_USER()
ALTER DEFINER = CURRENT_USER() EVENTbut, When these statements are binlogged, CURRENT_USER() just is binlogged
as 'CURRENT_USER()', it is not expanded to the real user name. When slave 
executes the log event, 'CURRENT_USER()' is expand to the user of slave 
SQL thread, but SQL thread's user name always NULL. This breaks the replication.

After this patch, session's user will be written into query log events 
if these statements call CURREN_USER() or 'ALTER EVENT' does not assign a definer.


mysql-test/include/diff_tables.inc:
  Expend its abilities.
  Now it can diff not only in sessions of 'master' and 'slave', but 
  other sessions as well.
mysql-test/include/rpl_diff_tables.inc:
  Diff the same table between master and slaves.
sql/log_event.cc:
  session's user will be written into Query_log_event, if is_current_user_used() is TRUE.
  On slave SQL thread, Only thd->variables.current_user is written into Query_log_event,
  if it exists.
sql/sql_acl.cc:
  On slave SQL thread, grantor should copy from thd->variables.current_user, if it exists
sql/sql_class.h:
  On slave SQL thread, thd->variables.current_user is used to store the applying event's
  invoker.
2010-06-27 12:42:06 +08:00
..
binlog Fix for bug #54393: crash and/or valgrind errors in 2010-06-18 21:32:23 +04:00
bugs Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
engines Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
federated Fix for bug#32426: "FEDERATED query returns corrupt results 2010-03-05 14:51:37 +04:00
funcs_1 5.0-bugteam->5.1-bugteam merge 2009-10-28 13:23:02 +04:00
funcs_2 merge 5.0-> 5.1 2009-04-24 13:00:17 -04:00
ibmdb2i Bug#49329 example (and other) engines use wrong collation for open tables hash 2009-12-11 12:31:16 +05:30
im
innodb Work around Bug #53750 in innodb.innodb_bug48024 2010-05-19 10:56:13 +03:00
innodb_plugin Fix Bug #53592 in plugin code, "crash replacing duplicates into table 2010-05-25 22:31:27 -07:00
jp Bug #45159 : some tests in suite "jp" fail in embedded server (use LOAD DATA) 2009-09-11 15:52:08 +03:00
large_tests
manual Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
ndb Bug #49132 Replication failure on temporary table + DDL 2010-01-22 17:38:21 +08:00
ndb_team Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
parts Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
rpl The following statements support the CURRENT_USER() where a user is needed. 2010-06-27 12:42:06 +08:00
rpl_ndb Postfix BUG#49741 2010-05-25 11:39:45 +08:00
stress Merge trift2.:/MySQL/M51/mysql-5.1 2008-02-22 16:14:27 +01:00
sys_vars Bug#53191 Lock_time in slow log is negative when logging stored routines 2010-06-08 10:58:19 +02:00