summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2016-11-26 14:10:53 +0100
committerSergei Golubchik <serg@mariadb.org>2016-12-12 20:27:41 +0100
commitb66976abb4ce16db99361262e97ac0db60385e35 (patch)
treeea2fd8d194c8c9e75f02614476354cc924b41e1c
parenta6f05b9292516020f9bb31c46bec0ca1e11702be (diff)
downloadmariadb-git-b66976abb4ce16db99361262e97ac0db60385e35.tar.gz
cleanup: InnoDB, various minor issues
* fix "unused pending_checkpoint_mutex_key" compiler warning * clarify/simplify get_field_offset() * typos, comments * unused (forgotten) declaration of create_options_are_invalid() * fix my_error(ER_WRONG_KEY_COLUMN) calls * crash in row_upd_sec_index_entry() * double if (ret != 0) * don't duplucate PSI_INSTRUMENT_ME lines * useless break; after return(); * remove unused xtradb-only "cursor_read_view" stuff * code formatting * simplify dropped column detection * redundant assignment
-rw-r--r--mysql-test/suite/sys_vars/r/sysvars_innodb.result2
-rw-r--r--storage/innobase/handler/ha_innodb.cc154
-rw-r--r--storage/innobase/handler/ha_innodb.h16
-rw-r--r--storage/innobase/handler/handler0alter.cc40
-rw-r--r--storage/innobase/handler/i_s.cc6
-rw-r--r--storage/innobase/row/row0merge.cc5
-rw-r--r--storage/innobase/row/row0upd.cc3
-rw-r--r--storage/innobase/srv/srv0srv.cc4
8 files changed, 45 insertions, 185 deletions
diff --git a/mysql-test/suite/sys_vars/r/sysvars_innodb.result b/mysql-test/suite/sys_vars/r/sysvars_innodb.result
index c298c98ac99..51878fb1748 100644
--- a/mysql-test/suite/sys_vars/r/sysvars_innodb.result
+++ b/mysql-test/suite/sys_vars/r/sysvars_innodb.result
@@ -488,7 +488,7 @@ GLOBAL_VALUE_ORIGIN COMPILE-TIME
DEFAULT_VALUE crc32
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE ENUM
-VARIABLE_COMMENT The algorithm InnoDB uses for page checksumming. Possible values are CRC32 (hardware accelerated if the CPU supports it) write crc32, allow any of the other checksums to match when reading; STRICT_CRC32 write crc32, do not allow other algorithms to match when reading; INNODB write a software calculated checksum, allow any other checksums to match when reading; STRICT_INNODB write a software calculated checksum, do not allow other algorithms to match when reading; NONE write a constant magic number, do not do any checksum verification when reading (same as innodb_checksums=OFF); STRICT_NONE write a constant magic number, do not allow values other than that magic number when reading; Files updated when this option is set to crc32 or strict_crc32 will not be readable by InnoDB versions older than 5.6.3
+VARIABLE_COMMENT The algorithm InnoDB uses for page checksumming. Possible values are CRC32 (hardware accelerated if the CPU supports it) write crc32, allow any of the other checksums to match when reading; STRICT_CRC32 write crc32, do not allow other algorithms to match when reading; INNODB write a software calculated checksum, allow any other checksums to match when reading; STRICT_INNODB write a software calculated checksum, do not allow other algorithms to match when reading; NONE write a constant magic number, do not do any checksum verification when reading (same as innodb_checksums=OFF); STRICT_NONE write a constant magic number, do not allow values other than that magic number when reading; Files updated when this option is set to crc32 or strict_crc32 will not be readable by MariaDB versions older than 10.0.4
NUMERIC_MIN_VALUE NULL
NUMERIC_MAX_VALUE NULL
NUMERIC_BLOCK_SIZE NULL
diff --git a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc
index dab081c1028..598047e31d6 100644
--- a/storage/innobase/handler/ha_innodb.cc
+++ b/storage/innobase/handler/ha_innodb.cc
@@ -476,6 +476,7 @@ static mysql_pfs_key_t pending_checkpoint_mutex_key;
static PSI_mutex_info all_pthread_mutexes[] = {
PSI_KEY(commit_cond_mutex),
+ PSI_KEY(pending_checkpoint_mutex),
PSI_KEY(innobase_share_mutex)
};
@@ -871,13 +872,17 @@ innobase_map_isolation_level(
/** Gets field offset for a field in a table.
@param[in] table MySQL table object
-@param[in] field MySQL field object
+@param[in] field MySQL field object (from table->field array)
@return offset */
static inline
uint
get_field_offset(
const TABLE* table,
- const Field* field);
+ const Field* field)
+{
+ return field->offset(table->record[0]);
+}
+
/*************************************************************//**
Check for a valid value of innobase_compression_algorithm.
@@ -3980,12 +3985,6 @@ innobase_init(
innobase_hton->commit_by_xid = innobase_commit_by_xid;
innobase_hton->rollback_by_xid = innobase_rollback_by_xid;
innobase_hton->commit_checkpoint_request=innobase_checkpoint_request;
-
-#ifdef INNOBASE_CURSOR_VIEW
- innobase_hton->create_cursor_read_view = innobase_create_cursor_view;
- innobase_hton->set_cursor_read_view = innobase_set_cursor_view;
- innobase_hton->close_cursor_read_view = innobase_close_cursor_view;
-#endif
innobase_hton->create = innobase_create_handler;
#ifdef MYSQL_TABLESPACES
@@ -5686,7 +5685,7 @@ ha_innobase::table_flags() const
all InnoDB features such as GEOMETRY, FULLTEXT etc. */
/* JAN: TODO: MySQL 5.7
flags &= ~(HA_INNOPART_DISABLED_TABLE_FLAGS);
-
+ }
*/
}
@@ -6126,8 +6125,6 @@ innobase_match_index_columns(
if (innodb_idx_fld >= innodb_idx_fld_end) {
DBUG_RETURN(FALSE);
}
-
- mtype = innodb_idx_fld->col->mtype;
}
/* MariaDB-5.5 compatibility */
@@ -7311,19 +7308,6 @@ ha_innobase::close()
/* The following accessor functions should really be inside MySQL code! */
-/** Gets field offset for a field in a table.
-@param[in] table MySQL table object
-@param[in] field MySQL field object
-@return offset */
-static inline
-uint
-get_field_offset(
- const TABLE* table,
- const Field* field)
-{
- return(static_cast<uint>((field->ptr - table->record[0])));
-}
-
#ifdef WITH_WSREP
UNIV_INTERN
int
@@ -9649,7 +9633,7 @@ wsrep_calc_row_hash(
}
#endif /* WITH_WSREP */
-/*
+/**
Updates a row given as a parameter to a new value. Note that we are given
whole rows, not just the fields which are updated: this incurs some
overhead for CPU when we check which fields are actually updated.
@@ -9694,10 +9678,9 @@ ha_innobase::update_row(
+ MAX_REF_PARTS * 3;
m_upd_buf = reinterpret_cast<uchar*>(
- my_malloc(
- m_upd_buf_size,
+ my_malloc(//PSI_INSTRUMENT_ME,
+ m_upd_buf_size,
MYF(MY_WME)));
- /* JAN: TODO: MySQL 5.7: PSI_INSTRUMENT_ME,...*/
if (m_upd_buf == NULL) {
m_upd_buf_size = 0;
@@ -10942,10 +10925,7 @@ ha_innobase::ft_init_ext(
/* Allocate FTS handler, and instantiate it before return */
fts_hdl = reinterpret_cast<NEW_FT_INFO*>(
- my_malloc(sizeof(NEW_FT_INFO), MYF(0)));
- /* JAN: TODO: MySQL 5.7 PSI
- my_malloc(PSI_INSTRUMENT_ME, sizeof(NEW_FT_INFO), MYF(0)));
- */
+ my_malloc(/*PSI_INSTRUMENT_ME,*/ sizeof(NEW_FT_INFO), MYF(0)));
fts_hdl->please = const_cast<_ft_vft*>(&ft_vft_result);
fts_hdl->could_you = const_cast<_ft_vft_ext*>(&ft_vft_ext_result);
@@ -12356,13 +12336,7 @@ create_index(
ind_type |= DICT_UNIQUE;
}
- /* JAN: TODO: MySQL 5.7 PSI
- field_lengths = (ulint*) my_malloc(PSI_INSTRUMENT_ME,
- key->user_defined_key_parts * sizeof *
- field_lengths, MYF(MY_FAE));
- */
-
- field_lengths = (ulint*) my_malloc(
+ field_lengths = (ulint*) my_malloc(//PSI_INSTRUMENT_ME,
key->user_defined_key_parts * sizeof *
field_lengths, MYF(MY_FAE));
@@ -12589,8 +12563,7 @@ validate_tablespace_name(
err = HA_WRONG_CREATE_OPTION;
}
} else {
- my_printf_error(
- ER_WRONG_TABLESPACE_NAME,
+ my_printf_error(ER_WRONG_TABLESPACE_NAME,
"InnoDB: A general tablespace"
" name cannot start with `%s`.",
MYF(0), reserved_space_name_prefix);
@@ -13434,8 +13407,6 @@ index_bad:
}
}
- //rec_format_t row_format = m_form->s->row_type;
-
if (m_create_info->key_block_size > 0) {
/* The requested compressed page size (key_block_size)
is given in kilobytes. If it is a valid number, store
@@ -15114,9 +15085,7 @@ innobase_drop_database(
}
ptr++;
- namebuf = (char*) my_malloc((uint) len + 2, MYF(0));
- // JAN: TODO: MySQL 5.7
- //namebuf = (char*) my_malloc(PSI_INSTRUMENT_ME, (uint) len + 2, MYF(0));
+ namebuf = (char*) my_malloc(/*PSI_INSTRUMENT_ME,*/ (uint) len + 2, MYF(0));
memcpy(namebuf, ptr, len);
namebuf[len] = '/';
@@ -15366,8 +15335,9 @@ For other error codes, the server will fall back to counting records. */
#ifdef MYSQL_57_SELECT_COUNT_OPTIMIZATION
int
-ha_innobase::records(ha_rows* num_rows)
-/*===================================*/
+ha_innobase::records(
+/*==================*/
+ ha_rows* num_rows) /*!< out: number of rows */
{
DBUG_ENTER("ha_innobase::records()");
@@ -15439,16 +15409,15 @@ ha_innobase::records(ha_rows* num_rows)
case DB_LOCK_WAIT_TIMEOUT:
*num_rows = HA_POS_ERROR;
DBUG_RETURN(convert_error_code_to_mysql(ret, 0, m_user_thd));
- break;
case DB_INTERRUPTED:
*num_rows = HA_POS_ERROR;
DBUG_RETURN(HA_ERR_QUERY_INTERRUPTED);
- break;
default:
/* No other error besides the three below is returned from
row_scan_index_for_mysql(). Make a debug catch. */
*num_rows = HA_POS_ERROR;
ut_ad(0);
+ DBUG_RETURN(-1);
}
m_prebuilt->trx->op_info = "";
@@ -17894,12 +17863,8 @@ innodb_show_status(
/* allocate buffer for the string, and
read the contents of the temporary file */
- /* JAN: TODO: MySQL 5.7 PSI */
- if (!(str = (char*) my_malloc(
- usable_len + 1, MYF(0)))) {
- /* if (!(str = (char*) my_malloc(PSI_INSTRUMENT_ME,
+ if (!(str = (char*) my_malloc(//PSI_INSTRUMENT_ME,
usable_len + 1, MYF(0)))) {
- */
mutex_exit(&srv_monitor_file_mutex);
DBUG_RETURN(1);
}
@@ -18334,15 +18299,9 @@ get_share(
grows too big */
share = reinterpret_cast<INNOBASE_SHARE*>(
- my_malloc(
+ my_malloc(//PSI_INSTRUMENT_ME,
sizeof(*share) + length + 1,
MYF(MY_FAE | MY_ZEROFILL)));
- /* JAN: TODO: MySQL 5.7 PSI
- share = reinterpret_cast<INNOBASE_SHARE*>(
- my_malloc(PSI_INSTRUMENT_ME,
- sizeof(*share) + length + 1,
- MYF(MY_FAE | MY_ZEROFILL)));
- */
share->table_name = reinterpret_cast<char*>(
memcpy(share + 1, table_name, length + 1));
@@ -19320,64 +19279,6 @@ innobase_rollback_by_xid(
}
}
-#ifdef INNOBASE_CURSOR_VIEW
-
-/*******************************************************************//**
-Create a consistent view for a cursor based on current transaction
-which is created if the corresponding MySQL thread still lacks one.
-This consistent view is then used inside of MySQL when accessing records
-using a cursor.
-@return pointer to cursor view or NULL */
-static
-void*
-innobase_create_cursor_view(
-/*========================*/
- handlerton* hton, /*!< in: innobase hton */
- THD* thd) /*!< in: user thread handle */
-{
- DBUG_ASSERT(hton == innodb_hton_ptr);
-
- return(read_cursor_view_create_for_mysql(check_trx_exists(thd)));
-}
-
-/*******************************************************************//**
-Close the given consistent cursor view of a transaction and restore
-global read view to a transaction read view. Transaction is created if the
-corresponding MySQL thread still lacks one. */
-static
-void
-innobase_close_cursor_view(
-/*=======================*/
- handlerton* hton, /*!< in: innobase hton */
- THD* thd, /*!< in: user thread handle */
- void* curview)/*!< in: Consistent read view to be closed */
-{
- DBUG_ASSERT(hton == innodb_hton_ptr);
-
- read_cursor_view_close_for_mysql(check_trx_exists(thd),
- (cursor_view_t*) curview);
-}
-
-/*******************************************************************//**
-Set the given consistent cursor view to a transaction which is created
-if the corresponding MySQL thread still lacks one. If the given
-consistent cursor view is NULL global read view of a transaction is
-restored to a transaction read view. */
-static
-void
-innobase_set_cursor_view(
-/*=====================*/
- handlerton* hton, /*!< in: innobase hton */
- THD* thd, /*!< in: user thread handle */
- void* curview)/*!< in: Consistent cursor view to be set */
-{
- DBUG_ASSERT(hton == innodb_hton_ptr);
-
- read_cursor_set_for_mysql(check_trx_exists(thd),
- (cursor_view_t*) curview);
-}
-#endif /* INNOBASE_CURSOR_VIEW */
-
bool
ha_innobase::check_if_incompatible_data(
/*====================================*/
@@ -20531,12 +20432,8 @@ innodb_monitor_validate(
by InnoDB, so we can access it in another callback
function innodb_monitor_update() and free it appropriately */
if (name) {
- /* JAN: TODO: MySQL 5.7 PSI
- monitor_name = my_strdup(PSI_INSTRUMENT_ME,
+ monitor_name = my_strdup(//PSI_INSTRUMENT_ME,
name, MYF(0));
- */
- monitor_name = my_strdup(
- name, MYF(0));
} else {
return(1);
}
@@ -21860,7 +21757,7 @@ static MYSQL_SYSVAR_ENUM(checksum_algorithm, srv_checksum_algorithm,
" write a constant magic number, do not allow values other than that"
" magic number when reading;"
" Files updated when this option is set to crc32 or strict_crc32 will"
- " not be readable by InnoDB versions older than 5.6.3",
+ " not be readable by MariaDB versions older than 10.0.4",
NULL, NULL, SRV_CHECKSUM_ALGORITHM_CRC32,
&innodb_checksum_algorithm_typelib);
@@ -23789,11 +23686,6 @@ innobase_get_computed_value(
return(NULL);
}
- /* we just want to store the data in passed in MySQL record */
- if (ret != 0) {
- return(NULL);
- }
-
if (vctempl->mysql_null_bit_mask
&& (mysql_rec[vctempl->mysql_null_byte_offset]
& vctempl->mysql_null_bit_mask)) {
diff --git a/storage/innobase/handler/ha_innodb.h b/storage/innobase/handler/ha_innodb.h
index 1c71735d716..a78925d94e1 100644
--- a/storage/innobase/handler/ha_innodb.h
+++ b/storage/innobase/handler/ha_innodb.h
@@ -1157,19 +1157,3 @@ ib_push_frm_error(
ulint n_keys, /*!< in: InnoDB #keys */
bool push_warning); /*!< in: print warning ? */
-/*****************************************************************//**
-Validates the create options. We may build on this function
-in future. For now, it checks two specifiers:
-KEY_BLOCK_SIZE and ROW_FORMAT
-If innodb_strict_mode is not set then this function is a no-op
-@return NULL if valid, string if not. */
-UNIV_INTERN
-const char*
-create_options_are_invalid(
-/*=======================*/
- THD* thd, /*!< in: connection thread. */
- TABLE* form, /*!< in: information on table
- columns and indexes */
- HA_CREATE_INFO* create_info, /*!< in: create info. */
- bool use_tablespace) /*!< in: srv_file_per_table */
- MY_ATTRIBUTE((nonnull, warn_unused_result));
diff --git a/storage/innobase/handler/handler0alter.cc b/storage/innobase/handler/handler0alter.cc
index cfc01d3d18e..9b4128de426 100644
--- a/storage/innobase/handler/handler0alter.cc
+++ b/storage/innobase/handler/handler0alter.cc
@@ -520,19 +520,7 @@ check_v_col_in_order(
ut_ad(innobase_is_v_fld(field));
- /* Check if this column is in drop list */
- List_iterator_fast<Alter_drop> cf_it(
- ha_alter_info->alter_info->drop_list);
-
- while ((drop = (cf_it++)) != NULL) {
- if (my_strcasecmp(system_charset_info,
- field->field_name, drop->name) == 0) {
- dropped = true;
- break;
- }
- }
-
- if (dropped) {
+ if (field->flags & FIELD_IS_DROPPED) {
continue;
}
@@ -863,7 +851,7 @@ ha_innobase::check_if_supported_inplace_alter(
new_key++) {
#ifdef MYSQL_VIRTUAL_COLUMNS
- /* Do not support adding/droping a vritual column, while
+ /* Do not support adding/droping a virtual column, while
there is a table rebuild caused by adding a new FTS_DOC_ID */
if ((new_key->flags & HA_FULLTEXT) && add_drop_v_cols
&& !DICT_TF2_FLAG_IS_SET(m_prebuilt->table,
@@ -880,7 +868,8 @@ ha_innobase::check_if_supported_inplace_alter(
key_part++) {
const Create_field* new_field;
- DBUG_ASSERT(key_part->fieldnr < altered_table->s->fields);
+ DBUG_ASSERT(key_part->fieldnr
+ < altered_table->s->fields);
cf_it.rewind();
for (uint fieldnr = 0; (new_field = cf_it++);
@@ -1853,7 +1842,9 @@ null_field:
}
/*************************************************************//**
-Copies an InnoDB index entry to table->record[0]. */
+Copies an InnoDB index entry to table->record[0].
+This is used in preparation for print_keydup_error() from
+inline add index */
void
innobase_fields_to_mysql(
/*=====================*/
@@ -1913,7 +1904,9 @@ innobase_fields_to_mysql(
}
/*************************************************************//**
-Copies an InnoDB row to table->record[0]. */
+Copies an InnoDB row to table->record[0].
+This is used in preparation for print_keydup_error() from
+row_log_table_apply() */
void
innobase_row_to_mysql(
/*==================*/
@@ -3775,7 +3768,7 @@ prepare_inplace_add_virtual(
charset_no += MAX_CHAR_COLL_NUM;);
if (charset_no > MAX_CHAR_COLL_NUM) {
- my_error(ER_WRONG_KEY_COLUMN, MYF(0),
+ my_error(ER_WRONG_KEY_COLUMN, MYF(0), "InnoDB",
field->field_name);
return(true);
}
@@ -3919,7 +3912,7 @@ prepare_inplace_drop_virtual(
charset_no += MAX_CHAR_COLL_NUM;);
if (charset_no > MAX_CHAR_COLL_NUM) {
- my_error(ER_WRONG_KEY_COLUMN, MYF(0),
+ my_error(ER_WRONG_KEY_COLUMN, MYF(0), "InnoDB",
field->field_name);
return(true);
}
@@ -4548,10 +4541,8 @@ prepare_inplace_alter_table_dict(
}
}
- /*
- There should be no order change for virtual columns coming in
- here
- */
+ /* There should be no order change for virtual columns coming in
+ here */
ut_ad(check_v_col_in_order(old_table, altered_table, ha_alter_info));
#endif /* MYSQL_VIRTUAL_COLUMNS */
@@ -4792,7 +4783,7 @@ prepare_inplace_alter_table_dict(
if (charset_no > MAX_CHAR_COLL_NUM) {
dict_mem_table_free(
ctx->new_table);
- my_error(ER_WRONG_KEY_COLUMN, MYF(0),
+ my_error(ER_WRONG_KEY_COLUMN, MYF(0), "InnoDB",
field->field_name);
goto new_clustered_failed;
}
@@ -5578,7 +5569,6 @@ rename_index_in_cache(
DBUG_VOID_RETURN;
}
-#
/**
Rename all indexes in data dictionary cache of a given table that are
specified in ha_alter_info.
diff --git a/storage/innobase/handler/i_s.cc b/storage/innobase/handler/i_s.cc
index 37bc9c1f15d..4a13faa480f 100644
--- a/storage/innobase/handler/i_s.cc
+++ b/storage/innobase/handler/i_s.cc
@@ -9406,11 +9406,8 @@ i_s_innodb_mutexes_fill_table(
TABLE_LIST* tables, /*!< in/out: tables to fill */
Item* ) /*!< in: condition (not used) */
{
- ib_mutex_t* mutex;
rw_lock_t* lock;
- ulint block_mutex_oswait_count = 0;
ulint block_lock_oswait_count = 0;
- ib_mutex_t* block_mutex = NULL;
rw_lock_t* block_lock = NULL;
Field** fields = tables->table->field;
@@ -9425,6 +9422,9 @@ i_s_innodb_mutexes_fill_table(
// mutex_enter(&mutex_list_mutex);
#ifdef JAN_TODO_FIXME
+ ib_mutex_t* mutex;
+ ulint block_mutex_oswait_count = 0;
+ ib_mutex_t* block_mutex = NULL;
for (mutex = UT_LIST_GET_FIRST(os_mutex_list); mutex != NULL;
mutex = UT_LIST_GET_NEXT(list, mutex)) {
if (mutex->count_os_wait == 0) {
diff --git a/storage/innobase/row/row0merge.cc b/storage/innobase/row/row0merge.cc
index 0b7c1c36231..e666cf5ccb2 100644
--- a/storage/innobase/row/row0merge.cc
+++ b/storage/innobase/row/row0merge.cc
@@ -30,10 +30,6 @@ Completed by Sunny Bains and Marko Makela
#include "ha_prototypes.h"
-#include <math.h>
-
-#include "ha_prototypes.h"
-
#include "row0merge.h"
#include "row0ext.h"
#include "row0log.h"
@@ -51,7 +47,6 @@ Completed by Sunny Bains and Marko Makela
#include "fsp0sysspace.h"
#include "ut0new.h"
#include "ut0stage.h"
-#include "math.h" /* log() */
#include "fil0crypt.h"
float my_log2f(float n)
diff --git a/storage/innobase/row/row0upd.cc b/storage/innobase/row/row0upd.cc
index d4b8decaea7..759bfb57428 100644
--- a/storage/innobase/row/row0upd.cc
+++ b/storage/innobase/row/row0upd.cc
@@ -2394,7 +2394,8 @@ row_upd_sec_index_entry(
<< " of table " << index->table->name
<< " was not found on update: " << *entry
<< " at: " << rec_index_print(rec, index);
- srv_mbr_print((unsigned char*)entry->fields[0].data);
+ if (entry->fields[0].data)
+ srv_mbr_print((unsigned char*)entry->fields[0].data);
#ifdef UNIV_DEBUG
mtr_commit(&mtr);
mtr_start(&mtr);
diff --git a/storage/innobase/srv/srv0srv.cc b/storage/innobase/srv/srv0srv.cc
index 38f9744e2c6..d2f13ad9b37 100644
--- a/storage/innobase/srv/srv0srv.cc
+++ b/storage/innobase/srv/srv0srv.cc
@@ -45,8 +45,6 @@ Created 10/8/1995 Heikki Tuuri
//
// #include "mysql/psi/mysql_stage.h"
// #include "mysql/psi/psi.h"
-// JAN: TODO: MySQL 5.7 missing header
-//#include "sql_thd_internal_api.h"
#include "ha_prototypes.h"
@@ -2757,7 +2755,7 @@ DECLARE_THREAD(srv_worker_thread)(
srv_sys_mutex_exit();
/* We need to ensure that the worker threads exit after the
- purge coordinator thread. Otherwise the purge coordinaor can
+ purge coordinator thread. Otherwise the purge coordinator can
end up waiting forever in trx_purge_wait_for_workers_to_complete() */
do {