Commit graph

37 commits

Author SHA1 Message Date
Oleksandr Byelkin
e3982cead2 MDEV-6066: Merge new defaults from 5.6 and 5.7 (defaults changed, QC can be stopped with no-zero size) 2015-09-04 10:33:56 +02:00
Sergey Vojtovich
4188ba9c1e MDEV-7652 - More explanatory ERROR and WARNING messages when loading plugins
with plugin-load-add that are already registered at mysql.plugin

- issue just one error message, without this extra warning
- don't abuse ER_UDF_EXISTS, instead add a proper error message for plugins
- report started initialization for each plugin source
2015-07-29 13:51:22 +04:00
Sergei Golubchik
a6087e7dc1 MDEV-5309 - RENAME TABLE does not check for existence of the table's engine
fix the test case for ps-protocol
2015-06-17 16:13:02 +02:00
Sergey Vojtovich
909f760701 MDEV-5309 - RENAME TABLE does not check for existence of the table's engine
When RENAME TABLE is executed, it apparently does not check whether the engine
is available (unlike ALTER TABLE .. RENAME, which does). It means that if the
engine in question was not loaded on some reason, the table might become
unusable, since the engine won't know about the change.

With this patch RENAME TABLE fails if storage engine is not available.
2015-06-16 12:12:17 +04:00
Sergei Golubchik
d3e2e1243b 5.5 merge 2014-05-09 12:35:11 +02:00
Sergei Golubchik
eb9f422c43 MDEV-5667 online alter and changed field/index options
use the Alter_inplace_info::ALTER_COLUMN_OPTION flag if
field/column flags were altered.

change ha_example to use check_if_supported_inplace_alter() instead
of obsolete check_if_incompatible_data()
2014-03-02 15:02:13 +01:00
Sergei Golubchik
32b3c9f35d Make THDVAR_INT variables to be signed in SELECT in SHOW 2014-04-09 14:28:07 +02:00
Sergei Golubchik
9af177042e 10.0-base merge.
Partitioning/InnoDB changes are *not* merged (they'll come from 5.6)
TokuDB does not compile (not updated to 10.0 SE API)
2013-09-21 10:14:42 +02:00
Sergei Golubchik
4ec2e9d7ed 5.5 merge and fixes for compiler/test errors 2013-09-18 13:07:31 +02:00
Sergei Golubchik
b838d081ad mysql-5.5.33 merge 2013-09-06 22:31:30 +02:00
Sergei Golubchik
13dca0125a more post-merge fixes:
* update results
* don't force HA_CREATE_DELAY_KEY_WRITE on all temp tables,
  (bad for CREATE ... LIKE) instead imply it in myisam/aria
* restore HA_ERR_TABLE_DEF_CHANGED in archive
* increase the default number of rwlock classes in P_S to fit all our rwlocks
2013-07-21 19:24:20 +02:00
Sergei Golubchik
97e640b9ae 5.5 merge 2013-07-17 21:24:29 +02:00
Sergei Golubchik
1fb33e4a67 MDEV-4529 Assertion `tmp->state == 4' fails on mix of INSTALL SONAME / UNINSTALL PLUGIN
fix incorrect assert
2013-06-13 20:19:11 +02:00
Sergei Golubchik
acad1cc03c MDEV-4573 UNINSTALL PLUGIN misleading error message for non-dynamic plugins
change WARN_PLUGIN_DELETE_BUILTIN to ER_PLUGIN_DELETE_BUILTIN
2013-06-13 14:14:47 +02:00
Ashish Agarwal
0c4f4ff015 Bug#16194302: SUPPORT FOR FLOATING-POINT SYSTEM VARIABLES
USING THE PLUGIN INTERFACE.

ISSUE: No support for floating-point plugin
       system variables.

SOLUTION: Allowing plugins to define and expose floating-point
          system variables of type double. MYSQL_SYSVAR_DOUBLE
          and MYSQL_THDVAR_DOUBLE are added.

ISSUE: Fractional part of the def, min, max values of system
       variables are ignored.

SOLUTION: Adding functions that are used to store the raw
          representation of a double in the raw bits of unsigned
          longlong in a way that the binary representation
          remains the same.
2013-05-19 23:38:06 +05:30
Sergei Golubchik
5f293dd694 MDEV-4022 table attributes with sysvar as a default value 2013-04-09 23:27:24 +02:00
Sergei Golubchik
a489ae89b9 fix mysql_rm_table_no_locks() not to use dd_frm_type, because the frm file
may not exist (the table exists only in the engine).
2013-04-09 15:47:25 +02:00
Sergei Golubchik
c9ff25f568 MDEV-3985 crash: uninstall soname 'a' 2013-01-09 17:29:51 +01:00
Sergei Golubchik
1c530b36d1 mdev-20: INSTALL PLUGIN SONAME 2012-03-05 21:48:06 +01:00
Sergei Golubchik
76f0b94bb0 merge with 5.3
sql/sql_insert.cc:
  CREATE ... IF NOT EXISTS may do nothing, but
  it is still not a failure. don't forget to my_ok it.
  ******
  CREATE ... IF NOT EXISTS may do nothing, but
  it is still not a failure. don't forget to my_ok it.
sql/sql_table.cc:
  small cleanup
  ******
  small cleanup
2011-10-19 21:45:18 +02:00
Bjorn Munch
83fea27b61 Bug #58841 Generalise handling of plugins in MTR mysql-test-run.pl script
Put descriptions of plugins into a separate file read by MTR
MTR itself has generalised code to read this and set env. variables
Removed the *SO variables, updated some tests accordingly
New commit: added optional list of plugin names for _LOAD variable
Also made changes for the new AUTH_* plugins
2011-01-11 14:27:03 +01:00
Sergei Golubchik
62d31f675d bugfix: engine defined table options were not showing up in INFORMATION_SCHEMA.TABLES.CREATE_OPTIONS 2010-10-24 20:47:01 +02:00
Sergei Golubchik
2f8ca649d2 merge 2010-06-14 18:58:52 +02:00
Sergei Golubchik
e96885de92 fixed for mysql-test-run to
* fully support --mysqld=--plugin-load=xxxx
* uniformly support all loadable plugins, no need to hard-code
  every new plugin in mtr
* autodetect MTR_VS_CONFIG on windows
2010-06-10 11:11:52 +02:00
Sergei Golubchik
a3e8ae1280 A temporary solution to make CREATE TABLE attributes
to work when a table is partitioned
2010-05-11 16:49:23 +02:00
Sergei Golubchik
2b8de050bf create table options bug:
alter table does not reset HA_OPTION_TEXT_CREATE_OPTIONS when the last option value is removed
2010-04-30 22:04:35 +02:00
Sergei Golubchik
b58cb7c4a2 small changes to WL#43:
consistency: don't use "index" and "key" interchangeably
  => rename "key" to "index"
  consistency: all option types are logical, besides ULL
  => rename ULL to NUMBER
  don't accept floats where integers are expected
  accept hexadecimal where integers are expected
2010-04-30 12:12:25 +02:00
Sergei Golubchik
cda2c0ced4 fixes for buildbot:
update test results
fix compilation failure on windows
fix for ps-protocol

mysql-test/r/plugin.result:
  make sure the PS handle is closed
mysql-test/t/plugin.test:
  make sure the PS handle is closed
sql/mysqld.cc:
  compilation failure: lable without a statement.
sql/sql_plugin.cc:
  make plugin lock and plugin unlock use the same format of the dbug info string.
  print the ref_count *after* the lock and *after* the unlock.
2010-04-08 19:19:01 +02:00
Sergei Golubchik
e24e1668bc MWL#43 CREATE TABLE options (by Sanja)
Docs/sp-imp-spec.txt:
  New sql_mode added.
include/my_base.h:
  Flag in frm of create options.
libmysqld/CMakeLists.txt:
  New files added.
libmysqld/Makefile.am:
  New files added.
mysql-test/r/events_bugs.result:
  New sql_mode added.
mysql-test/r/information_schema.result:
  New sql_mode added.
mysql-test/r/sp.result:
  New sql_mode added.
mysql-test/r/system_mysql_db.result:
  New sql_mode added.
mysql-test/suite/funcs_1/r/is_columns_mysql.result:
  New sql_mode added.
mysql-test/suite/funcs_1/r/is_columns_mysql_embedded.result:
  New sql_mode added.
mysql-test/t/events_bugs.test:
  New sql_mode added.
mysql-test/t/sp.test:
  New sql_mode added.
scripts/mysql_system_tables.sql:
  New sql_mode added.
scripts/mysql_system_tables_fix.sql:
  New sql_mode added.
sql/CMakeLists.txt:
  New files added.
sql/Makefile.am:
  New files added.
sql/event_db_repository.cc:
  New sql_mode added.
sql/field.cc:
  Create options support added.
sql/field.h:
  Create options support added.
sql/ha_partition.cc:
  Create options support added.
sql/handler.cc:
  Create options support added.
sql/handler.h:
  Create options support added.
sql/log_event.h:
  New sql_mode added.
sql/mysql_priv.h:
  New sql_mode added.
sql/mysqld.cc:
  New sql_mode added.
sql/share/errmsg.txt:
  New error messages added.
sql/sp.cc:
  New sql_mode added.
sql/sp_head.cc:
  Create options support added.
sql/sql_class.cc:
  Create options support added.
  Debug added.
sql/sql_class.h:
  Create options support added.
sql/sql_insert.cc:
  my_safe_a* moved to mysqld_priv.h
sql/sql_lex.h:
  Create options support added.
sql/sql_parse.cc:
  Create options support added.
sql/sql_show.cc:
  Create options support added.
sql/sql_table.cc:
  Create options support added.
sql/sql_view.cc:
  New sql_mode added.
sql/sql_yacc.yy:
  Create options support added.
sql/structs.h:
  Create options support added.
sql/table.cc:
  Create options support added.
sql/table.h:
  Create options support added.
sql/unireg.cc:
  Create options support added.
storage/example/ha_example.cc:
  Create options example.
storage/example/ha_example.h:
  Create options example.
storage/pbxt/src/discover_xt.cc:
  Create options support added.
2010-04-08 14:10:05 +02:00
Sergei Golubchik
2ceaffc467 mwl:98 - libservices 2010-03-03 15:44:14 +01:00
Sergei Golubchik
3d23068f3a WL#4903 Plugin Service API part I
(mysql-next-mr backport)
2009-11-02 21:05:42 +01:00
Magnus Blåudd
fabde82dbd Bug#47801 The plugin test fails with the Embedded Server on Windows
- Remove the "hack" from mtr.pl that skipped searching for the .dll files
  when embedded and windows. Now the variables will be preoperly initialized.
 - Make the tests detect that they can't run on windows+embedded
2009-10-08 10:39:15 +02:00
Vladislav Vaintroub
768bbae90e Backport WL#3653 to 5.1 to enable bundled innodb plugin.
Remove custom DLL loader code from innodb plugin code, use 
symbols exported from mysqld.


storage/innodb_plugin/handler/ha_innodb.cc:
  Remove a Win32 workaround for current_thd.
  The original  problem that innodb plugin used
  value of TLS variable across DLL boundaries is 
  solved in MySQL server (current_thd is a function
  not TLS variable now)
storage/innodb_plugin/handler/handler0alter.cc:
  Remove custom delay loader
storage/innodb_plugin/handler/handler0vars.h:
  Remove custom delay loader
storage/innodb_plugin/handler/i_s.cc:
  Remove custom delay loader
storage/innodb_plugin/handler/win_delay_loader.cc:
  Remove custom delay loader
storage/innodb_plugin/plug.in:
  Remove commented out MYSQL_PLUGIN_STATIC, 
  CMake would not parse that correctly
2009-06-10 10:59:49 +02:00
unknown
9bd3b8545a Bug#32757: hang with sql_mode set when setting some global variables
If setting a system-variable provided by a plug-in failed, no OK or
error was sent in some cases, hanging the client. We now send an error
in the case from the ticket (integer-argument out of range in STRICT
mode). We also provide a semi-generic fallback message for possible
future cases like this where an error is signalled, but no message is
sent to the client. The error/warning handling is unified so it's the
same again for variables provided by plugins and those in the server
proper.


mysql-test/r/plugin.result:
  show that on out-of-range values, plugin interface throws errors
  in STRICT mode and warnings otherwise.
mysql-test/t/plugin.test:
  show that on out-of-range values, plugin interface throws errors
  in STRICT mode and warnings otherwise.
sql/set_var.cc:
  - handle signedness of values used in warnings
  - in STRICT mode, throw errors rather than warnings
sql/sql_parse.cc:
  If sql_set_variables() returns with an error but no message
  was sent to the client, send a semi-generic one so the session
  won't hang and we won't fail silently.
sql/sql_plugin.cc:
  throw a warning if more than just block-size was corrected
  (or an error in STRICT mode). use functions from set_var
  for uniform behaviour of server- and plug-in variables.
storage/example/ha_example.cc:
  Add a ULONG system variable to example plugin so
  we can test integers in the plugin-interface without
  having to depend on the presence of innobase.
2008-02-24 14:12:17 +01:00
unknown
69762c0581 Fixed bug #32034: On 64bit platforms assigning values of
storage engine system variables was not validated and
unexpected value was assigned.

The check_func_enum function used subtraction from the uint
value with the probably negative result. That result of
type uint was compared with 0 after casting to signed long
type. On architectures where long type is longer than int
type the result of comparison was unexpected.


storage/example/ha_example.cc:
  Fixed bug #32034.
  Sample system variable example_enum_var has been added to the
  EXAMPLE storage to test ENUM variables.
sql/sql_plugin.cc:
  Fixed bug #32034.
  The check_func_enum function used subtraction from the uint
  value with the probably negative result. That result of
  type uint was compared with 0 after casting to signed long
  type. On architectures where long type is longer than int
  type the result of comparison was unexpected.
  
  uint value has been casted to long type before subtraction.
mysql-test/t/plugin.test:
  Added test case for bug #32034.
mysql-test/r/plugin.result:
  Added test case for bug #32034.
2007-11-14 13:48:21 +04:00
unknown
c367385f7f BUG#25659 - memory leak via "plugins" test
- Added suppressions for dlopen to make plugin test pass.
- Do not pass empty string to mysqld, since my_getopt is
  not capable to handle it.
- Re-enabled trailing UNINSTALL PLUGIN statement of plugin.test.

The memory leak described in the bug report happens in libdl, not
in mysqld. On some valgrind installations this error is suppressed
by default, no idea why it isn't suppressed on pb-valgrind.

<observation>
If library remains open after thread has finished, and is closed by
another thread, we get memory leak. But in case library is opened and
closed by the same thread no leak occurs.
</observation>


mysql-test/lib/mtr_io.pl:
  Do not pass empty string since my_getopt is not capable to handle it.
  This is required to make plugin.test work on platforms where
  ha_example is not compiled.
mysql-test/r/plugin.result:
  Updated test result.
mysql-test/t/plugin.test:
  Re-enabled UNINSTALL PLUGIN statement. It is a good idea to cleanup
  at the end of the test. Anyway bug22694 was fixed while this test
  was disabled.
mysql-test/valgrind.supp:
  Added suppressions for dlopen to make plugin test pass.
2007-05-21 17:48:29 +05:00
unknown
eb3b8c3cb7 Add support for loading example plugin and add plugin.test
mysql-test/r/have_dynamic_loading.require:
  Rename: mysql-test/r/have_udf.require -> mysql-test/r/have_dynamic_loading.require
mysql-test/include/have_udf.inc:
  Rename have_udf.require to hqave_dynamic_loading.require
mysql-test/mysql-test-run.pl:
  Add support for ha_example plugin
mysql-test/include/have_example_plugin.inc:
  New BitKeeper file ``mysql-test/include/have_example_plugin.inc''
mysql-test/r/have_example_plugin.require:
  New BitKeeper file ``mysql-test/r/have_example_plugin.require''
mysql-test/r/plugin.result:
  New BitKeeper file ``mysql-test/r/plugin.result''
mysql-test/t/plugin.test:
  New BitKeeper file ``mysql-test/t/plugin.test''
2006-12-15 00:09:56 +01:00