summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2022-09-30 08:25:00 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2022-09-30 08:25:00 +0300
commite29fb956145cfa1f4f8c41cafcddea36a20b23aa (patch)
tree16dbe904f2222e7654bb8f01decd06416fa9d3e2 /storage
parent6b685ea7b0776430d45b095cb4be3ef0739a3c04 (diff)
downloadmariadb-git-e29fb956145cfa1f4f8c41cafcddea36a20b23aa.tar.gz
Cleanup: Remove innobase_destroy_background_thd()
We do not need a non-inline wrapper for the function destroy_background_thd().
Diffstat (limited to 'storage')
-rw-r--r--storage/innobase/fts/fts0opt.cc2
-rw-r--r--storage/innobase/handler/ha_innodb.cc11
-rw-r--r--storage/innobase/include/ha_prototypes.h7
-rw-r--r--storage/innobase/srv/srv0srv.cc2
4 files changed, 5 insertions, 17 deletions
diff --git a/storage/innobase/fts/fts0opt.cc b/storage/innobase/fts/fts0opt.cc
index 348566ae952..9e3b4b3121d 100644
--- a/storage/innobase/fts/fts0opt.cc
+++ b/storage/innobase/fts/fts0opt.cc
@@ -2965,7 +2965,7 @@ retry_later:
ib_wqueue_free(fts_optimize_wq);
fts_optimize_wq = NULL;
- innobase_destroy_background_thd(fts_opt_thd);
+ destroy_background_thd(fts_opt_thd);
ib::info() << "FTS optimize thread exiting.";
os_event_set(fts_opt_shutdown_event);
diff --git a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc
index a3184abd2d3..e18d0d5968c 100644
--- a/storage/innobase/handler/ha_innodb.cc
+++ b/storage/innobase/handler/ha_innodb.cc
@@ -127,7 +127,6 @@ void thd_clear_error(MYSQL_THD thd);
TABLE *find_fk_open_table(THD *thd, const char *db, size_t db_len,
const char *table, size_t table_len);
MYSQL_THD create_background_thd();
-void destroy_background_thd(MYSQL_THD thd);
void reset_thd(MYSQL_THD thd);
TABLE *get_purge_table(THD *thd);
TABLE *open_purge_table(THD *thd, const char *db, size_t dblen,
@@ -1477,16 +1476,6 @@ innobase_create_background_thd(const char* name)
}
-/** Destroy a background purge thread THD.
-@param[in] thd MYSQL_THD to destroy */
-void
-innobase_destroy_background_thd(
-/*============================*/
- MYSQL_THD thd)
-{
- destroy_background_thd(thd);
-}
-
/** Close opened tables, free memory, delete items for a MYSQL_THD.
@param[in] thd MYSQL_THD to reset */
void
diff --git a/storage/innobase/include/ha_prototypes.h b/storage/innobase/include/ha_prototypes.h
index c1c41a8f77c..04e1ec96b73 100644
--- a/storage/innobase/include/ha_prototypes.h
+++ b/storage/innobase/include/ha_prototypes.h
@@ -1,7 +1,7 @@
/*****************************************************************************
Copyright (c) 2006, 2016, Oracle and/or its affiliates. All Rights Reserved.
-Copyright (c) 2017, 2021, MariaDB Corporation.
+Copyright (c) 2017, 2022, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
@@ -512,10 +512,9 @@ innodb_set_buf_pool_size(ulonglong buf_pool_size);
MYSQL_THD
innobase_create_background_thd(const char* name);
-/** Destroy a background purge thread THD.
+/** Destroy a THD object associated with a background task.
@param[in] thd MYSQL_THD to destroy */
-void
-innobase_destroy_background_thd(MYSQL_THD);
+void destroy_background_thd(MYSQL_THD thd);
/** Close opened tables, free memory, delete items for a MYSQL_THD.
@param[in] thd MYSQL_THD to reset */
diff --git a/storage/innobase/srv/srv0srv.cc b/storage/innobase/srv/srv0srv.cc
index a33d34c5654..f8e02f95c5e 100644
--- a/storage/innobase/srv/srv0srv.cc
+++ b/storage/innobase/srv/srv0srv.cc
@@ -2003,7 +2003,7 @@ static void srv_shutdown_purge_tasks()
std::unique_lock<std::mutex> lk(purge_thd_mutex);
while (!purge_thds.empty())
{
- innobase_destroy_background_thd(purge_thds.front());
+ destroy_background_thd(purge_thds.front());
purge_thds.pop_front();
}
n_purge_thds= 0;