summaryrefslogtreecommitdiff
path: root/sql/mysqld.h
diff options
context:
space:
mode:
authorSergey Vojtovich <svoj@mariadb.org>2019-05-18 23:01:44 +0400
committerSergey Vojtovich <svoj@mariadb.org>2019-05-21 17:55:09 +0400
commit34dfcbe3a64deddd633ff62b51b6f12ecebe42be (patch)
tree70675bbb0d6761eb89e1fef945ef0b7de51d2e34 /sql/mysqld.h
parentebc55c8577be7b8b8c3d9433feb4ce457f5b6cc5 (diff)
downloadmariadb-git-34dfcbe3a64deddd633ff62b51b6f12ecebe42be.tar.gz
Move thread re-initialisation out of cache_thread
It mostly duplicates code of do_handle_one_connection(). Move it there, so that it is easier to simplify it in future. Moved PSI_CALL_delete_current_thread()/_db_pop_() out of mutex. Call them consistently in all cases, unlike before: - called for reused threads - called for flushed threads - called for threads that go down after 5 minutes timeout - not called for threads attempting to cache themselves during flush - not called for threads attempting to cache themselves when cache is full Part of MDEV-19515 - Improve connect speed
Diffstat (limited to 'sql/mysqld.h')
-rw-r--r--sql/mysqld.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/mysqld.h b/sql/mysqld.h
index ceef0dd7b3a..e106ee5bc9a 100644
--- a/sql/mysqld.h
+++ b/sql/mysqld.h
@@ -79,7 +79,7 @@ void close_connection(THD *thd, uint sql_errno= 0);
void handle_connection_in_main_thread(CONNECT *thd);
void create_thread_to_handle_connection(CONNECT *connect);
void unlink_thd(THD *thd);
-bool cache_thread(THD *thd);
+CONNECT *cache_thread(THD *thd);
void flush_thread_cache();
void refresh_status(THD *thd);
bool is_secure_file_path(char *path);