1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-34860 Implement MAX_EXECUTION_TIME hint

It places a limit N (a timeout value in milliseconds) on how long
a statement is permitted to execute before the server terminates it.

Syntax:
SELECT /*+ MAX_EXECUTION_TIME(milliseconds) */ ...

Only top-level SELECT statements support the hint.
This commit is contained in:
Oleg Smirnov
2024-08-07 22:10:50 +07:00
parent 1e2774d829
commit 67319f3e8d
20 changed files with 573 additions and 51 deletions

View File

@@ -228,7 +228,7 @@ Item ** find_item_in_list(Item *item, List<Item> &items, uint *counter,
bool setup_tables(THD *thd, Name_resolution_context *context,
List<TABLE_LIST> *from_clause, TABLE_LIST *tables,
List<TABLE_LIST> &leaves, bool select_insert,
bool full_table_list);
bool full_table_list, bool resolve_opt_hints);
bool setup_tables_and_check_access(THD *thd,
Name_resolution_context *context,
List<TABLE_LIST> *from_clause,
@@ -237,7 +237,8 @@ bool setup_tables_and_check_access(THD *thd,
bool select_insert,
privilege_t want_access_first,
privilege_t want_access,
bool full_table_list);
bool full_table_list,
bool resolve_opt_hints);
bool wait_while_table_is_used(THD *thd, TABLE *table,
enum ha_extra_function function);