This patch:
- Moves all definitions from the mysql_priv.h file into
header files for the component where the variable is
defined
- Creates header files if the component lacks one
- Eliminates all include directives from mysql_priv.h
- Eliminates all circular include cycles
- Rename time.cc to sql_time.cc
- Rename mysql_priv.h to sql_priv.h
Implemented the server infrastructure for the fix:
1. Added a function LEX_STRING *thd_query_string(THD) to return
a LEX_STRING structure instead of char *.
This is the function that must be called in innodb instead of
thd_query()
2. Did some encapsulation in THD : aggregated thd_query and
thd_query_length into a LEX_STRING and made accessor and mutator
methods for easy code updating.
3. Updated the server code to use the new methods where applicable.
CREATE/DROP TEMPORARY TABLE + ROLLBACK on master
The transaction ability of the storage engines of
the tables on the replication master and the replication
slave must generally be the same.
When the storage engine type of the slave is
non-transactional then transactions on the master that
mix update of transactional and non-transactional tables
should be avoided because they will cause inconsistency of
the data between the master's transactional table and the
slave's non-transactional table.
The effect described by this bug is actually expected.
A detailed test case is added (to be merged later to
the updated rpl_ddl.test), as there was no coverage
by the existing tests.
Some code cleanup is also added by this change.
mysql-test/r/rpl_innodb.result:
Bug #26418: test case
mysql-test/t/rpl_innodb.test:
Bug #26418: test case
sql/events.cc:
Bug #26418: replace repeating code with a function call
sql/sp.cc:
Bug #26418: replace repeating code with a function call
sql/sql_acl.cc:
Bug #26418: replace repeating code with a function call
sql/sql_class.cc:
Bug #26418: remove dead code
sql/sql_class.h:
Bug #26418: remove dead code
sql/sql_delete.cc:
Bug #26418: replace repeating code with a function call
sql/sql_parse.cc:
Bug #26418: replace repeating code with a function call
sql/sql_rename.cc:
Bug #26418: replace repeating code with a function call
sql/sql_tablespace.cc:
Bug #26418: replace repeating code with a function call
sql/sql_trigger.cc:
Bug #26418: replace repeating code with a function call
sql/sql_udf.cc:
Bug #26418: replace repeating code with a function call
sql/sql_view.cc:
Bug #26418: replace repeating code with a function call
"Server Variables for Plugins"
Implement support for plugins to declare server variables.
Demonstrate functionality by removing InnoDB specific code from sql/*
New feature for HASH - HASH_UNIQUE flag
New feature for DYNAMIC_ARRAY - initializer accepts preallocated ptr.
Completed support for plugin reference counting.
include/hash.h:
New flag for HASH
HASH_UNIQUE
include/my_getopt.h:
New data types for options: ENUM and SET.
Use typelib to enumerate possible values.
New flag variable:
my_getopt_skip_unknown
include/my_sys.h:
change to DYNAMIC_ARRAY init functions to support pre-allocated buffers
include/mysql.h:
relocate inclusion of typelib due to longlong requirement
include/mysql/plugin.h:
wl2936
New declarations for plugin server variable support.
New functions for use by plugins
include/mysys_err.h:
new my_getopt return value: EXIT_ARGUMENT_INVALID
include/typelib.h:
new typelib function: find_typeset(), returns an int which is a SET of
the elements in the typelib
mysql-test/r/im_utils.result:
change to more specific command line settings
--skip-innodb => --skip-plugin-innodb
etc.
mysql-test/r/log_tables.result:
set default storage engine to MEMORY so that test will succeed even
when some of the other named storage engines are not present
mysql-test/r/ndb_dd_basic.result:
change in error message
mysql-test/r/partition_innodb.result:
change in results
mysql-test/r/ps_1general.result:
bdb doesn't exist, use myisam for a non-transactional engine
mysql-test/r/variables.result:
information schema doesn't sort row results for server variables.
mysql-test/t/log_tables.test:
set default storage engine to MEMORY so that test will succeed even
when some of the other named storage engines are not present
mysql-test/t/ndb_dd_basic.test:
ALTER LOGFILE GROUP no longer silently fail here
mysql-test/t/partition_innodb.test:
ALTER TABLE no longer silently fails for unknown storage engine
mysql-test/t/ps_1general.test:
remove unneccessary parts
use myisam as it is an always present non-transactional engine
mysql-test/t/variables.test:
information schema doesn't sort row results for server variables.
mysql-test/t/warnings_engine_disabled-master.opt:
use the new style command line option
mysys/array.c:
change to DYNAMIC_ARRAY init functions to support pre-allocated buffers
mysys/hash.c:
New flag for HASH
HASH_UNIQUE
Implement HASH_UNIQUE functionality by performing a hash_search
mysys/my_getopt.c:
New data types for options: ENUM and SET.
Use typelib to enumerate possible values.
New flag variable:
my_getopt_skip_unknown
mysys/typelib.c:
new typelib function: find_typeset(), returns an int which is a SET of
the elements in the typelib
sql/ha_ndbcluster.cc:
use ha_statistic_increment() method instead of
statistic_increment() function
ha_ndbcluster variable has gone away.
sql/ha_partition.cc:
fix for reference counting
sql/ha_partition.h:
fix for reference counting
sql/handler.cc:
fixes for reference counting
sql/handler.h:
fixes for reference counting
some new methods to aid storage engine writers
sql/item_func.cc:
find_sys_var() function now requires thd
sql/item_sum.cc:
fixes for ref counting
sql/mysql_priv.h:
remove unneccessary globals.
new lock: LOCK_system_variables_hash
sql/mysqld.cc:
Remove InnoBase specific code.
Support plugin command line processing.
sql/set_var.cc:
Remove InnoBase specific declarations
Remove redundant declarations
changes to permit new variables at run time
changes for ref counting
sql/set_var.h:
changes to permit new variables at run time
changes for ref counting
sql/sql_base.cc:
changes for ref counting
sql/sql_cache.cc:
mark code as needing work in the future
sql/sql_class.cc:
new functions to aid plugin authors
initialize variables for dynamic plugin variables
sql/sql_class.h:
remove InnoBase specific declarations
New declarations for plugin variables.
sql/sql_connect.cc:
initialization and cleanup of plugin variables
sql/sql_delete.cc:
change for ref counting
sql/sql_insert.cc:
change for ref counting
sql/sql_lex.cc:
changes for ref counting and plugin variables
sql/sql_lex.h:
add properties for plugin ref counting,
add to distructor to clean up
sql/sql_partition.cc:
changes for ref counting
sql/sql_plugin.cc:
WL2936
Plugin Variables
New methods and code to support server variables for plugins.
New code to complete plugin reference counting
Debug code adds further indirection so that malloc debugging can be
used to aid finding plugin ref count leaks
sql/sql_plugin.h:
WL2936
Plugin Variables
New methods and code to support server variables for plugins.
New code to complete plugin reference counting
Debug code adds further indirection so that malloc debugging can be
used to aid finding plugin ref count leaks
sql/sql_repl.cc:
replication system variables moved here from set_var.cc
sql/sql_repl.h:
new function to initialise replication server variables
sql/sql_select.cc:
changes for ref counting
sql/sql_show.cc:
changes for ref counting
sql/sql_table.cc:
changes for ref counting
sql/sql_tablespace.cc:
use supplied functions instead of digging into data structures manually
sql/sql_yacc.yy:
changes for ref counting
find_sys_var() now requires thd parameter
changes on reporting errors to keep user-visible behaviour the same.
sql/structs.h:
changes for ref counting
sql/table.cc:
changes for ref counting
sql/table.h:
changes for ref counting
storage/federated/ha_federated.cc:
use ha_statistic_increment() method instead of statistic_increment()
function
storage/heap/ha_heap.cc:
use ha_statistic_increment() method instead of statistic_increment()
function
storage/innobase/handler/ha_innodb.cc:
use ha_statistic_increment() method instead of statistic_increment()
function
WL2936
Move InnoBase specific code out of mysqld.cc and into here
Declare all required server variables for InnoBase
storage/innobase/include/trx0trx.h:
store a bit more state so that InnoBase does not have to dig into
mysqld internal data structures.
storage/myisam/ha_myisam.cc:
use ha_statistic_increment() method instead of statistic_increment()
function
storage/myisammrg/ha_myisammrg.cc:
use ha_statistic_increment() method instead of statistic_increment()
function
Changed header to GPL version 2 only
client/mysqlslap.c:
Changed header to GPL version 2 only
include/atomic/nolock.h:
Changed header to GPL version 2 only
include/atomic/rwlock.h:
Changed header to GPL version 2 only
include/atomic/x86-gcc.h:
Changed header to GPL version 2 only
include/atomic/x86-msvc.h:
Changed header to GPL version 2 only
include/my_atomic.h:
Changed header to GPL version 2 only
include/my_trie.h:
Changed header to GPL version 2 only
include/my_vle.h:
Changed header to GPL version 2 only
include/mysql/plugin.h:
Changed header to GPL version 2 only
mysys/my_atomic.c:
Changed header to GPL version 2 only
mysys/my_getncpus.c:
Changed header to GPL version 2 only
mysys/my_memmem.c:
Changed header to GPL version 2 only
mysys/my_vle.c:
Changed header to GPL version 2 only
mysys/trie.c:
Changed header to GPL version 2 only
plugin/Makefile.am:
Changed header to GPL version 2 only
server-tools/instance-manager/IMService.h:
Changed header to GPL version 2 only
server-tools/instance-manager/WindowsService.h:
Changed header to GPL version 2 only
server-tools/instance-manager/exit_codes.h:
Changed header to GPL version 2 only
server-tools/instance-manager/user_management_commands.h:
Changed header to GPL version 2 only
sql/authors.h:
Changed header to GPL version 2 only
sql/contributors.h:
Changed header to GPL version 2 only
sql/event_data_objects.cc:
Changed header to GPL version 2 only
sql/event_data_objects.h:
Changed header to GPL version 2 only
sql/event_db_repository.cc:
Changed header to GPL version 2 only
sql/event_db_repository.h:
Changed header to GPL version 2 only
sql/event_queue.cc:
Changed header to GPL version 2 only
sql/event_queue.h:
Changed header to GPL version 2 only
sql/event_scheduler.cc:
Changed header to GPL version 2 only
sql/event_scheduler.h:
Changed header to GPL version 2 only
sql/events.cc:
Changed header to GPL version 2 only
sql/events.h:
Changed header to GPL version 2 only
sql/ha_ndbcluster_binlog.cc:
Changed header to GPL version 2 only
sql/ha_ndbcluster_binlog.h:
Changed header to GPL version 2 only
sql/ha_ndbcluster_tables.h:
Changed header to GPL version 2 only
sql/ha_partition.cc:
Changed header to GPL version 2 only
sql/ha_partition.h:
Changed header to GPL version 2 only
sql/item_xmlfunc.cc:
Changed header to GPL version 2 only
sql/item_xmlfunc.h:
Changed header to GPL version 2 only
sql/log.h:
Changed header to GPL version 2 only
sql/partition_element.h:
Changed header to GPL version 2 only
sql/partition_info.cc:
Changed header to GPL version 2 only
sql/partition_info.h:
Changed header to GPL version 2 only
sql/rpl_filter.cc:
Changed header to GPL version 2 only
sql/rpl_filter.h:
Changed header to GPL version 2 only
sql/rpl_injector.cc:
Changed header to GPL version 2 only
sql/rpl_injector.h:
Changed header to GPL version 2 only
sql/rpl_mi.cc:
Changed header to GPL version 2 only
sql/rpl_mi.h:
Changed header to GPL version 2 only
sql/rpl_rli.cc:
Changed header to GPL version 2 only
sql/rpl_rli.h:
Changed header to GPL version 2 only
sql/rpl_tblmap.cc:
Changed header to GPL version 2 only
sql/rpl_tblmap.h:
Changed header to GPL version 2 only
sql/rpl_utility.cc:
Changed header to GPL version 2 only
sql/rpl_utility.h:
Changed header to GPL version 2 only
sql/sql_binlog.cc:
Changed header to GPL version 2 only
sql/sql_partition.cc:
Changed header to GPL version 2 only
sql/sql_partition.h:
Changed header to GPL version 2 only
sql/sql_plugin.cc:
Changed header to GPL version 2 only
sql/sql_plugin.h:
Changed header to GPL version 2 only
sql/sql_servers.cc:
Changed header to GPL version 2 only
sql/sql_servers.h:
Changed header to GPL version 2 only
sql/sql_tablespace.cc:
Changed header to GPL version 2 only
sql/sql_yacc.yy.bak:
Changed header to GPL version 2 only
storage/Makefile.am:
Changed header to GPL version 2 only
storage/archive/Makefile.am:
Changed header to GPL version 2 only
storage/blackhole/Makefile.am:
Changed header to GPL version 2 only
storage/csv/Makefile.am:
Changed header to GPL version 2 only
storage/example/Makefile.am:
Changed header to GPL version 2 only
storage/federated/Makefile.am:
Changed header to GPL version 2 only
storage/innobase/handler/Makefile.am:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/AllocNodeId.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateFilegroup.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateFilegroupImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/CreateObj.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DictObjOp.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DihFragCount.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropFilegroup.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropFilegroupImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/DropObj.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/Extent.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/LgmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/PgmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RestoreContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RestoreImpl.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/RouteOrd.hpp:
Changed header to GPL version 2 only
storage/ndb/include/kernel/signaldata/TsmanContinueB.hpp:
Changed header to GPL version 2 only
storage/ndb/include/ndbapi/NdbIndexStat.hpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/mgmapi_logevent/mgmapi_logevent.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/mgmapi_logevent_dual/mgmapi_logevent_dual.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_async/ndbapi_async.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_async1/ndbapi_async1.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_event/ndbapi_event.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_retries/ndbapi_retries.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_scan/ndbapi_scan.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple/ndbapi_simple.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple_dual/ndbapi_simple_dual.cpp:
Changed header to GPL version 2 only
storage/ndb/ndbapi-examples/ndbapi_simple_index/ndbapi_simple_index.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbdih/printSysfile.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/DbtupVarAlloc.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/Undo_buffer.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/Undo_buffer.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/tuppage.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtup/tuppage.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/dbtux/DbtuxStat.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/diskpage.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/lgman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/lgman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/pgman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/pgman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/print_file.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/record_types.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/restore.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/restore.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/tsman.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/blocks/tsman.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DLCFifoList.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DLCHashTable.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DynArr256.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/DynArr256.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/KeyTable2Ref.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/LinearPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/NdbdSuperPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/NdbdSuperPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Pool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Pool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/RWPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/RWPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/Rope.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/SLFifoList.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/WOPool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/WOPool.hpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/bench_pool.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/ndbd_malloc_impl.cpp:
Changed header to GPL version 2 only
storage/ndb/src/kernel/vm/ndbd_malloc_impl.hpp:
Changed header to GPL version 2 only
storage/ndb/src/mgmsrv/ParamInfo.cpp:
Changed header to GPL version 2 only
storage/ndb/src/ndbapi/NdbIndexStat.cpp:
Changed header to GPL version 2 only
storage/ndb/test/ndbapi/testIndexStat.cpp:
Changed header to GPL version 2 only
storage/ndb/test/tools/listen.cpp:
Changed header to GPL version 2 only
storage/ndb/tools/restore/ndb_nodegroup_map.h:
Changed header to GPL version 2 only
strings/my_strchr.c:
Changed header to GPL version 2 only
unittest/mysys/base64-t.c:
Changed header to GPL version 2 only
unittest/mysys/bitmap-t.c:
Changed header to GPL version 2 only
unittest/mysys/my_atomic-t.c:
Changed header to GPL version 2 only
unittest/mytap/tap.c:
Changed header to GPL version 2 only
unittest/mytap/tap.h:
Changed header to GPL version 2 only
win/Makefile.am:
Changed header to GPL version 2 only
Partitioning now has a flag to allow disabling of engines from being compatible with partitioning. Cleaned up heap naming convention on panic call.
include/heap.h:
Added new function
sql/ha_ndbcluster.cc:
Updated hanlderton functions
sql/ha_ndbcluster_binlog.cc:
Updated handlerton functions.
sql/handler.cc:
Updated handlerton functions.
sql/handler.h:
Updated hanlderton functions
sql/log.cc:
Updated handlerton functions
sql/mysql_priv.h:
Updated handlerton functions
sql/mysqld.cc:
Added Legacy handlerton functions
sql/partition_info.cc:
Added flag support for marking engines not compatible with partitioning
sql/sql_cursor.cc:
Updated hanlderton functions
sql/sql_show.cc:
Updated hanlderton functions
sql/sql_tablespace.cc:
Update for handlerton functions
storage/archive/ha_archive.cc:
Update for hanlderton functions
storage/archive/ha_archive.h:
Update for handlerton functions
storage/blackhole/ha_blackhole.cc:
Update for handlerton functions
storage/csv/ha_tina.cc:
Update for handlerton functions
storage/csv/ha_tina.h:
Update for handlerton functions
storage/federated/ha_federated.cc:
Updated for handlerton functions
storage/federated/ha_federated.h:
Updated for handlerton functions
storage/heap/ha_heap.cc:
Update for handlerton functions
storage/heap/hp_panic.c:
Update of function name
storage/heap/hp_test1.c:
Update of function name
storage/heap/hp_test2.c:
Update of function name.
storage/innobase/handler/ha_innodb.cc:
Update of function name
storage/innobase/handler/ha_innodb.h:
Update of function name
storage/myisam/ha_myisam.cc:
Update of function name.
storage/myisammrg/ha_myisammrg.cc:
Update of function name
"Change in behavior --default-storage-engine=ndb or ndbcluster"
Reduce use of legacy_db_type, some code cleanup
(serg read my mind and implemented desired mysqld.cc changes)
sql/handler.cc:
Bug#20168
remove some use of legacy_db_type
cleanup code, new func for default type
sql/handler.h:
Bug#20168
remove some use of legacy_db_type
cleanup code, new func for default type
sql/sql_plugin.cc:
compiler hints, consts
sql/sql_plugin.h:
compiler hints, consts
sql/sql_tablespace.cc:
use ha_default_handlerton instead of resolving DB_TYPE_DEFAULT
- changed alter tablespace truct to work with handlerton pointer (to avoid crash in parser on unknown db type"
- pushed warnings when default storage engine is used and/or tablespace stuff is not supported by storage engine
mysql-test/r/ndb_dd_basic.result:
bug#18604 create logfile for MyISAM tables
mysql-test/t/ndb_dd_basic.test:
bug#18604 create logfile for MyISAM tables
bug: check if storage engine is enabled to avoif code dump
BitKeeper/etc/ignore:
Added storage/ndb/test/ndbapi/DbAsyncGenerator storage/ndb/test/ndbapi/DbCreate storage/ndb/test/ndbapi/ndbapi_slow_select storage/ndb/test/ndbapi/testBitfield storage/ndb/test/ndbapi/testLcp storage/ndb/test/ndbapi/testPartitioning storage/ndb/test/ndbapi/testReadPerf storage/ndb/test/ndbapi/test_event_merge storage/ndb/test/tools/listen_event to the ignore list