summaryrefslogtreecommitdiff
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* SHOW and FLUSH for I_S tables.Sergei Golubchik2014-10-111-5/+1
| | | | | | | | | | Extend existing plugins to support * SHOW QUERY_RESPONSE_TIME * FLUSH QUERY_RESPONSE_TIME * SHOW LOCALE move userstat tables to use the new API instead of hand-coded syntax
* cleanup: move safe_str*() from sql_acl.cc to m_string.hSergei Golubchik2014-10-102-3/+15
|
* Plugin API: increase SHOW_VAR_FUNC_BUFF_SIZE for 64-bit CPUsSergei Golubchik2014-10-101-2/+2
| | | | | | instead of having it 1K everywhere, make it 1K on 32-bit and 2K on 64-bit. As the latter has larger pointers (and larger sizeof(SHOW_VAR), it needs a larger buffer to store the same amount of SHOW_VARs
* cleanup: simplify the usage of WSREP_FORMAT macroSergei Golubchik2014-10-101-9/+0
|
* followup changes to timeout commitSergei Golubchik2014-10-101-4/+4
| | | | | | | | * fix debian patch * update the copyright * rename include guards to follow conventions * restore incorectly deleted test file, add clarification in a comment * capitalize the first letter of the status variable
* MDEV 4427: query timeoutsMonty2014-10-071-0/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added MAX_STATEMENT_TIME user variable to automaticly kill queries after a given time limit has expired. - Added timer functions based on pthread_cond_timedwait - Added kill_handlerton() to signal storage engines about kill/timeout - Added support for GRANT ... MAX_STATEMENT_TIME=# - Copy max_statement_time to current user, if stored in mysql.user - Added status variable max_statement_time_exceeded - Added KILL_TIMEOUT - Removed digest hash from performance schema tests as they change all the time. - Updated test results that changed because of the new user variables or new fields in mysql.user This functionallity is inspired by work done by Davi Arnaut at twitter. Test case is copied from Davi's work. Documentation can be found at https://kb.askmonty.org/en/how-to-limittimeout-queries/ mysql-test/r/mysqld--help.result: Updated for new help message mysql-test/suite/perfschema/r/all_instances.result: Added new mutex mysql-test/suite/sys_vars/r/max_statement_time_basic.result: Added testing of max_statement_time mysql-test/suite/sys_vars/t/max_statement_time_basic.test: Added testing of max_statement_time mysql-test/t/max_statement_time.test: Added testing of max_statement_time mysys/CMakeLists.txt: Added thr_timer mysys/my_init.c: mysys/mysys_priv.h: Added new mutex and condition variables Added new mutex and condition variables mysys/thr_timer.c: Added timer functions based on pthread_cond_timedwait() This can be compiled with HAVE_TIMER_CREATE to benchmark agains timer_create()/timer_settime() sql/lex.h: Added MAX_STATEMENT_TIME sql/log_event.cc: Safety fix (timeout should be threated as an interrupted query) sql/mysqld.cc: Added support for timers Added status variable max_statement_time_exceeded sql/share/errmsg-utf8.txt: Added ER_QUERY_TIMEOUT sql/signal_handler.cc: Added support for KILL_TIMEOUT sql/sql_acl.cc: Added support for GRANT ... MAX_STATEMENT_TIME=# Copy max_statement_time to current user sql/sql_class.cc: Added timer functionality to THD. Added thd_kill_timeout() sql/sql_class.h: Added timer functionality to THD. Added KILL_TIMEOUT Added max_statement_time variable in similar manner as long_query_time was done. sql/sql_connect.cc: Added handling of max_statement_time_exceeded sql/sql_parse.cc: Added starting and stopping timers for queries. sql/sql_show.cc: Added max_statement_time_exceeded for user/connects status in MariaDB 10.0 sql/sql_yacc.yy: Added support for GRANT ... MAX_STATEMENT_TIME=# syntax, to be enabled in 10.0 sql/structs.h: Added max_statement_time user resource sql/sys_vars.cc: Added max_statement_time variables mysql-test/suite/roles/create_and_drop_role_invalid_user_table.test Removed test as we require all fields in mysql.user table. scripts/mysql_system_tables.sql scripts/mysql_system_tables_data.sql scripts/mysql_system_tables_fix.sql Updated mysql.user with new max_statement_time field
* fixing embedded: WaaS. Wsrep as a Service.Sergei Golubchik2014-10-013-0/+207
|
* use MD5 service in innodb/xtradbSergei Golubchik2014-10-011-1/+1
|
* MD5 serviceSergei Golubchik2014-10-018-2/+118
|
* extend SHA1 service. cleanup of sha1 wrappersSergei Golubchik2014-10-015-2/+38
|
* cleanup: galera merge, simple changesSergei Golubchik2014-10-011-1/+3
|
* compiler warningsSergei Golubchik2014-10-011-1/+1
|
* MDEV-6247: Merge 10.0-galera to 10.1.Jan Lindström2014-08-274-2/+74
|\ | | | | | | | | | | | | | | | | Merged lp:maria/maria-10.0-galera up to revision 3880. Added a new functions to handler API to forcefully abort_transaction, producing fake_trx_id, get_checkpoint and set_checkpoint for XA. These were added for future possiblity to add more storage engines that could use galera replication.
| * MDEV-6247: Merge 10.0-galera to 10.1.Jan Lindström2014-08-264-2/+74
| | | | | | | | | | | | | | | | | | Merged lp:maria/maria-10.0-galera up to revision 3879. Added a new functions to handler API to forcefully abort_transaction, producing fake_trx_id, get_checkpoint and set_checkpoint for XA. These were added for future possiblity to add more storage engines that could use galera replication.
* | MDEV-6305 - UNINIT_VAR emits code in non-debug buildsSergey Vojtovich2014-08-261-7/+5
|/ | | | | Reverted workaround for gcc bug, which was fixed 3 years ago: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34772
* remove a couple of old unused #definesSergei Golubchik2014-07-041-9/+0
|
* 5.5.38 mergeSergei Golubchik2014-06-062-3/+5
|\
| * Merge 5.3->5.5Alexander Barkov2014-06-042-1/+9
| |\
| | * MDEV-4858 Wrong results for a huge unsigned value inserted into a TIME columnAlexander Barkov2014-06-042-1/+9
| | | | | | | | | | | | | | | | | | | | | MDEV-6099 Bad results for DATE_ADD(.., INTERVAL 2000000000000000000.0 SECOND) MDEV-6097 Inconsistent results for CAST(int,decimal,double AS DATETIME) MDEV-6100 No warning on CAST(9000000 AS TIME)
| | * 5.2 mergeSergei Golubchik2014-03-1642-69/+69
| | |\
| | | * 5.1 mergeSergei Golubchik2014-03-1643-71/+71
| | | |\
| | | | * mysql-5.1.73 mergeSergei Golubchik2014-03-1543-71/+71
| | | | |\
| | | | | * Bug 16395495 - OLD FSF ADDRESS IN GPL HEADERMurthy Narkedimilli2013-03-1933-33/+33
| | | | | |
| * | | | | mysql-5.5.38 mergeSergei Golubchik2014-06-031-2/+4
| |\ \ \ \ \
| | * | | | | BUG#18080920: CRASH; MY_REALLOC_STR DEREFERENCES NEGATIVE VALUE Nisha Gopalakrishnan2014-04-241-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | INTO CLIENT_ERRORS ARRAY Analysis: -------- The client may crash while executing a statement due to the missing mapping of the server error to it's equivalent client error. When trying to reallocate memory for the packet buffer, if the system is out of memory or the packet buffer is large, the server errors 'ER_OUT_OF_RESOURCES' or 'ER_PACKET_TOO_LARGE' is returned respectively. The client error number calculated is negative and when trying to dereference the array of client error messages with the calculated error number, the client crashes. Fix: ---- Map the server error returned to it's equivalent client error prior to dereferencing the array of client error messages. Note: Test case is not added since it is difficult to simulate the error condition.
* | | | | | | MDEV-6153 Trivial Lintian errors in MariaDB sources: spelling errors and ↵Sergei Golubchik2014-05-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | wrong executable bits
* | | | | | | 5.5 mergeSergei Golubchik2014-05-092-3/+5
|\ \ \ \ \ \ \ | |/ / / / / /
| * | | | | | mysql-5.5.37 selective mergeSergei Golubchik2014-03-272-3/+5
| |\ \ \ \ \ \ | | |/ / / / /
| | * | | | | Updated/added copyright header. Added line "use is subject to license terms" Murthy Narkedimilli2014-02-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to copyright header.
| | * | | | | Fixing the bug 18184414: WRONG COPYRIGHT TO FILE INCLUDE/MYSQL_VERSION.H.INMurthy Narkedimilli2014-02-061-3/+4
| | | | | | |
| | * | | | | Bug #17760379 COLLATIONS WITH CONTRACTIONS BUFFER-OVERFLOW THEMSELVES IN THE ↵Venkata Sidagam2014-01-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FOOT Description: A typo in create_tailoring() causes the "contraction_flags" to be written into cs->contractions in the wrong place. This causes two problems: (1) Anyone relying on `contraction_flags` to decide "could this character be part of a contraction" is 100% broken. (2) Anyone relying on `contractions` to determine the weight of a contraction is mostly broken Analysis: When we are preparing the contraction in create_tailoring(), we are corrupting the cs->contractions memory location which is supposed to store the weights(8k) + contraction information(256 bytes). We started storing the contraction information after the 4k location. This is because of logic flaw in the code. Fix: When we create the contractions, we need to calculate the contraction with (char*) (cs->contractions + 0x40*0x40) from ((char*) cs->contractions) + 0x40*0x40. This makes the "cs->contractions" to move to 8k bytes and stores the contraction information from there. Similarly when we are calculating it for like range queries we need to calculate it from the 8k bytes onwards, this can be done by changing the logic to (const char*) (cs->contractions + 0x40*0x40). And for ucs2 charsets we need to modify the my_cs_can_be_contraction_head() and my_cs_can_be_contraction_tail() to point to 8k+ locations.
| | * | | | | updating the current copyright year which reflects in the MySQL welcome message.Murthy Narkedimilli2014-01-091-2/+2
| | | | | | |
* | | | | | | merge of "BUG#18233051 - FTS: FAILING ASSERTION: NUM_TOKEN < MAX_PROXIMITY_ITEM"Sergei Golubchik2014-05-072-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | revno: 5826 committer: Shaohua Wang <shaohua.wang@oracle.com> branch nick: mysql-5.6-bugfix2 timestamp: Wed 2014-02-19 16:41:14 +0800 message: BUG#18233051 - FTS: FAILING ASSERTION: NUM_TOKEN < MAX_PROXIMITY_ITEM
* | | | | | | perfschema 5.6.17Sergei Golubchik2014-05-075-6/+6
|\ \ \ \ \ \ \
| * | | | | | | 5.6.17Sergei Golubchik2014-05-076-8/+8
| | | | | | | |
* | | | | | | | null-merge from perfschema-5.6 merge treeSergei Golubchik2014-05-072-11/+0
|\ \ \ \ \ \ \ \ | |/ / / / / / / | | | | | | | | | | | | | | | | (only new files and small style changes are accepted)
| * | | | | | | perfschema 5.6.10 initial commit.Sergei Golubchik2014-05-0714-0/+7835
| / / / / / / | | | | | | | | | | | | | | | | | | | | | include/mysql/psi/*
* | | | | | | Revert revision sergii@pisem.net-20130123151853-xc6i3l11aqv0iykkSergei Golubchik2014-03-261-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rename back my_init_dynamic_array2() -> init_dynamic_array2() It happens to be a part of the de facto API :(
* | | | | | | 5.5 mergeSergei Golubchik2014-03-261-8/+8
|\ \ \ \ \ \ \ | |/ / / / / /
| * | | | | | MDEV-5905: Creating tmp. memory table kills the serverMichael Widenius2014-03-261-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The reason was that a couple of variables that hold number of rows that was used to calculate buffers was uint and caused an overflow. Fixed by changing variables that could hold number of rows from uint to ulong and also added a cast for this test. include/heap.h: Reorder to get better alignment. Changed variables that could hold number of rows from uint to ulong mysql-test/suite/heap/heap.result: Added test case mysql-test/suite/heap/heap.test: Added test case mysql-test/suite/plugins/t/server_audit.test: Added sleep as we want to have disconnect logged before we try a new connect storage/heap/ha_heap.cc: Changed variables that could hold number of rows from uint to ulong Limit number of rows to 4G (as most of the variables that holds rows are ulong anyway) reset records_changed when key_stat_version is changed to not cause increments for every row changed storage/heap/ha_heap.h: changed records_changed to ulong as this can get big storage/heap/hp_create.c: Changed variables that could hold number of rows from uint to ulong Added cast (fixed the original bug) storage/heap/hp_delete.c: Changed variables that could hold number of rows from uint to ulong storage/heap/hp_open.c: Removed not needed cast storage/heap/hp_write.c: Changed variables that could hold number of rows from uint to ulong support-files/compiler_warnings.supp: Removed extra : from supression
| * | | | | | MDEV-5822 TokuDB fails to compile without partition storage engineSergei Golubchik2014-03-241-0/+6
| | | | | | |
* | | | | | | MDEV-5404 Can't free data returned by mariadb_dyncol_unpack on windowsSergei Golubchik2014-03-191-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | add mariadb_dyncol_unpack_free()
* | | | | | | MDEV-5914: Parallel replication deadlock due to InnoDB lock conflictsunknown2014-03-214-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to how gap locks work, two transactions could group commit together on the master, but get lock conflicts and then deadlock due to different thread scheduling order on slave. For now, remove these deadlocks by running the parallel slave in READ COMMITTED mode. And let InnoDB/XtraDB allow statement-based binlogging for the parallel slave in READ COMMITTED. We are also investigating a different solution long-term, which is based on relaxing the gap locks only between the transactions running in parallel for one slave, but not against possibly external transactions.
* | | | | | | Merge with 10.0-baseMichael Widenius2014-03-131-0/+10
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Automatic merge, except for server_audit.cc that had to be modified slightly Changes to xtradb and innobase where ignored was these made no sence for 10.0
* | | | | | | | Fixed some failing testsMichael Widenius2014-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove memory warnings if mysql client aborts early Changed copyright for clients client/mysql.cc: Free memory if get_options fails, so that we don't get warnings from safemalloc include/welcome_copyright_notice.h: Added SkySQL to client copyrights mysql-test/valgrind.supp: Added suppressions for memory leaks from dlopen() for OpenSUSE 12.3 storage/oqgraph/mysql-test/oqgraph/regression_mdev5744.result: Suppress warning storage/oqgraph/mysql-test/oqgraph/regression_mdev5744.test: Suppress warning
* | | | | | | | MDEV-5766 - my_atomic_load does memory writesSergey Vojtovich2014-03-071-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | my_atomic_load() is implemented as __sync_fetch_and_or(var, 0) which writes or-ed value back to var. Memory writes as such have worse performance and scalability than reads. gcc 4.7 and up offers better facility for atomic loads/stores. Use it whenever it is available.
* | | | | | | | Fixed MDEV-5780 "create-big fails in 10.0"Michael Widenius2014-03-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The issue was that create...trigger part of the test suite used a debug_sync point that before was never triggered (in other words, wrong meaningless test). With the new create ... replace code the debug sync point is triggered and the test case could not handled that. I fixed this by adding a wait and go for the debug syncpoint in the test. Removed some compiler warnings from mysql_cond_timedwait include/mysql/psi/mysql_thread.h: Removed compiler warnings mysql-test/r/create-big.result: New test result mysql-test/t/create-big.test: Fixed test case as create_table_select_before_check_if_exists was not before triggered by the code.
* | | | | | | | MDEV-5372 Make "CAST(time_expr AS DATETIME)" compatible with MySQL-5.6 (and ↵Alexander Barkov2014-03-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the SQL Standard)
* | | | | | | | MDEV-5675 - Performance: my_hash_sort_bin is called too oftenSergey Vojtovich2014-03-061-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduced number of my_hash_sort_bin() calls from 4 to 1 per query. Reduced number of memory accesses done by my_hash_sort_bin(). Details: - let MDL subsystem use pre-calculated hash value for hash inserts and deletes - let table cache use pre-calculated MDL hash value - MDL namespace is excluded from hash value calculation, so that hash value can be used by table cache as is - hash value for MDL is calculated as resulting hash value + MDL namespace - extended hash implementation to accept user defined hash function
* | | | | | | | mergeSergei Golubchik2014-02-2810-28/+16
|\ \ \ \ \ \ \ \