mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
Merge branch '10.11' into 11.4
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@ -136,6 +136,7 @@ scripts/mysqld_safe
|
|||||||
scripts/mysqldumpslow
|
scripts/mysqldumpslow
|
||||||
scripts/mysqlhotcopy
|
scripts/mysqlhotcopy
|
||||||
scripts/mytop
|
scripts/mytop
|
||||||
|
scripts/print_ddl_recovery_log.pl
|
||||||
scripts/wsrep_sst_backup
|
scripts/wsrep_sst_backup
|
||||||
scripts/wsrep_sst_common
|
scripts/wsrep_sst_common
|
||||||
scripts/wsrep_sst_mysqldump
|
scripts/wsrep_sst_mysqldump
|
||||||
|
@ -297,7 +297,7 @@ ENDIF()
|
|||||||
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DENABLED_DEBUG_SYNC")
|
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DENABLED_DEBUG_SYNC")
|
||||||
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DENABLED_DEBUG_SYNC")
|
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DENABLED_DEBUG_SYNC")
|
||||||
|
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "10")
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "10")
|
||||||
# Enable extra checks when using a recent enough version of GNU libstdc++
|
# Enable extra checks when using a recent enough version of GNU libstdc++
|
||||||
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_GLIBCXX_DEBUG -D_GLIBCXX_ASSERTIONS")
|
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_GLIBCXX_DEBUG -D_GLIBCXX_ASSERTIONS")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
@ -890,6 +890,9 @@ static int disable_binlog()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Ok as mysqlcheck is not multi threaded */
|
||||||
|
PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
|
|
||||||
static int handle_request_for_tables(char *tables, size_t length,
|
static int handle_request_for_tables(char *tables, size_t length,
|
||||||
my_bool view, my_bool dont_quote)
|
my_bool view, my_bool dont_quote)
|
||||||
{
|
{
|
||||||
@ -1021,9 +1024,6 @@ static void insert_table_name(DYNAMIC_ARRAY *arr, char *in, size_t dblen)
|
|||||||
insert_dynamic(arr, (uchar*) buf);
|
insert_dynamic(arr, (uchar*) buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Ok as mysqlcheck is not multi threaded */
|
|
||||||
PRAGMA_DISABLE_CHECK_STACK_FRAME
|
|
||||||
|
|
||||||
static void __attribute__((noinline)) print_result()
|
static void __attribute__((noinline)) print_result()
|
||||||
{
|
{
|
||||||
MYSQL_RES *res;
|
MYSQL_RES *res;
|
||||||
|
@ -419,6 +419,8 @@ int main(int argc, char **argv)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
|
|
||||||
void concurrency_loop(MYSQL *mysql, uint current, option_string *eptr)
|
void concurrency_loop(MYSQL *mysql, uint current, option_string *eptr)
|
||||||
{
|
{
|
||||||
unsigned int x;
|
unsigned int x;
|
||||||
@ -514,6 +516,7 @@ void concurrency_loop(MYSQL *mysql, uint current, option_string *eptr)
|
|||||||
my_free(head_sptr);
|
my_free(head_sptr);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
PRAGMA_REENABLE_CHECK_STACK_FRAME
|
||||||
|
|
||||||
|
|
||||||
static struct my_option my_long_options[] =
|
static struct my_option my_long_options[] =
|
||||||
@ -2279,6 +2282,7 @@ statement_cleanup(statement *stmt)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
|
|
||||||
int
|
int
|
||||||
slap_connect(MYSQL *mysql)
|
slap_connect(MYSQL *mysql)
|
||||||
@ -2312,3 +2316,4 @@ slap_connect(MYSQL *mysql)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
PRAGMA_REENABLE_CHECK_STACK_FRAME
|
||||||
|
@ -2860,6 +2860,7 @@ do_result_format_version(struct st_command *command)
|
|||||||
dynstr_append_mem(&ds_res, ds_version.str, ds_version.length);
|
dynstr_append_mem(&ds_res, ds_version.str, ds_version.length);
|
||||||
dynstr_append_mem(&ds_res, STRING_WITH_LEN("\n"));
|
dynstr_append_mem(&ds_res, STRING_WITH_LEN("\n"));
|
||||||
dynstr_free(&ds_version);
|
dynstr_free(&ds_version);
|
||||||
|
DBUG_VOID_RETURN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -171,7 +171,7 @@ ENDIF()
|
|||||||
IF(UNIX)
|
IF(UNIX)
|
||||||
|
|
||||||
# Default GCC flags
|
# Default GCC flags
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC)
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||||
SET(COMMON_C_FLAGS "-g -fno-omit-frame-pointer -fno-strict-aliasing -Wno-uninitialized")
|
SET(COMMON_C_FLAGS "-g -fno-omit-frame-pointer -fno-strict-aliasing -Wno-uninitialized")
|
||||||
STRING(APPEND CMAKE_C_FLAGS_DEBUG " ${COMMON_C_FLAGS}")
|
STRING(APPEND CMAKE_C_FLAGS_DEBUG " ${COMMON_C_FLAGS}")
|
||||||
STRING(APPEND CMAKE_C_FLAGS_RELEASE " ${COMMON_C_FLAGS}")
|
STRING(APPEND CMAKE_C_FLAGS_RELEASE " ${COMMON_C_FLAGS}")
|
||||||
@ -180,7 +180,7 @@ IF(UNIX)
|
|||||||
STRING(REGEX REPLACE "-O2" "-O3" CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
|
STRING(REGEX REPLACE "-O2" "-O3" CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
|
||||||
STRING(REGEX REPLACE "-O2" "-O3" CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO}")
|
STRING(REGEX REPLACE "-O2" "-O3" CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
IF(CMAKE_COMPILER_IS_GNUCXX)
|
IF(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||||
SET(COMMON_CXX_FLAGS "-g -fno-omit-frame-pointer -fno-strict-aliasing -Wno-uninitialized")
|
SET(COMMON_CXX_FLAGS "-g -fno-omit-frame-pointer -fno-strict-aliasing -Wno-uninitialized")
|
||||||
STRING(APPEND CMAKE_CXX_FLAGS_DEBUG " ${COMMON_CXX_FLAGS}")
|
STRING(APPEND CMAKE_CXX_FLAGS_DEBUG " ${COMMON_CXX_FLAGS}")
|
||||||
STRING(APPEND CMAKE_CXX_FLAGS_RELEASE " ${COMMON_CXX_FLAGS}")
|
STRING(APPEND CMAKE_CXX_FLAGS_RELEASE " ${COMMON_CXX_FLAGS}")
|
||||||
@ -200,11 +200,11 @@ IF(UNIX)
|
|||||||
SET(z_flags "")
|
SET(z_flags "")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC)
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||||
STRING(APPEND CMAKE_C_FLAGS_RELEASE " ${z_flags}")
|
STRING(APPEND CMAKE_C_FLAGS_RELEASE " ${z_flags}")
|
||||||
STRING(APPEND CMAKE_C_FLAGS_RELWITHDEBINFO " ${z_flags}")
|
STRING(APPEND CMAKE_C_FLAGS_RELWITHDEBINFO " ${z_flags}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
IF(CMAKE_COMPILER_IS_GNUCXX)
|
IF(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||||
STRING(APPEND CMAKE_CXX_FLAGS_RELEASE " ${z_flags}")
|
STRING(APPEND CMAKE_CXX_FLAGS_RELEASE " ${z_flags}")
|
||||||
STRING(APPEND CMAKE_CXX_FLAGS_RELWITHDEBINFO " ${z_flags}")
|
STRING(APPEND CMAKE_CXX_FLAGS_RELWITHDEBINFO " ${z_flags}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA
|
||||||
|
|
||||||
IF(CMAKE_SYSTEM_NAME MATCHES "SunOS" AND CMAKE_COMPILER_IS_GNUCXX
|
IF(CMAKE_SYSTEM_NAME MATCHES "SunOS" AND CMAKE_CXX_COMPILER_ID STREQUAL "GNU"
|
||||||
AND CMAKE_SIZEOF_VOID_P EQUAL 4)
|
AND CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||||
IF(NOT DEFINED BUGGY_GCC_NO_DTRACE_MODULES)
|
IF(NOT DEFINED BUGGY_GCC_NO_DTRACE_MODULES)
|
||||||
EXECUTE_PROCESS(
|
EXECUTE_PROCESS(
|
||||||
|
@ -42,6 +42,10 @@ SET(MY_WARNING_FLAGS
|
|||||||
-Wcast-function-type-strict
|
-Wcast-function-type-strict
|
||||||
)
|
)
|
||||||
|
|
||||||
|
IF(NOT (WITH_MSAN OR WITH_ASAN OR WITH_UBSAN))
|
||||||
|
SET(MY_WARNING_FLAGS ${MY_WARNING_FLAGS} -Wframe-larger-than=16384)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
# Warning flags that are in testing before moving
|
# Warning flags that are in testing before moving
|
||||||
# to MY_WARNING_FLAGS if stable.
|
# to MY_WARNING_FLAGS if stable.
|
||||||
SET(MY_WARNING_FLAGS_NON_FATAL
|
SET(MY_WARNING_FLAGS_NON_FATAL
|
||||||
@ -58,7 +62,7 @@ ENDFOREACH()
|
|||||||
|
|
||||||
SET(MY_ERROR_FLAGS -Werror -fno-operator-names -Wsuggest-override)
|
SET(MY_ERROR_FLAGS -Werror -fno-operator-names -Wsuggest-override)
|
||||||
|
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC AND CMAKE_C_COMPILER_VERSION VERSION_LESS "6.0.0")
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND CMAKE_C_COMPILER_VERSION VERSION_LESS "6.0.0")
|
||||||
SET(MY_ERROR_FLAGS ${MY_ERROR_FLAGS} -Wno-error=maybe-uninitialized)
|
SET(MY_ERROR_FLAGS ${MY_ERROR_FLAGS} -Wno-error=maybe-uninitialized)
|
||||||
SET(MY_ERROR_FLAGS ${MY_ERROR_FLAGS} -Wno-error=non-virtual-dtor) # gcc bug 7302
|
SET(MY_ERROR_FLAGS ${MY_ERROR_FLAGS} -Wno-error=non-virtual-dtor) # gcc bug 7302
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
@ -69,8 +69,8 @@ CHECK_C_SOURCE_RUNS(
|
|||||||
|
|
||||||
|
|
||||||
# Check is special processor flag needs to be set on older GCC
|
# Check is special processor flag needs to be set on older GCC
|
||||||
#that defaults to v8 sparc . Code here is taken from my_rdtsc.h
|
# that defaults to v8 sparc . Code here is taken from my_rdtsc.h
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC AND CMAKE_SIZEOF_VOID_P EQUAL 4
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND CMAKE_SIZEOF_VOID_P EQUAL 4
|
||||||
AND CMAKE_SYSTEM_PROCESSOR MATCHES "sparc")
|
AND CMAKE_SYSTEM_PROCESSOR MATCHES "sparc")
|
||||||
SET(SOURCE
|
SET(SOURCE
|
||||||
"
|
"
|
||||||
|
@ -82,6 +82,14 @@ IF(WITH_INNOBASE_STORAGE_ENGINE)
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
# clang ~16+ with return values being undefined is resolved by basic optimization
|
||||||
|
# compiler flags for the function mach_read_from_2 (per MDEV-36316)
|
||||||
|
IF(WITH_MSAN AND CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
|
SET_SOURCE_FILES_PROPERTIES(
|
||||||
|
${INNOBASE_SOURCES}
|
||||||
|
innochecksum.cc
|
||||||
|
PROPERTIES COMPILE_FLAGS -Og)
|
||||||
|
ENDIF()
|
||||||
MYSQL_ADD_EXECUTABLE(innochecksum innochecksum.cc ${INNOBASE_SOURCES})
|
MYSQL_ADD_EXECUTABLE(innochecksum innochecksum.cc ${INNOBASE_SOURCES})
|
||||||
TARGET_LINK_LIBRARIES(innochecksum mysys mysys_ssl)
|
TARGET_LINK_LIBRARIES(innochecksum mysys mysys_ssl)
|
||||||
ADD_DEPENDENCIES(innochecksum GenError)
|
ADD_DEPENDENCIES(innochecksum GenError)
|
||||||
|
@ -955,6 +955,7 @@ void Backup::set_post_copy_table_hook(const post_copy_table_hook_t &hook) {
|
|||||||
|
|
||||||
bool prepare(const char *target_dir) {
|
bool prepare(const char *target_dir) {
|
||||||
maria_data_root= (char *)target_dir;
|
maria_data_root= (char *)target_dir;
|
||||||
|
maria_tmpdir= &mysql_tmpdir_list;
|
||||||
|
|
||||||
if (maria_init())
|
if (maria_init())
|
||||||
die("Can't init Aria engine (%d)", errno);
|
die("Can't init Aria engine (%d)", errno);
|
||||||
|
@ -209,7 +209,10 @@ xb_fil_cur_open(
|
|||||||
cursor->buf_size = XB_FIL_CUR_PAGES * cursor->page_size;
|
cursor->buf_size = XB_FIL_CUR_PAGES * cursor->page_size;
|
||||||
cursor->buf = static_cast<byte*>(aligned_malloc(cursor->buf_size,
|
cursor->buf = static_cast<byte*>(aligned_malloc(cursor->buf_size,
|
||||||
srv_page_size));
|
srv_page_size));
|
||||||
|
cursor->tmp_page = static_cast<byte*>(aligned_malloc(srv_page_size,
|
||||||
|
srv_page_size));
|
||||||
|
cursor->tmp_frame = static_cast<byte*>(aligned_malloc(srv_page_size,
|
||||||
|
srv_page_size));
|
||||||
cursor->buf_read = 0;
|
cursor->buf_read = 0;
|
||||||
cursor->buf_npages = 0;
|
cursor->buf_npages = 0;
|
||||||
cursor->buf_offset = 0;
|
cursor->buf_offset = 0;
|
||||||
@ -237,15 +240,10 @@ xb_fil_cur_open(
|
|||||||
return(XB_FIL_CUR_SUCCESS);
|
return(XB_FIL_CUR_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Stack usage 131224 with clang */
|
|
||||||
PRAGMA_DISABLE_CHECK_STACK_FRAME
|
|
||||||
|
|
||||||
static bool page_is_corrupted(const byte *page, ulint page_no,
|
static bool page_is_corrupted(const byte *page, ulint page_no,
|
||||||
const xb_fil_cur_t *cursor,
|
const xb_fil_cur_t *cursor,
|
||||||
const fil_space_t *space)
|
const fil_space_t *space)
|
||||||
{
|
{
|
||||||
byte tmp_frame[UNIV_PAGE_SIZE_MAX];
|
|
||||||
byte tmp_page[UNIV_PAGE_SIZE_MAX];
|
|
||||||
const ulint page_size = cursor->page_size;
|
const ulint page_size = cursor->page_size;
|
||||||
uint16_t page_type = fil_page_get_type(page);
|
uint16_t page_type = fil_page_get_type(page);
|
||||||
|
|
||||||
@ -308,42 +306,43 @@ static bool page_is_corrupted(const byte *page, ulint page_no,
|
|||||||
&& !opt_extended_validation)
|
&& !opt_extended_validation)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
memcpy(tmp_page, page, page_size);
|
memcpy(cursor->tmp_page, page, page_size);
|
||||||
|
|
||||||
if (!space->crypt_data
|
if (!space->crypt_data
|
||||||
|| space->crypt_data->type == CRYPT_SCHEME_UNENCRYPTED
|
|| space->crypt_data->type == CRYPT_SCHEME_UNENCRYPTED
|
||||||
|| !fil_space_decrypt(space, tmp_frame, tmp_page)) {
|
|| !fil_space_decrypt(space, cursor->tmp_frame,
|
||||||
|
cursor->tmp_page)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (page_type != FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED) {
|
if (page_type != FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED) {
|
||||||
return buf_page_is_corrupted(false, tmp_page,
|
return buf_page_is_corrupted(false, cursor->tmp_page,
|
||||||
space->flags);
|
space->flags);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (page_type == FIL_PAGE_PAGE_COMPRESSED) {
|
if (page_type == FIL_PAGE_PAGE_COMPRESSED) {
|
||||||
memcpy(tmp_page, page, page_size);
|
memcpy(cursor->tmp_page, page, page_size);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (page_type == FIL_PAGE_PAGE_COMPRESSED
|
if (page_type == FIL_PAGE_PAGE_COMPRESSED
|
||||||
|| page_type == FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED) {
|
|| page_type == FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED) {
|
||||||
ulint decomp = fil_page_decompress(tmp_frame, tmp_page,
|
ulint decomp = fil_page_decompress(cursor->tmp_frame,
|
||||||
|
cursor->tmp_page,
|
||||||
space->flags);
|
space->flags);
|
||||||
page_type = fil_page_get_type(tmp_page);
|
page_type = fil_page_get_type(cursor->tmp_page);
|
||||||
|
|
||||||
return (!decomp
|
return (!decomp
|
||||||
|| (decomp != srv_page_size
|
|| (decomp != srv_page_size
|
||||||
&& cursor->zip_size)
|
&& cursor->zip_size)
|
||||||
|| page_type == FIL_PAGE_PAGE_COMPRESSED
|
|| page_type == FIL_PAGE_PAGE_COMPRESSED
|
||||||
|| page_type == FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED
|
|| page_type == FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED
|
||||||
|| buf_page_is_corrupted(false, tmp_page,
|
|| buf_page_is_corrupted(false, cursor->tmp_page,
|
||||||
space->flags));
|
space->flags));
|
||||||
}
|
}
|
||||||
|
|
||||||
return buf_page_is_corrupted(false, page, space->flags);
|
return buf_page_is_corrupted(false, page, space->flags);
|
||||||
}
|
}
|
||||||
PRAGMA_REENABLE_CHECK_STACK_FRAME
|
|
||||||
|
|
||||||
/** Reads and verifies the next block of pages from the source
|
/** Reads and verifies the next block of pages from the source
|
||||||
file. Positions the cursor after the last read non-corrupted page.
|
file. Positions the cursor after the last read non-corrupted page.
|
||||||
@ -507,7 +506,11 @@ xb_fil_cur_close(
|
|||||||
xb_fil_cur_t *cursor) /*!< in/out: source file cursor */
|
xb_fil_cur_t *cursor) /*!< in/out: source file cursor */
|
||||||
{
|
{
|
||||||
aligned_free(cursor->buf);
|
aligned_free(cursor->buf);
|
||||||
|
aligned_free(cursor->tmp_page);
|
||||||
|
aligned_free(cursor->tmp_frame);
|
||||||
cursor->buf = NULL;
|
cursor->buf = NULL;
|
||||||
|
cursor->tmp_page = NULL;
|
||||||
|
cursor->tmp_frame = NULL;
|
||||||
|
|
||||||
if (cursor->node != NULL) {
|
if (cursor->node != NULL) {
|
||||||
xb_fil_node_close_file(cursor->node);
|
xb_fil_node_close_file(cursor->node);
|
||||||
|
@ -46,7 +46,9 @@ struct xb_fil_cur_t {
|
|||||||
xb_read_filt_t* read_filter; /*!< read filter */
|
xb_read_filt_t* read_filter; /*!< read filter */
|
||||||
xb_read_filt_ctxt_t read_filter_ctxt;
|
xb_read_filt_ctxt_t read_filter_ctxt;
|
||||||
/*!< read filter context */
|
/*!< read filter context */
|
||||||
byte* buf; /*!< read buffer */
|
byte* buf; /*!< read buffer of XB_FIL_CUR_PAGES */
|
||||||
|
byte* tmp_page; /*!< buffer for decrypting a page */
|
||||||
|
byte* tmp_frame; /*!< buffer for decompressing a page */
|
||||||
size_t buf_size; /*!< buffer size in bytes */
|
size_t buf_size; /*!< buffer size in bytes */
|
||||||
size_t buf_read; /*!< number of read bytes in buffer
|
size_t buf_read; /*!< number of read bytes in buffer
|
||||||
after the last cursor read */
|
after the last cursor read */
|
||||||
|
@ -1187,6 +1187,7 @@ static void backup_file_op_fail(uint32_t space_id, int type,
|
|||||||
const byte* name, ulint len,
|
const byte* name, ulint len,
|
||||||
const byte* new_name, ulint new_len)
|
const byte* new_name, ulint new_len)
|
||||||
{
|
{
|
||||||
|
const char *error= "";
|
||||||
bool fail = false;
|
bool fail = false;
|
||||||
const std::string spacename{filename_to_spacename(name, len)};
|
const std::string spacename{filename_to_spacename(name, len)};
|
||||||
switch (type) {
|
switch (type) {
|
||||||
@ -1194,6 +1195,7 @@ static void backup_file_op_fail(uint32_t space_id, int type,
|
|||||||
msg("DDL tracking : create %" PRIu32 " \"%.*s\"",
|
msg("DDL tracking : create %" PRIu32 " \"%.*s\"",
|
||||||
space_id, int(len), name);
|
space_id, int(len), name);
|
||||||
fail = !check_if_skip_table(spacename.c_str());
|
fail = !check_if_skip_table(spacename.c_str());
|
||||||
|
error= "create";
|
||||||
break;
|
break;
|
||||||
case FILE_MODIFY:
|
case FILE_MODIFY:
|
||||||
break;
|
break;
|
||||||
@ -1203,12 +1205,14 @@ static void backup_file_op_fail(uint32_t space_id, int type,
|
|||||||
fail = !check_if_skip_table(spacename.c_str())
|
fail = !check_if_skip_table(spacename.c_str())
|
||||||
|| !check_if_skip_table(
|
|| !check_if_skip_table(
|
||||||
filename_to_spacename(new_name, new_len).c_str());
|
filename_to_spacename(new_name, new_len).c_str());
|
||||||
|
error= "rename";
|
||||||
break;
|
break;
|
||||||
case FILE_DELETE:
|
case FILE_DELETE:
|
||||||
fail = !check_if_skip_table(spacename.c_str())
|
fail = !check_if_skip_table(spacename.c_str())
|
||||||
&& !check_if_fts_table(spacename.c_str());
|
&& !check_if_fts_table(spacename.c_str());
|
||||||
msg("DDL tracking : delete %" PRIu32 " \"%.*s\"",
|
msg("DDL tracking : delete %" PRIu32 " \"%.*s\"",
|
||||||
space_id, int(len), name);
|
space_id, int(len), name);
|
||||||
|
error= "delete";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
ut_ad(0);
|
ut_ad(0);
|
||||||
@ -1216,9 +1220,14 @@ static void backup_file_op_fail(uint32_t space_id, int type,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (fail) {
|
if (fail) {
|
||||||
ut_a(opt_no_lock);
|
if (opt_no_lock)
|
||||||
die("DDL operation detected in the late phase of backup."
|
die("DDL operation detected in the late phase of backup while "
|
||||||
"Backup is inconsistent. Remove --no-lock option to fix.");
|
"executing %s on %s. "
|
||||||
|
"Backup is inconsistent. Remove --no-lock option to fix.",
|
||||||
|
error, name);
|
||||||
|
die("Unexpected DDL operation detected in the late phase of backup "
|
||||||
|
"while executing %s on %s. Backup is inconsistent.",
|
||||||
|
error, name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -126,7 +126,8 @@ endif()
|
|||||||
# Silence some warnings
|
# Silence some warnings
|
||||||
if(MSVC)
|
if(MSVC)
|
||||||
# truncation warnings
|
# truncation warnings
|
||||||
target_compile_options(wolfssl PRIVATE $<$<COMPILE_LANGUAGE:C>:/wd4244>)
|
target_compile_options(wolfssl PRIVATE $<$<COMPILE_LANGUAGE:C>:/wd4244 /wd5287 /wd5286>)
|
||||||
|
target_compile_definitions(wolfssl PUBLIC WC_NO_STATIC_ASSERT)
|
||||||
if(CMAKE_C_COMPILER_ID MATCHES Clang)
|
if(CMAKE_C_COMPILER_ID MATCHES Clang)
|
||||||
target_compile_options(wolfssl PRIVATE $<$<COMPILE_LANGUAGE:C>:-Wno-incompatible-function-pointer-types>)
|
target_compile_options(wolfssl PRIVATE $<$<COMPILE_LANGUAGE:C>:-Wno-incompatible-function-pointer-types>)
|
||||||
endif()
|
endif()
|
||||||
|
@ -83,17 +83,30 @@
|
|||||||
|
|
||||||
/* Define pragmas to disable warnings for stack frame checking */
|
/* Define pragmas to disable warnings for stack frame checking */
|
||||||
|
|
||||||
#if defined(__clang__)
|
#ifdef __GNUC__
|
||||||
#define PRAGMA_DISABLE_CHECK_STACK_FRAME \
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME \
|
||||||
_Pragma("clang diagnostic push") \
|
_Pragma("GCC diagnostic push") \
|
||||||
_Pragma("clang diagnostic ignored \"-Wframe-larger-than=\"")
|
_Pragma("GCC diagnostic ignored \"-Wframe-larger-than=\"")
|
||||||
|
|
||||||
#define PRAGMA_REENABLE_CHECK_STACK_FRAME \
|
#define PRAGMA_REENABLE_CHECK_STACK_FRAME \
|
||||||
_Pragma("clang diagnostic pop")
|
_Pragma("GCC diagnostic pop")
|
||||||
|
|
||||||
|
/*
|
||||||
|
The following check is for older gcc version that allocates
|
||||||
|
a lot of stack during startup that does not need to be checked
|
||||||
|
*/
|
||||||
|
|
||||||
|
#if !defined(__clang__) && __GNUC__ < 13
|
||||||
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME_EXTRA PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
#else
|
#else
|
||||||
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME_EXTRA
|
||||||
|
#endif /* !defined(__clang__) && __GNUC__ < 13 */
|
||||||
|
|
||||||
|
#else /*! __GNUC__ */
|
||||||
#define PRAGMA_DISABLE_CHECK_STACK_FRAME
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
#define PRAGMA_REENABLE_CHECK_STACK_FRAME
|
#define PRAGMA_REENABLE_CHECK_STACK_FRAME
|
||||||
#endif
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME
|
||||||
|
#define PRAGMA_DISABLE_CHECK_STACK_FRAME_EXTRA
|
||||||
|
#endif /* __GNUC__ */
|
||||||
|
|
||||||
#endif /* _my_attribute_h */
|
#endif /* _my_attribute_h */
|
||||||
|
@ -667,7 +667,17 @@ extern void my_mutex_end(void);
|
|||||||
We need to have at least 256K stack to handle calls to myisamchk_init()
|
We need to have at least 256K stack to handle calls to myisamchk_init()
|
||||||
with the current number of keys and key parts.
|
with the current number of keys and key parts.
|
||||||
*/
|
*/
|
||||||
# if defined(__SANITIZE_ADDRESS__) || defined(WITH_UBSAN)
|
#if !defined(__has_feature)
|
||||||
|
#define __has_feature(x) 0
|
||||||
|
#endif
|
||||||
|
#if defined(__clang__) && __has_feature(memory_sanitizer) && !defined(DBUG_OFF)
|
||||||
|
/*
|
||||||
|
MSAN in Debug with clang-20.1 required more memory to complete
|
||||||
|
mtr begin/end checks. The result without increase was MSAN
|
||||||
|
errors triggered on a call instruction.
|
||||||
|
*/
|
||||||
|
# define DEFAULT_THREAD_STACK (2L<<20)
|
||||||
|
# elif defined(__SANITIZE_ADDRESS__) || defined(WITH_UBSAN)
|
||||||
/*
|
/*
|
||||||
Optimized WITH_ASAN=ON executables produced
|
Optimized WITH_ASAN=ON executables produced
|
||||||
by GCC 12.3.0, GCC 13.2.0, or clang 16.0.6
|
by GCC 12.3.0, GCC 13.2.0, or clang 16.0.6
|
||||||
|
@ -230,7 +230,6 @@ static inline longlong sec_part_unshift(longlong second_part, uint digits)
|
|||||||
/* Date/time rounding and truncation functions */
|
/* Date/time rounding and truncation functions */
|
||||||
static inline long my_time_fraction_remainder(long nr, uint decimals)
|
static inline long my_time_fraction_remainder(long nr, uint decimals)
|
||||||
{
|
{
|
||||||
DBUG_ASSERT(decimals <= TIME_SECOND_PART_DIGITS);
|
|
||||||
return nr % (long) log_10_int[TIME_SECOND_PART_DIGITS - decimals];
|
return nr % (long) log_10_int[TIME_SECOND_PART_DIGITS - decimals];
|
||||||
}
|
}
|
||||||
static inline void my_datetime_trunc(MYSQL_TIME *ltime, uint decimals)
|
static inline void my_datetime_trunc(MYSQL_TIME *ltime, uint decimals)
|
||||||
|
8
mysql-test/include/no_msan_without_big.inc
Normal file
8
mysql-test/include/no_msan_without_big.inc
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
# Slow with MSAN, but if mtr --big-test specified, then it should complete
|
||||||
|
if (!$BIG_TEST)
|
||||||
|
{
|
||||||
|
if (`select count(*) from information_schema.system_variables where variable_name='have_sanitizer' and global_value like "MSAN%"`)
|
||||||
|
{
|
||||||
|
--skip Can't be run WITH_MSAN unless using --big-test
|
||||||
|
}
|
||||||
|
}
|
@ -1,4 +1,5 @@
|
|||||||
# This file should only be used with tests that are too big or slow for MSAN.
|
# This file should only be used with tests that are too big or slow for MSAN (even with --big-test).
|
||||||
|
# Use no_msan_without_big instead unless this really won't complete in a test timeout period.
|
||||||
|
|
||||||
if (`select count(*) from information_schema.system_variables where variable_name='have_sanitizer' and global_value like "MSAN%"`)
|
if (`select count(*) from information_schema.system_variables where variable_name='have_sanitizer' and global_value like "MSAN%"`)
|
||||||
{
|
{
|
||||||
|
9
mysql-test/include/not_msan_with_debug.inc
Normal file
9
mysql-test/include/not_msan_with_debug.inc
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
# This file should only be used with tests that are too big or slow for MSAN with Debug.
|
||||||
|
|
||||||
|
if (`select count(*) from information_schema.system_variables where variable_name='have_sanitizer' and global_value like "MSAN%"`)
|
||||||
|
{
|
||||||
|
if (`select version() like '%debug%'`)
|
||||||
|
{
|
||||||
|
--skip Can't be run WITH_MSAN and CMAKE_BUILD_TYPE=Debug
|
||||||
|
}
|
||||||
|
}
|
@ -1,4 +1,3 @@
|
|||||||
--source include/not_msan.inc
|
|
||||||
--source include/not_embedded.inc
|
--source include/not_embedded.inc
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
|
|
||||||
|
@ -453,5 +453,56 @@ SELECT * FROM t1 WHERE f LIKE '2023%';
|
|||||||
f
|
f
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
#
|
#
|
||||||
|
# MDEV-36536 Add option to not collect statistics for long char/varchars
|
||||||
|
#
|
||||||
|
select @@session.analyze_max_length;
|
||||||
|
@@session.analyze_max_length
|
||||||
|
4294967295
|
||||||
|
create table t1 (c0 char(2), c1 char(16), c2 char(64), v1 varchar(16), v2 varchar(1000), b1 blob, i1 int)
|
||||||
|
character set utf8mb4 COLLATE utf8mb4_bin;
|
||||||
|
insert into t1 values ("A", "A","A","A","A","A",1), ("B","B","B","B","B","B",1);
|
||||||
|
ANALYZE TABLE t1 PERSISTENT FOR ALL;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 analyze status Engine-independent statistics collected
|
||||||
|
test.t1 analyze Warning Engine-independent statistics are not collected for column 'b1'
|
||||||
|
test.t1 analyze status OK
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
column_name
|
||||||
|
c0
|
||||||
|
c1
|
||||||
|
c2
|
||||||
|
i1
|
||||||
|
v1
|
||||||
|
v2
|
||||||
|
set @@session.analyze_max_length= 64;
|
||||||
|
truncate table mysql.column_stats;
|
||||||
|
ANALYZE TABLE t1 PERSISTENT FOR ALL;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 analyze status Engine-independent statistics collected
|
||||||
|
test.t1 analyze Warning Engine-independent statistics are not collected for column 'c2'
|
||||||
|
test.t1 analyze Warning Engine-independent statistics are not collected for column 'v2'
|
||||||
|
test.t1 analyze Warning Engine-independent statistics are not collected for column 'b1'
|
||||||
|
test.t1 analyze status Table is already up to date
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
column_name
|
||||||
|
c0
|
||||||
|
c1
|
||||||
|
i1
|
||||||
|
v1
|
||||||
|
truncate table mysql.column_stats;
|
||||||
|
ANALYZE TABLE t1 PERSISTENT for COLUMNS (c0,c2,v1,v2,i1) INDEXES ALL;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 analyze status Engine-independent statistics collected
|
||||||
|
test.t1 analyze status Table is already up to date
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
column_name
|
||||||
|
c0
|
||||||
|
c2
|
||||||
|
i1
|
||||||
|
v1
|
||||||
|
v2
|
||||||
|
set @@session.analyze_max_length= default;
|
||||||
|
drop table t1;
|
||||||
|
#
|
||||||
# End of 10.6 tests
|
# End of 10.6 tests
|
||||||
#
|
#
|
||||||
|
@ -306,6 +306,26 @@ ANALYZE TABLE t1 PERSISTENT FOR ALL;
|
|||||||
SELECT * FROM t1 WHERE f LIKE '2023%';
|
SELECT * FROM t1 WHERE f LIKE '2023%';
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36536 Add option to not collect statistics for long char/varchars
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
select @@session.analyze_max_length;
|
||||||
|
create table t1 (c0 char(2), c1 char(16), c2 char(64), v1 varchar(16), v2 varchar(1000), b1 blob, i1 int)
|
||||||
|
character set utf8mb4 COLLATE utf8mb4_bin;
|
||||||
|
insert into t1 values ("A", "A","A","A","A","A",1), ("B","B","B","B","B","B",1);
|
||||||
|
ANALYZE TABLE t1 PERSISTENT FOR ALL;
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
set @@session.analyze_max_length= 64;
|
||||||
|
truncate table mysql.column_stats;
|
||||||
|
ANALYZE TABLE t1 PERSISTENT FOR ALL;
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
truncate table mysql.column_stats;
|
||||||
|
ANALYZE TABLE t1 PERSISTENT for COLUMNS (c0,c2,v1,v2,i1) INDEXES ALL;
|
||||||
|
select column_name from mysql.column_stats where table_name = 't1';
|
||||||
|
set @@session.analyze_max_length= default;
|
||||||
|
drop table t1;
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.6 tests
|
--echo # End of 10.6 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -266,6 +266,7 @@ col1
|
|||||||
SET AUTOCOMMIT = 0;
|
SET AUTOCOMMIT = 0;
|
||||||
UPDATE t_permanent_innodb SET col1 = 9;
|
UPDATE t_permanent_innodb SET col1 = 9;
|
||||||
UPDATE t_permanent_aria SET col1 = 9;
|
UPDATE t_permanent_aria SET col1 = 9;
|
||||||
|
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||||
UPDATE t_permanent_myisam SET col1 = 9;
|
UPDATE t_permanent_myisam SET col1 = 9;
|
||||||
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||||
UPDATE t_permanent_aria2 SET col1 = 9;
|
UPDATE t_permanent_aria2 SET col1 = 9;
|
||||||
|
@ -328,6 +328,7 @@ select * from t_permanent_aria2;
|
|||||||
|
|
||||||
SET AUTOCOMMIT = 0;
|
SET AUTOCOMMIT = 0;
|
||||||
UPDATE t_permanent_innodb SET col1 = 9;
|
UPDATE t_permanent_innodb SET col1 = 9;
|
||||||
|
--error ER_LOCK_WAIT_TIMEOUT
|
||||||
UPDATE t_permanent_aria SET col1 = 9;
|
UPDATE t_permanent_aria SET col1 = 9;
|
||||||
--error ER_LOCK_WAIT_TIMEOUT
|
--error ER_LOCK_WAIT_TIMEOUT
|
||||||
UPDATE t_permanent_myisam SET col1 = 9;
|
UPDATE t_permanent_myisam SET col1 = 9;
|
||||||
|
@ -139,7 +139,7 @@ drop table t1;
|
|||||||
create or replace table t1( c1 int auto_increment primary key, check( c1 > 0 or c1 is null ) );
|
create or replace table t1( c1 int auto_increment primary key, check( c1 > 0 or c1 is null ) );
|
||||||
ERROR HY000: Function or expression 'AUTO_INCREMENT' cannot be used in the CHECK clause of `c1`
|
ERROR HY000: Function or expression 'AUTO_INCREMENT' cannot be used in the CHECK clause of `c1`
|
||||||
create table t1 (a int check (@b in (select user from mysql.user)));
|
create table t1 (a int check (@b in (select user from mysql.user)));
|
||||||
ERROR HY000: Function or expression 'select ...' cannot be used in the CHECK clause of `a`
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
create table t1 (a int check (a > @b));
|
create table t1 (a int check (a > @b));
|
||||||
ERROR HY000: Function or expression '@b' cannot be used in the CHECK clause of `a`
|
ERROR HY000: Function or expression '@b' cannot be used in the CHECK clause of `a`
|
||||||
create table t1 (a int check (a = 1));
|
create table t1 (a int check (a = 1));
|
||||||
|
@ -87,7 +87,7 @@ create or replace table t1( c1 int auto_increment primary key, check( c1 > 0 or
|
|||||||
#
|
#
|
||||||
# MDEV-12421 Check constraint with query crashes server and renders DB unusable
|
# MDEV-12421 Check constraint with query crashes server and renders DB unusable
|
||||||
#
|
#
|
||||||
--error ER_GENERATED_COLUMN_FUNCTION_IS_NOT_ALLOWED
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
create table t1 (a int check (@b in (select user from mysql.user)));
|
create table t1 (a int check (@b in (select user from mysql.user)));
|
||||||
--error ER_GENERATED_COLUMN_FUNCTION_IS_NOT_ALLOWED
|
--error ER_GENERATED_COLUMN_FUNCTION_IS_NOT_ALLOWED
|
||||||
create table t1 (a int check (a > @b));
|
create table t1 (a int check (a > @b));
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
--source include/default_optimizer_switch.inc
|
--source include/default_optimizer_switch.inc
|
||||||
# This is too slow on MSAN
|
# This is too slow on MSAN
|
||||||
--source include/not_msan.inc
|
--source include/no_msan_without_big.inc
|
||||||
--source include/not_valgrind.inc
|
--source include/not_valgrind.inc
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
|
|
||||||
|
@ -1383,6 +1383,152 @@ drop table t1,t2,t3;
|
|||||||
# End of 10.3 tests
|
# End of 10.3 tests
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
|
# MDEV-24588: Fix crash with unnamed column in derived table.
|
||||||
|
# Assertion `item->name.str && item->name.str[0]` in
|
||||||
|
# `TABLE_LIST::create_field_translation` fails when a SELECT
|
||||||
|
# query includes a derived table containing unnamed column
|
||||||
|
# (eg: `SELECT '' from t`).
|
||||||
|
#
|
||||||
|
# Tests from the bug report
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
SELECT SHA(pk) IN (SELECT * FROM (SELECT '' FROM t) AS a) FROM t;
|
||||||
|
SHA(pk) IN (SELECT * FROM (SELECT '' FROM t) AS a)
|
||||||
|
0
|
||||||
|
0
|
||||||
|
0
|
||||||
|
SET sql_mode='';
|
||||||
|
PREPARE p FROM 'SELECT SHA(pk) IN (SELECT * FROM (SELECT \'\' FROM t) AS a) FROM t;';
|
||||||
|
EXECUTE p;
|
||||||
|
SHA(pk) IN (SELECT * FROM (SELECT '' FROM t) AS a)
|
||||||
|
0
|
||||||
|
0
|
||||||
|
0
|
||||||
|
EXECUTE p;
|
||||||
|
SHA(pk) IN (SELECT * FROM (SELECT '' FROM t) AS a)
|
||||||
|
0
|
||||||
|
0
|
||||||
|
0
|
||||||
|
DEALLOCATE PREPARE p;
|
||||||
|
# Tests on derived tables
|
||||||
|
SELECT * FROM (SELECT 1, '' FROM t) AS a;
|
||||||
|
1
|
||||||
|
1
|
||||||
|
1
|
||||||
|
1
|
||||||
|
SELECT * FROM (SELECT '', 1 FROM t) AS a;
|
||||||
|
1
|
||||||
|
1
|
||||||
|
1
|
||||||
|
1
|
||||||
|
SELECT * FROM (SELECT 1, 2, '' FROM t) AS a;
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
SELECT * FROM (SELECT pk, '' FROM t) AS a;
|
||||||
|
pk
|
||||||
|
1
|
||||||
|
2
|
||||||
|
3
|
||||||
|
SELECT '/', '/';
|
||||||
|
/ /
|
||||||
|
/ /
|
||||||
|
SELECT * FROM (SELECT pk, '', '' as c1 FROM t) AS a;
|
||||||
|
pk c1
|
||||||
|
1
|
||||||
|
2
|
||||||
|
3
|
||||||
|
SELECT * FROM (SELECT '', '' from t) AS a;
|
||||||
|
ERROR 42S21: Duplicate column name ''
|
||||||
|
SELECT * FROM (SELECT '/', '/' FROM t) AS a;
|
||||||
|
ERROR 42S21: Duplicate column name '/'
|
||||||
|
SELECT * FROM (SELECT '/', '/') AS a;
|
||||||
|
ERROR 42S21: Duplicate column name '/'
|
||||||
|
DROP TABLE t;
|
||||||
|
# Tests on views
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
CREATE VIEW v_t AS SELECT * FROM t;
|
||||||
|
SHOW CREATE VIEW v_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v_t` AS select `t`.`pk` AS `pk` from `t` latin1 latin1_swedish_ci
|
||||||
|
SELECT SHA(pk) IN (SELECT * FROM (SELECT '' FROM v_t) AS a) FROM v_t;
|
||||||
|
SHA(pk) IN (SELECT * FROM (SELECT '' FROM v_t) AS a)
|
||||||
|
0
|
||||||
|
0
|
||||||
|
0
|
||||||
|
SELECT * FROM (SELECT pk, '', '' as c1 FROM v_t) AS a;
|
||||||
|
pk c1
|
||||||
|
1
|
||||||
|
2
|
||||||
|
3
|
||||||
|
SELECT * FROM (SELECT '', '' from v_t) AS a;
|
||||||
|
ERROR 42S21: Duplicate column name ''
|
||||||
|
SELECT * FROM (SELECT '/', '/' from v_t) AS a;
|
||||||
|
ERROR 42S21: Duplicate column name '/'
|
||||||
|
CREATE VIEW v1 AS SELECT '/', '/';
|
||||||
|
SHOW CREATE VIEW v1;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select '/' AS `/`,'/' AS `My_exp_/` latin1 latin1_swedish_ci
|
||||||
|
DROP VIEW v_t, v1;
|
||||||
|
DROP TABLE t;
|
||||||
|
# Tests on views created using SELECT statements that contain derived columns
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
CREATE VIEW v1_t AS SELECT '' FROM t;
|
||||||
|
SHOW CREATE VIEW v1_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v1_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1_t` AS select '' AS `Name_exp_1` from `t` latin1 latin1_swedish_ci
|
||||||
|
SELECT * FROM v1_t;
|
||||||
|
Name_exp_1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
CREATE VIEW v2_t AS SELECT * FROM (SELECT '' FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v2_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v2_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v2_t` AS select `tmp_field` AS `Name_exp_1` from (select '' from `t`) `a` latin1 latin1_swedish_ci
|
||||||
|
Warnings:
|
||||||
|
Warning 1356 View 'test.v2_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
SELECT * FROM v2_t;
|
||||||
|
ERROR HY000: View 'test.v2_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
CREATE VIEW v3_t AS SELECT * FROM (SELECT '' as c1 FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v3_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v3_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v3_t` AS select `a`.`c1` AS `c1` from (select '' AS `c1` from `t`) `a` latin1 latin1_swedish_ci
|
||||||
|
SELECT * FROM v3_t;
|
||||||
|
c1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
CREATE VIEW v4_t AS SELECT * FROM (SELECT 1, '' FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v4_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v4_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v4_t` AS select `a`.`1` AS `1`,`tmp_field` AS `Name_exp_2` from (select 1 AS `1`,'' from `t`) `a` latin1 latin1_swedish_ci
|
||||||
|
Warnings:
|
||||||
|
Warning 1356 View 'test.v4_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
SELECT * from v4_t;
|
||||||
|
ERROR HY000: View 'test.v4_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
CREATE VIEW v5_t AS SELECT '';
|
||||||
|
SHOW CREATE VIEW v5_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v5_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v5_t` AS select '' AS `Name_exp_1` latin1 latin1_swedish_ci
|
||||||
|
SELECT * FROM v5_t;
|
||||||
|
Name_exp_1
|
||||||
|
|
||||||
|
CREATE VIEW v6_t AS SELECT * FROM (SELECT '') AS a;
|
||||||
|
SHOW CREATE VIEW v6_t;
|
||||||
|
View Create View character_set_client collation_connection
|
||||||
|
v6_t CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v6_t` AS select `tmp_field` AS `Name_exp_1` from (select '') `a` latin1 latin1_swedish_ci
|
||||||
|
Warnings:
|
||||||
|
Warning 1356 View 'test.v6_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
SELECT * FROM v6_t;
|
||||||
|
ERROR HY000: View 'test.v6_t' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||||
|
DROP VIEW v1_t, v2_t, v3_t, v4_t, v5_t, v6_t;
|
||||||
|
DROP TABLE t;
|
||||||
|
# End of 10.11 tests
|
||||||
|
#
|
||||||
# Test of "Derived tables and union can now create distinct keys"
|
# Test of "Derived tables and union can now create distinct keys"
|
||||||
#
|
#
|
||||||
create table t1 (a int);
|
create table t1 (a int);
|
||||||
|
@ -1192,6 +1192,114 @@ drop table t1,t2,t3;
|
|||||||
--echo # End of 10.3 tests
|
--echo # End of 10.3 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-24588: Fix crash with unnamed column in derived table.
|
||||||
|
--echo # Assertion `item->name.str && item->name.str[0]` in
|
||||||
|
--echo # `TABLE_LIST::create_field_translation` fails when a SELECT
|
||||||
|
--echo # query includes a derived table containing unnamed column
|
||||||
|
--echo # (eg: `SELECT '' from t`).
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
--echo # Tests from the bug report
|
||||||
|
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
|
||||||
|
# this should pass withiout assertion fail in dbg or should not crash mariadb server
|
||||||
|
SELECT SHA(pk) IN (SELECT * FROM (SELECT '' FROM t) AS a) FROM t;
|
||||||
|
|
||||||
|
# The PREPARE command itself should succeed without crashing
|
||||||
|
SET sql_mode='';
|
||||||
|
PREPARE p FROM 'SELECT SHA(pk) IN (SELECT * FROM (SELECT \'\' FROM t) AS a) FROM t;';
|
||||||
|
|
||||||
|
EXECUTE p;
|
||||||
|
EXECUTE p;
|
||||||
|
|
||||||
|
DEALLOCATE PREPARE p;
|
||||||
|
|
||||||
|
--echo # Tests on derived tables
|
||||||
|
|
||||||
|
SELECT * FROM (SELECT 1, '' FROM t) AS a;
|
||||||
|
SELECT * FROM (SELECT '', 1 FROM t) AS a;
|
||||||
|
SELECT * FROM (SELECT 1, 2, '' FROM t) AS a;
|
||||||
|
SELECT * FROM (SELECT pk, '' FROM t) AS a;
|
||||||
|
SELECT '/', '/';
|
||||||
|
|
||||||
|
SELECT * FROM (SELECT pk, '', '' as c1 FROM t) AS a;
|
||||||
|
--error ER_DUP_FIELDNAME
|
||||||
|
SELECT * FROM (SELECT '', '' from t) AS a;
|
||||||
|
--error ER_DUP_FIELDNAME
|
||||||
|
SELECT * FROM (SELECT '/', '/' FROM t) AS a;
|
||||||
|
--error ER_DUP_FIELDNAME
|
||||||
|
SELECT * FROM (SELECT '/', '/') AS a;
|
||||||
|
|
||||||
|
DROP TABLE t;
|
||||||
|
|
||||||
|
--echo # Tests on views
|
||||||
|
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
|
||||||
|
CREATE VIEW v_t AS SELECT * FROM t;
|
||||||
|
SHOW CREATE VIEW v_t;
|
||||||
|
|
||||||
|
SELECT SHA(pk) IN (SELECT * FROM (SELECT '' FROM v_t) AS a) FROM v_t;
|
||||||
|
|
||||||
|
SELECT * FROM (SELECT pk, '', '' as c1 FROM v_t) AS a;
|
||||||
|
--error ER_DUP_FIELDNAME
|
||||||
|
SELECT * FROM (SELECT '', '' from v_t) AS a;
|
||||||
|
--error ER_DUP_FIELDNAME
|
||||||
|
SELECT * FROM (SELECT '/', '/' from v_t) AS a;
|
||||||
|
|
||||||
|
CREATE VIEW v1 AS SELECT '/', '/';
|
||||||
|
SHOW CREATE VIEW v1;
|
||||||
|
|
||||||
|
DROP VIEW v_t, v1;
|
||||||
|
DROP TABLE t;
|
||||||
|
|
||||||
|
--echo # Tests on views created using SELECT statements that contain derived columns
|
||||||
|
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY);
|
||||||
|
INSERT INTO t VALUES (1), (2), (3);
|
||||||
|
|
||||||
|
CREATE VIEW v1_t AS SELECT '' FROM t;
|
||||||
|
SHOW CREATE VIEW v1_t;
|
||||||
|
|
||||||
|
SELECT * FROM v1_t;
|
||||||
|
|
||||||
|
CREATE VIEW v2_t AS SELECT * FROM (SELECT '' FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v2_t;
|
||||||
|
|
||||||
|
--error ER_VIEW_INVALID
|
||||||
|
SELECT * FROM v2_t;
|
||||||
|
|
||||||
|
CREATE VIEW v3_t AS SELECT * FROM (SELECT '' as c1 FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v3_t;
|
||||||
|
|
||||||
|
SELECT * FROM v3_t;
|
||||||
|
|
||||||
|
CREATE VIEW v4_t AS SELECT * FROM (SELECT 1, '' FROM t) AS a;
|
||||||
|
SHOW CREATE VIEW v4_t;
|
||||||
|
|
||||||
|
--error ER_VIEW_INVALID
|
||||||
|
SELECT * from v4_t;
|
||||||
|
|
||||||
|
CREATE VIEW v5_t AS SELECT '';
|
||||||
|
SHOW CREATE VIEW v5_t;
|
||||||
|
|
||||||
|
SELECT * FROM v5_t;
|
||||||
|
|
||||||
|
CREATE VIEW v6_t AS SELECT * FROM (SELECT '') AS a;
|
||||||
|
SHOW CREATE VIEW v6_t;
|
||||||
|
|
||||||
|
--error ER_VIEW_INVALID
|
||||||
|
SELECT * FROM v6_t;
|
||||||
|
|
||||||
|
DROP VIEW v1_t, v2_t, v3_t, v4_t, v5_t, v6_t;
|
||||||
|
DROP TABLE t;
|
||||||
|
|
||||||
|
--echo # End of 10.11 tests
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # Test of "Derived tables and union can now create distinct keys"
|
--echo # Test of "Derived tables and union can now create distinct keys"
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -1063,3 +1063,113 @@ NULL INTERSECT RESULT <intersect2,3> ALL NULL NULL NULL NULL NULL NULL
|
|||||||
Warnings:
|
Warnings:
|
||||||
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a` from `test`.`t1` where `test`.`t1`.`a` > 4 union all /* select#4 */ select `__4`.`a` AS `a` from (/* select#2 */ select `test`.`t2`.`a` AS `a` from `test`.`t2` where `test`.`t2`.`a` < 5 intersect all /* select#3 */ select `test`.`t3`.`a` AS `a` from `test`.`t3` where `test`.`t3`.`a` < 5) `__4`
|
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a` from `test`.`t1` where `test`.`t1`.`a` > 4 union all /* select#4 */ select `__4`.`a` AS `a` from (/* select#2 */ select `test`.`t2`.`a` AS `a` from `test`.`t2` where `test`.`t2`.`a` < 5 intersect all /* select#3 */ select `test`.`t3`.`a` AS `a` from `test`.`t3` where `test`.`t3`.`a` < 5) `__4`
|
||||||
drop table t1,t2,t3;
|
drop table t1,t2,t3;
|
||||||
|
#
|
||||||
|
# MDEV-25158 Segfault on INTERSECT ALL with UNION in Oracle mode
|
||||||
|
#
|
||||||
|
create table t3 (x int);
|
||||||
|
create table u3 (x int);
|
||||||
|
create table i3 (x int);
|
||||||
|
explain SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
id select_type table type possible_keys key key_len ref rows Extra
|
||||||
|
1 PRIMARY t3 system NULL NULL NULL NULL 0 Const row not found
|
||||||
|
4 UNION <derived2> ALL NULL NULL NULL NULL 2
|
||||||
|
2 DERIVED NULL NULL NULL NULL NULL NULL NULL no matching row in const table
|
||||||
|
3 INTERSECT NULL NULL NULL NULL NULL NULL NULL no matching row in const table
|
||||||
|
NULL INTERSECT RESULT <intersect2,3> ALL NULL NULL NULL NULL NULL
|
||||||
|
NULL UNION RESULT <union1,4> ALL NULL NULL NULL NULL NULL
|
||||||
|
set sql_mode= 'oracle';
|
||||||
|
explain SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
id select_type table type possible_keys key key_len ref rows Extra
|
||||||
|
1 PRIMARY t3 system NULL NULL NULL NULL 0 Const row not found
|
||||||
|
2 UNION u3 system NULL NULL NULL NULL 0 Const row not found
|
||||||
|
3 INTERSECT i3 system NULL NULL NULL NULL 0 Const row not found
|
||||||
|
NULL UNIT RESULT <unit1,2,3> ALL NULL NULL NULL NULL NULL
|
||||||
|
select * from t3 union select * from u3 intersect select * from i3;
|
||||||
|
x
|
||||||
|
SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
x
|
||||||
|
insert into t3 values (0);
|
||||||
|
insert into i3 values (0);
|
||||||
|
Select * from t3 union select * from u3 intersect select * from i3;
|
||||||
|
x
|
||||||
|
0
|
||||||
|
SELECT * FROM t3 UNION SELECT * FROM u3 INTERSECT ALL SELECT * FROM i3;
|
||||||
|
x
|
||||||
|
0
|
||||||
|
drop tables t3, u3, i3;
|
||||||
|
# First line of these results is column names, not the result
|
||||||
|
# (pay attention to "affected rows")
|
||||||
|
values (1, 2) union all values (1, 2);
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
affected rows: 2
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3);
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
4 3
|
||||||
|
4 3
|
||||||
|
affected rows: 3
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3) union all values (1, 2);
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
4 3
|
||||||
|
4 3
|
||||||
|
1 2
|
||||||
|
affected rows: 4
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3) union all values (1, 2) union values (1, 2);
|
||||||
|
1 2
|
||||||
|
1 2
|
||||||
|
4 3
|
||||||
|
affected rows: 2
|
||||||
|
create table t1 (a int, b int);
|
||||||
|
create table t2 like t1;
|
||||||
|
insert t1 values (1, 2), (1, 2), (1, 2), (2, 3), (2, 3), (3, 4), (3, 4);
|
||||||
|
insert t2 values (1, 2), (1, 2), (2, 3), (2, 3), (2, 3), (2, 3), (4, 5);
|
||||||
|
select * from t1 intersect select * from t2;
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
select * from t1 intersect all select * from t2;
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
# Default: first INTERSECT ALL, then UNION
|
||||||
|
# Oracle: first UNION, then INTERSECT ALL
|
||||||
|
select * from t1 union values (1, 2) intersect all select * from t2;
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
select * from t1 union (values (1, 2) intersect all select * from t2);
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
3 4
|
||||||
|
(select * from t1 union values (1, 2)) intersect all select * from t2;
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
select * from t1 intersect all select * from t2 union values (1, 2);
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
select * from t1 intersect all (select * from t2 union values (1, 2));
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
(select * from t1 intersect all select * from t2) union values (1, 2);
|
||||||
|
a b
|
||||||
|
1 2
|
||||||
|
2 3
|
||||||
|
explain select * from t1 intersect all select * from t2 union values (1, 2);
|
||||||
|
id select_type table type possible_keys key key_len ref rows Extra
|
||||||
|
1 PRIMARY t1 ALL NULL NULL NULL NULL 7
|
||||||
|
2 INTERSECT t2 ALL NULL NULL NULL NULL 7
|
||||||
|
3 UNION NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||||
|
NULL UNIT RESULT <unit1,2,3> ALL NULL NULL NULL NULL NULL
|
||||||
|
drop tables t1, t2;
|
||||||
|
set sql_mode= default;
|
||||||
|
@ -328,3 +328,69 @@ intersect all
|
|||||||
select * from t3 where a < 5;
|
select * from t3 where a < 5;
|
||||||
|
|
||||||
drop table t1,t2,t3;
|
drop table t1,t2,t3;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-25158 Segfault on INTERSECT ALL with UNION in Oracle mode
|
||||||
|
--echo #
|
||||||
|
create table t3 (x int);
|
||||||
|
create table u3 (x int);
|
||||||
|
create table i3 (x int);
|
||||||
|
explain SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
set sql_mode= 'oracle';
|
||||||
|
explain SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
select * from t3 union select * from u3 intersect select * from i3;
|
||||||
|
SELECT * from t3 union select * from u3 intersect all select * from i3;
|
||||||
|
insert into t3 values (0);
|
||||||
|
insert into i3 values (0);
|
||||||
|
Select * from t3 union select * from u3 intersect select * from i3;
|
||||||
|
SELECT * FROM t3 UNION SELECT * FROM u3 INTERSECT ALL SELECT * FROM i3;
|
||||||
|
drop tables t3, u3, i3;
|
||||||
|
|
||||||
|
--enable_info
|
||||||
|
--echo # First line of these results is column names, not the result
|
||||||
|
--echo # (pay attention to "affected rows")
|
||||||
|
|
||||||
|
# MSSQL:
|
||||||
|
# 1 2
|
||||||
|
# 1 2
|
||||||
|
values (1, 2) union all values (1, 2);
|
||||||
|
|
||||||
|
# MSSQL:
|
||||||
|
# 1 2
|
||||||
|
# 4 3
|
||||||
|
# 4 3
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3);
|
||||||
|
|
||||||
|
# MSSQL:
|
||||||
|
# 1 2
|
||||||
|
# 4 3
|
||||||
|
# 4 3
|
||||||
|
# 1 2
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3) union all values (1, 2);
|
||||||
|
|
||||||
|
# MSSQL:
|
||||||
|
# 1 2
|
||||||
|
# 4 3
|
||||||
|
values (1, 2) union all values (1, 2) union values (4, 3) union all values (4, 3) union all values (1, 2) union values (1, 2);
|
||||||
|
--disable_info
|
||||||
|
|
||||||
|
create table t1 (a int, b int);
|
||||||
|
create table t2 like t1;
|
||||||
|
insert t1 values (1, 2), (1, 2), (1, 2), (2, 3), (2, 3), (3, 4), (3, 4);
|
||||||
|
insert t2 values (1, 2), (1, 2), (2, 3), (2, 3), (2, 3), (2, 3), (4, 5);
|
||||||
|
select * from t1 intersect select * from t2;
|
||||||
|
select * from t1 intersect all select * from t2;
|
||||||
|
--echo # Default: first INTERSECT ALL, then UNION
|
||||||
|
--echo # Oracle: first UNION, then INTERSECT ALL
|
||||||
|
# VIEW is stored and executed normal mode (see Sql_mode_save_for_frm_handling)
|
||||||
|
--disable_view_protocol
|
||||||
|
select * from t1 union values (1, 2) intersect all select * from t2;
|
||||||
|
--enable_view_protocol
|
||||||
|
select * from t1 union (values (1, 2) intersect all select * from t2);
|
||||||
|
(select * from t1 union values (1, 2)) intersect all select * from t2;
|
||||||
|
select * from t1 intersect all select * from t2 union values (1, 2);
|
||||||
|
select * from t1 intersect all (select * from t2 union values (1, 2));
|
||||||
|
(select * from t1 intersect all select * from t2) union values (1, 2);
|
||||||
|
explain select * from t1 intersect all select * from t2 union values (1, 2);
|
||||||
|
drop tables t1, t2;
|
||||||
|
set sql_mode= default;
|
||||||
|
5
mysql-test/main/join_cache_notasan.cnf
Normal file
5
mysql-test/main/join_cache_notasan.cnf
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
!include include/default_my.cnf
|
||||||
|
|
||||||
|
[ENV]
|
||||||
|
MSAN_OPTIONS=allocator_may_return_null=1:abort_on_error=1
|
||||||
|
|
@ -1,3 +1,4 @@
|
|||||||
|
call mtr.add_suppression("MemorySanitizer failed to allocate");
|
||||||
#
|
#
|
||||||
# MDEV-28217 Incorrect Join Execution When Controlling Join Buffer Size
|
# MDEV-28217 Incorrect Join Execution When Controlling Join Buffer Size
|
||||||
#
|
#
|
||||||
|
@ -4,11 +4,13 @@
|
|||||||
--source include/have_64bit.inc
|
--source include/have_64bit.inc
|
||||||
# Disable asan it asan builds crashes when trying to allocate too much memory
|
# Disable asan it asan builds crashes when trying to allocate too much memory
|
||||||
--source include/not_asan.inc
|
--source include/not_asan.inc
|
||||||
--source include/not_msan.inc
|
|
||||||
# Valgrind is useful here, but very slow as lots of memory is allocated
|
# Valgrind is useful here, but very slow as lots of memory is allocated
|
||||||
--source include/no_valgrind_without_big.inc
|
--source include/no_valgrind_without_big.inc
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
|
|
||||||
|
# MSAN runs, but ignore its notice. ER_OUTOFMEMORY is expected by tests
|
||||||
|
call mtr.add_suppression("MemorySanitizer failed to allocate");
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # MDEV-28217 Incorrect Join Execution When Controlling Join Buffer Size
|
--echo # MDEV-28217 Incorrect Join Execution When Controlling Join Buffer Size
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -770,4 +770,42 @@ alter table t1 add constraint constraint_1 unique (a);
|
|||||||
Warnings:
|
Warnings:
|
||||||
Note 1831 Duplicate index `constraint_1`. This is deprecated and will be disallowed in a future release
|
Note 1831 Duplicate index `constraint_1`. This is deprecated and will be disallowed in a future release
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
#
|
||||||
|
# MDEV-33675 assertion(reclength < vreclength) in setup_vcols_for_repair()
|
||||||
|
#
|
||||||
|
create table t (c1 bit, unique key(c1) using hash) engine=myisam;
|
||||||
|
insert into t values (0);
|
||||||
|
check table t;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t check status OK
|
||||||
|
insert into t values();
|
||||||
|
select cast(c1 as unsigned) c1 from t;
|
||||||
|
c1
|
||||||
|
0
|
||||||
|
NULL
|
||||||
|
drop table t;
|
||||||
|
create table t1 (c1 bit, c2 long as (c1) virtual, c3 char(10),
|
||||||
|
c4 long as (c1) stored) engine=myisam;
|
||||||
|
insert into t1 (c1, c3) values (1, "a");
|
||||||
|
check table t1;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 check status OK
|
||||||
|
insert into t1 values();
|
||||||
|
select hex(c1), hex(c2), c3, hex(c4) from t1;
|
||||||
|
hex(c1) hex(c2) c3 hex(c4)
|
||||||
|
1 01 a 01
|
||||||
|
NULL NULL NULL NULL
|
||||||
|
drop table t1;
|
||||||
|
create table t1 (c1 bit, c2 long as (c1) virtual, c3 char(10),
|
||||||
|
c4 long as (c1) stored) engine=aria;
|
||||||
|
insert into t1 (c1, c3) values (1, "a");
|
||||||
|
check table t1;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 check status OK
|
||||||
|
insert into t1 values();
|
||||||
|
select hex(c1), hex(c2), c3, hex(c4) from t1;
|
||||||
|
hex(c1) hex(c2) c3 hex(c4)
|
||||||
|
1 01 a 01
|
||||||
|
NULL NULL NULL NULL
|
||||||
|
drop table t1;
|
||||||
# End of 10.5 tests
|
# End of 10.5 tests
|
||||||
|
@ -745,4 +745,30 @@ create table t1 (a blob unique);
|
|||||||
alter table t1 add constraint constraint_1 unique (a);
|
alter table t1 add constraint constraint_1 unique (a);
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-33675 assertion(reclength < vreclength) in setup_vcols_for_repair()
|
||||||
|
--echo #
|
||||||
|
create table t (c1 bit, unique key(c1) using hash) engine=myisam;
|
||||||
|
insert into t values (0);
|
||||||
|
check table t;
|
||||||
|
insert into t values();
|
||||||
|
select cast(c1 as unsigned) c1 from t;
|
||||||
|
drop table t;
|
||||||
|
|
||||||
|
create table t1 (c1 bit, c2 long as (c1) virtual, c3 char(10),
|
||||||
|
c4 long as (c1) stored) engine=myisam;
|
||||||
|
insert into t1 (c1, c3) values (1, "a");
|
||||||
|
check table t1;
|
||||||
|
insert into t1 values();
|
||||||
|
select hex(c1), hex(c2), c3, hex(c4) from t1;
|
||||||
|
drop table t1;
|
||||||
|
|
||||||
|
create table t1 (c1 bit, c2 long as (c1) virtual, c3 char(10),
|
||||||
|
c4 long as (c1) stored) engine=aria;
|
||||||
|
insert into t1 (c1, c3) values (1, "a");
|
||||||
|
check table t1;
|
||||||
|
insert into t1 values();
|
||||||
|
select hex(c1), hex(c2), c3, hex(c4) from t1;
|
||||||
|
drop table t1;
|
||||||
|
|
||||||
--echo # End of 10.5 tests
|
--echo # End of 10.5 tests
|
||||||
|
@ -16,6 +16,10 @@ The following specify which files/extra groups are read (specified before remain
|
|||||||
--alter-algorithm[=name]
|
--alter-algorithm[=name]
|
||||||
Specify the alter table algorithm. One of: DEFAULT, COPY,
|
Specify the alter table algorithm. One of: DEFAULT, COPY,
|
||||||
INPLACE, NOCOPY, INSTANT
|
INPLACE, NOCOPY, INSTANT
|
||||||
|
--analyze-max-length=#
|
||||||
|
Fields which length in bytes more than this are skipped
|
||||||
|
by ANALYZE TABLE PERSISTENT unless explicitly listed in
|
||||||
|
the FOR COLUMNS () clause
|
||||||
--analyze-sample-percentage=#
|
--analyze-sample-percentage=#
|
||||||
Percentage of rows from the table ANALYZE TABLE will
|
Percentage of rows from the table ANALYZE TABLE will
|
||||||
sample to collect table statistics. Set to 0 to let
|
sample to collect table statistics. Set to 0 to let
|
||||||
@ -2009,7 +2013,6 @@ thread-pool-oversubscribe 3
|
|||||||
thread-pool-prio-kickup-timer 1000
|
thread-pool-prio-kickup-timer 1000
|
||||||
thread-pool-priority auto
|
thread-pool-priority auto
|
||||||
thread-pool-stall-limit 500
|
thread-pool-stall-limit 500
|
||||||
thread-stack 299008
|
|
||||||
tmp-disk-table-size 18446744073709551615
|
tmp-disk-table-size 18446744073709551615
|
||||||
tmp-memory-table-size 16777216
|
tmp-memory-table-size 16777216
|
||||||
tmp-table-size 16777216
|
tmp-table-size 16777216
|
||||||
|
@ -20,7 +20,7 @@ exec $MYSQLD_BOOTSTRAP_CMD --symbolic-links=0 --log-bin=foo --lower-case-table-n
|
|||||||
|
|
||||||
perl;
|
perl;
|
||||||
# Variables which we don't want to display in the result file since
|
# Variables which we don't want to display in the result file since
|
||||||
# their paths may vary:
|
# their paths may vary or they may use a default of 4294967295 :
|
||||||
@skipvars=qw/basedir open-files-limit general-log-file log plugin-dir plugin-maturity
|
@skipvars=qw/basedir open-files-limit general-log-file log plugin-dir plugin-maturity
|
||||||
log-slow-queries pid-file slow-query-log-file log-basename
|
log-slow-queries pid-file slow-query-log-file log-basename
|
||||||
log-slow-query-file
|
log-slow-query-file
|
||||||
@ -30,7 +30,7 @@ perl;
|
|||||||
table-open-cache table-open-cache-instances max-connections
|
table-open-cache table-open-cache-instances max-connections
|
||||||
server-uid tls-version version.* password-reuse-check
|
server-uid tls-version version.* password-reuse-check
|
||||||
provider-bzip2 provider-lzma provider-lzo
|
provider-bzip2 provider-lzma provider-lzo
|
||||||
password-reuse-check-interval/;
|
password-reuse-check-interval analyze-max-length thread-stack/;
|
||||||
|
|
||||||
# Plugins which may or may not be there:
|
# Plugins which may or may not be there:
|
||||||
@plugins=qw/innodb archive blackhole federated partition s3
|
@plugins=qw/innodb archive blackhole federated partition s3
|
||||||
|
@ -192,12 +192,6 @@ select * from v1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -363,12 +357,6 @@ select * from (select * from t1 where t1.a=1)q {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -651,19 +639,6 @@ select * from v2 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 2,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -808,12 +783,6 @@ explain select * from v2 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -1057,19 +1026,6 @@ explain select * from v1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 2,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -1395,12 +1351,6 @@ explain select * from t1,t2 where t1.a=t2.b+2 and t2.a= t1.b {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -1580,12 +1530,6 @@ EXPLAIN SELECT DISTINCT a FROM t1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -1836,12 +1780,6 @@ set statement optimizer_scan_setup_cost=0 for EXPLAIN SELECT MIN(d) FROM t1 wher
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -2068,12 +2006,6 @@ EXPLAIN SELECT id,MIN(a),MAX(a) FROM t1 WHERE a>=20010104e0 GROUP BY id {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -2277,12 +2209,6 @@ EXPLAIN SELECT * FROM t1 WHERE a = 20010104e0 GROUP BY id {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -2677,12 +2603,6 @@ explain select * from t1 where a=1 and b=2 order by c limit 1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -2862,12 +2782,6 @@ select t1.a from t1 left join t2 on t1.a=t2.a {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -3078,12 +2992,6 @@ explain select * from t1 left join t2 on t2.a=t1.a {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -3270,12 +3178,6 @@ explain select t1.a from t1 left join (t2 join t3 on t2.b=t3.b) on t2.a=t1.a and
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -3653,12 +3555,6 @@ explain extended select * from t1 where a in (select p from t2) {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -4029,12 +3925,6 @@ explain select * from t1 where pk = 2 and a=5 and b=1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -4170,12 +4060,6 @@ select f1(a) from t1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -4287,12 +4171,6 @@ select f2(a) from t1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -4313,7 +4191,7 @@ a
|
|||||||
2
|
2
|
||||||
select length(trace) from INFORMATION_SCHEMA.OPTIMIZER_TRACE;
|
select length(trace) from INFORMATION_SCHEMA.OPTIMIZER_TRACE;
|
||||||
length(trace)
|
length(trace)
|
||||||
2819
|
2728
|
||||||
set optimizer_trace_max_mem_size=100;
|
set optimizer_trace_max_mem_size=100;
|
||||||
select * from t1;
|
select * from t1;
|
||||||
a
|
a
|
||||||
@ -4327,7 +4205,7 @@ select * from t1 {
|
|||||||
"join_preparation": {
|
"join_preparation": {
|
||||||
"select_id": 1,
|
"select_id": 1,
|
||||||
"steps": [
|
"steps": [
|
||||||
2719 0
|
2628 0
|
||||||
set optimizer_trace_max_mem_size=0;
|
set optimizer_trace_max_mem_size=0;
|
||||||
select * from t1;
|
select * from t1;
|
||||||
a
|
a
|
||||||
@ -4335,7 +4213,7 @@ a
|
|||||||
2
|
2
|
||||||
select * from INFORMATION_SCHEMA.OPTIMIZER_TRACE;
|
select * from INFORMATION_SCHEMA.OPTIMIZER_TRACE;
|
||||||
QUERY TRACE MISSING_BYTES_BEYOND_MAX_MEM_SIZE INSUFFICIENT_PRIVILEGES
|
QUERY TRACE MISSING_BYTES_BEYOND_MAX_MEM_SIZE INSUFFICIENT_PRIVILEGES
|
||||||
select * from t1 2819 0
|
select * from t1 2728 0
|
||||||
drop table t1;
|
drop table t1;
|
||||||
set optimizer_trace='enabled=off';
|
set optimizer_trace='enabled=off';
|
||||||
set @@optimizer_trace_max_mem_size= @save_optimizer_trace_max_mem_size;
|
set @@optimizer_trace_max_mem_size= @save_optimizer_trace_max_mem_size;
|
||||||
@ -4857,12 +4735,6 @@ explain delete t0,t1 from t0, t1 where t0.a=t1.a and t1.a<3 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -5086,19 +4958,6 @@ explain select * from (select rand() from t1)q {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 2,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -5684,12 +5543,6 @@ explain select * from t1 where a in (select t_inner_1.a from t1 t_inner_1, t1 t_
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -8091,12 +7944,6 @@ t_outer_2.a in (select t_inner_3.a from t2 t_inner_3, t1 t_inner_4) {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -10521,12 +10368,6 @@ t_outer_2.a in (select t_inner_3.a from t2 t_inner_3, t1 t_inner_4) {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -11750,12 +11591,6 @@ SELECT 'a\0' LIMIT 0 {
|
|||||||
"select_id": 1,
|
"select_id": 1,
|
||||||
"steps": []
|
"steps": []
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -12141,115 +11976,90 @@ UPDATE t, v SET t.b = t.a, t.a = v.c WHERE v.c < t.a {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"join_execution": {
|
"join_optimization": {
|
||||||
"select_id": 1,
|
"select_id": "fake",
|
||||||
"steps": [
|
"steps": [
|
||||||
{
|
{
|
||||||
"join_execution": {
|
"table_dependencies": [
|
||||||
"select_id": 2,
|
{
|
||||||
"steps": []
|
"table": "union",
|
||||||
}
|
"row_may_be_null": false,
|
||||||
|
"map_bit": 0,
|
||||||
|
"depends_on_map_bits": []
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"join_execution": {
|
"rows_estimation": [
|
||||||
"select_id": 3,
|
{
|
||||||
"steps": []
|
"table": "union",
|
||||||
}
|
"table_scan": {
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_optimization": {
|
|
||||||
"select_id": "fake",
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"table_dependencies": [
|
|
||||||
{
|
|
||||||
"table": "union",
|
|
||||||
"row_may_be_null": false,
|
|
||||||
"map_bit": 0,
|
|
||||||
"depends_on_map_bits": []
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"rows_estimation": [
|
|
||||||
{
|
|
||||||
"table": "union",
|
|
||||||
"table_scan": {
|
|
||||||
"rows": 2,
|
|
||||||
"read_cost": 0.010020701,
|
|
||||||
"read_and_compare_cost": 0.010084701
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"considered_execution_plans": [
|
|
||||||
{
|
|
||||||
"plan_prefix": "",
|
|
||||||
"get_costs_for_tables": [
|
|
||||||
{
|
|
||||||
"best_access_path": {
|
|
||||||
"table": "union",
|
|
||||||
"plan_details": {
|
|
||||||
"record_count": 1
|
|
||||||
},
|
|
||||||
"considered_access_paths": [
|
|
||||||
{
|
|
||||||
"access_type": "scan",
|
|
||||||
"rows": 2,
|
|
||||||
"rows_after_filter": 2,
|
|
||||||
"rows_out": 2,
|
|
||||||
"cost": 0.010084701,
|
|
||||||
"index_only": false,
|
|
||||||
"chosen": true
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"chosen_access_method": {
|
|
||||||
"type": "scan",
|
|
||||||
"rows_read": 2,
|
|
||||||
"rows_out": 2,
|
|
||||||
"cost": 0.010084701,
|
|
||||||
"uses_join_buffering": false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"plan_prefix": "",
|
|
||||||
"table": "union",
|
|
||||||
"rows_for_plan": 2,
|
|
||||||
"cost_for_plan": 0.010084701
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"best_join_order": ["union"],
|
|
||||||
"rows": 2,
|
"rows": 2,
|
||||||
"cost": 0.010084701
|
"read_cost": 0.010020701,
|
||||||
},
|
"read_and_compare_cost": 0.010084701
|
||||||
{
|
}
|
||||||
"attaching_conditions_to_tables": {
|
}
|
||||||
"attached_conditions_computation": [],
|
]
|
||||||
"attached_conditions_summary": [
|
},
|
||||||
{
|
{
|
||||||
"table": "union",
|
"considered_execution_plans": [
|
||||||
"attached_condition": null
|
{
|
||||||
|
"plan_prefix": "",
|
||||||
|
"get_costs_for_tables": [
|
||||||
|
{
|
||||||
|
"best_access_path": {
|
||||||
|
"table": "union",
|
||||||
|
"plan_details": {
|
||||||
|
"record_count": 1
|
||||||
|
},
|
||||||
|
"considered_access_paths": [
|
||||||
|
{
|
||||||
|
"access_type": "scan",
|
||||||
|
"rows": 2,
|
||||||
|
"rows_after_filter": 2,
|
||||||
|
"rows_out": 2,
|
||||||
|
"cost": 0.010084701,
|
||||||
|
"index_only": false,
|
||||||
|
"chosen": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"chosen_access_method": {
|
||||||
|
"type": "scan",
|
||||||
|
"rows_read": 2,
|
||||||
|
"rows_out": 2,
|
||||||
|
"cost": 0.010084701,
|
||||||
|
"uses_join_buffering": false
|
||||||
}
|
}
|
||||||
]
|
}
|
||||||
}
|
}
|
||||||
},
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"plan_prefix": "",
|
||||||
|
"table": "union",
|
||||||
|
"rows_for_plan": 2,
|
||||||
|
"cost_for_plan": 0.010084701
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"best_join_order": ["union"],
|
||||||
|
"rows": 2,
|
||||||
|
"cost": 0.010084701
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"attaching_conditions_to_tables": {
|
||||||
|
"attached_conditions_computation": [],
|
||||||
|
"attached_conditions_summary": [
|
||||||
{
|
{
|
||||||
"make_join_readinfo": []
|
"table": "union",
|
||||||
|
"attached_condition": null
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"join_execution": {
|
"make_join_readinfo": []
|
||||||
"select_id": "fake",
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -12504,12 +12314,6 @@ select count(*) from seq_1_to_10000000 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -13000,6 +12804,136 @@ left(trace, 100)
|
|||||||
set optimizer_trace='enabled=off';
|
set optimizer_trace='enabled=off';
|
||||||
# End of 10.6 tests
|
# End of 10.6 tests
|
||||||
#
|
#
|
||||||
|
# MDEV-36461: Remove join_execution nodes and add range_check_for_each_record when appropriate
|
||||||
|
#
|
||||||
|
create table t1 (a int, b int);
|
||||||
|
insert into t1 values (1, 999),(999, 1),(987,987);
|
||||||
|
create table t2 (a int, b int, index(a),index(b));
|
||||||
|
insert into t2 select seq, seq from seq_1_to_1000;
|
||||||
|
create table t3 (a int);
|
||||||
|
insert into t3 select seq from seq_1_to_2;
|
||||||
|
set optimizer_trace='enabled=on';
|
||||||
|
analyze
|
||||||
|
select
|
||||||
|
(
|
||||||
|
select count(*)
|
||||||
|
from t1, t2
|
||||||
|
where t2.a<t1.a and t2.b<t1.b and t2.b+t1.a>t3.a
|
||||||
|
) as SUBQ, a
|
||||||
|
from t3;
|
||||||
|
id select_type table type possible_keys key key_len ref rows r_rows filtered r_filtered Extra
|
||||||
|
1 PRIMARY t3 ALL NULL NULL NULL NULL 2 2.00 100.00 100.00
|
||||||
|
2 DEPENDENT SUBQUERY t1 ALL NULL NULL NULL NULL 3 3.00 100.00 100.00
|
||||||
|
2 DEPENDENT SUBQUERY t2 ALL a,b NULL NULL NULL 1000 333.33 100.00 98.60 Range checked for each record (index map: 0x3)
|
||||||
|
# The trace must contain 6 objects with select_id 2 and
|
||||||
|
# loop varying from 1..2 for each of the 3 ranges from t1:
|
||||||
|
set @trace=(select trace from information_schema.optimizer_trace);
|
||||||
|
set @trace=(select json_extract(@trace, '$**.range-checked-for-each-record'));
|
||||||
|
set @trace=json_replace(@trace, '$[0].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[1].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[2].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[3].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[4].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[5].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
select json_detailed(@trace) as TRACE;
|
||||||
|
TRACE
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 1,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 1,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 1,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 2,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 2,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"select_id": 2,
|
||||||
|
"loop": 2,
|
||||||
|
"rows_estimation":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"table": "t2",
|
||||||
|
"range_analysis": "REPLACED"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
# The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
NULL
|
||||||
|
select
|
||||||
|
(
|
||||||
|
select count(*)
|
||||||
|
from t1, t2
|
||||||
|
where t2.a+1<t1.a and t2.b+1<t1.b and t2.b+t1.a>t3.a
|
||||||
|
) as SUBQ, a
|
||||||
|
from t3;
|
||||||
|
SUBQ a
|
||||||
|
985 1
|
||||||
|
985 2
|
||||||
|
# The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.range-checked-for-each-record'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
json_detailed(json_extract(trace, '$**.range-checked-for-each-record'))
|
||||||
|
NULL
|
||||||
|
# The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
NULL
|
||||||
|
set optimizer_trace='enabled=off';
|
||||||
|
drop table t1,t2,t3;
|
||||||
|
# End of 10.11 tests
|
||||||
|
#
|
||||||
# Testing of records_out
|
# Testing of records_out
|
||||||
#
|
#
|
||||||
set @save_optimizer_switch= @@optimizer_switch;
|
set @save_optimizer_switch= @@optimizer_switch;
|
||||||
@ -13311,12 +13245,6 @@ explain select * from t1 where a<10 and b between 10 and 50 and c < 10 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -13783,12 +13711,6 @@ explain format=json select * from three, t1 where t1.a=three.a and t1.b<5000 and
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
|
@ -1167,6 +1167,62 @@ set optimizer_trace='enabled=off';
|
|||||||
|
|
||||||
--echo # End of 10.6 tests
|
--echo # End of 10.6 tests
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36461: Remove join_execution nodes and add range_check_for_each_record when appropriate
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
create table t1 (a int, b int);
|
||||||
|
insert into t1 values (1, 999),(999, 1),(987,987);
|
||||||
|
create table t2 (a int, b int, index(a),index(b));
|
||||||
|
insert into t2 select seq, seq from seq_1_to_1000;
|
||||||
|
create table t3 (a int);
|
||||||
|
insert into t3 select seq from seq_1_to_2;
|
||||||
|
|
||||||
|
set optimizer_trace='enabled=on';
|
||||||
|
|
||||||
|
analyze
|
||||||
|
select
|
||||||
|
(
|
||||||
|
select count(*)
|
||||||
|
from t1, t2
|
||||||
|
where t2.a<t1.a and t2.b<t1.b and t2.b+t1.a>t3.a
|
||||||
|
) as SUBQ, a
|
||||||
|
from t3;
|
||||||
|
|
||||||
|
--echo # The trace must contain 6 objects with select_id 2 and
|
||||||
|
--echo # loop varying from 1..2 for each of the 3 ranges from t1:
|
||||||
|
set @trace=(select trace from information_schema.optimizer_trace);
|
||||||
|
set @trace=(select json_extract(@trace, '$**.range-checked-for-each-record'));
|
||||||
|
set @trace=json_replace(@trace, '$[0].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[1].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[2].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[3].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[4].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
set @trace=json_replace(@trace, '$[5].rows_estimation[0].range_analysis','REPLACED');
|
||||||
|
select json_detailed(@trace) as TRACE;
|
||||||
|
|
||||||
|
--echo # The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
|
||||||
|
select
|
||||||
|
(
|
||||||
|
select count(*)
|
||||||
|
from t1, t2
|
||||||
|
where t2.a+1<t1.a and t2.b+1<t1.b and t2.b+t1.a>t3.a
|
||||||
|
) as SUBQ, a
|
||||||
|
from t3;
|
||||||
|
|
||||||
|
--echo # The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.range-checked-for-each-record'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
--echo # The trace must be empty:
|
||||||
|
select json_detailed(json_extract(trace, '$**.join_execution'))
|
||||||
|
from information_schema.optimizer_trace;
|
||||||
|
set optimizer_trace='enabled=off';
|
||||||
|
|
||||||
|
drop table t1,t2,t3;
|
||||||
|
--echo # End of 10.11 tests
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # Testing of records_out
|
--echo # Testing of records_out
|
||||||
@ -1271,4 +1327,3 @@ set @@optimizer_switch= @save_optimizer_switch;
|
|||||||
set @@use_stat_tables= @save_use_stat_tables;
|
set @@use_stat_tables= @save_use_stat_tables;
|
||||||
set @@histogram_size= @save_histogram_size;
|
set @@histogram_size= @save_histogram_size;
|
||||||
set @@optimizer_use_condition_selectivity= @save_optimizer_use_condition_selectivity;
|
set @@optimizer_use_condition_selectivity= @save_optimizer_use_condition_selectivity;
|
||||||
|
|
||||||
|
@ -272,12 +272,6 @@ explain select * from t1 where a=1 or b=1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
|
@ -277,12 +277,6 @@ explain select * from t1 where pk1 != 0 and key1 = 1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
|
@ -148,12 +148,6 @@ select * from db1.t1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
@ -290,12 +284,6 @@ select * from db1.v1 {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"join_execution": {
|
|
||||||
"select_id": 1,
|
|
||||||
"steps": []
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
} 0 0
|
} 0 0
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
--source include/big_test.inc
|
--source include/big_test.inc
|
||||||
# Test will take more than one hour with valgrind
|
# Test will take more than one hour with valgrind
|
||||||
--source include/not_valgrind.inc
|
--source include/not_valgrind.inc
|
||||||
--source include/not_msan.inc
|
--source include/not_msan_with_debug.inc
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
--source include/have_sequence.inc
|
--source include/have_sequence.inc
|
||||||
|
|
||||||
|
@ -1,26 +1,87 @@
|
|||||||
|
Certificate:
|
||||||
|
Data:
|
||||||
|
Version: 1 (0x0)
|
||||||
|
Serial Number: 4096 (0x1000)
|
||||||
|
Signature Algorithm: sha256WithRSAEncryption
|
||||||
|
Issuer: C=FI, ST=Helsinki, L=Helsinki, O=MariaDB, CN=Galera CA
|
||||||
|
Validity
|
||||||
|
Not Before: May 20 01:31:39 2025 GMT
|
||||||
|
Not After : May 20 01:31:39 2125 GMT
|
||||||
|
Subject:
|
||||||
|
Subject Public Key Info:
|
||||||
|
Public Key Algorithm: rsaEncryption
|
||||||
|
Public-Key: (2048 bit)
|
||||||
|
Modulus:
|
||||||
|
00:a5:04:b1:45:03:ef:44:cb:1f:31:0c:5d:87:60:
|
||||||
|
82:25:a8:f7:62:1f:a9:ed:82:06:67:23:6a:b0:0c:
|
||||||
|
59:3e:b7:c9:ec:17:16:e2:0b:55:06:49:26:82:e9:
|
||||||
|
d0:bb:82:a4:79:08:6d:93:2f:6b:a2:40:73:3a:77:
|
||||||
|
a0:e8:47:99:40:27:fa:d7:39:33:26:9c:3d:c5:0b:
|
||||||
|
82:ba:ea:48:71:53:18:0f:f6:47:a5:02:89:80:16:
|
||||||
|
68:77:33:d1:a2:bb:34:7f:38:ae:c4:cd:85:f1:8d:
|
||||||
|
84:e4:e3:dc:23:93:be:b3:93:bc:de:db:bb:67:6a:
|
||||||
|
ec:55:f6:6a:c0:bd:b5:18:6e:2e:15:06:a1:b9:f2:
|
||||||
|
fc:72:12:4d:fc:c1:5a:38:b2:30:17:c0:de:83:19:
|
||||||
|
4c:fc:9c:c5:0f:c2:b1:86:57:30:88:82:07:f7:ff:
|
||||||
|
96:68:1e:55:7c:18:3f:53:5e:40:20:06:02:a1:6e:
|
||||||
|
f7:03:4b:82:ea:9e:4f:07:97:03:33:d0:bf:1c:de:
|
||||||
|
b8:17:bf:7d:4c:3a:48:2d:41:ed:82:e6:3a:2c:6f:
|
||||||
|
4f:fd:b1:2d:33:ed:d6:36:8c:bc:f2:ff:52:af:aa:
|
||||||
|
32:9b:cf:87:45:f3:b3:61:d1:20:7d:03:a3:2f:1f:
|
||||||
|
6c:1d:f9:b8:41:e9:88:04:c1:ae:b9:23:36:80:59:
|
||||||
|
d1:4f
|
||||||
|
Exponent: 65537 (0x10001)
|
||||||
|
Signature Algorithm: sha256WithRSAEncryption
|
||||||
|
Signature Value:
|
||||||
|
a1:d1:8e:b3:3f:47:3a:4a:2c:f0:bf:34:72:69:99:f2:fa:a9:
|
||||||
|
a0:72:3c:7e:7a:69:c1:d6:97:4f:bd:44:ac:92:79:46:e4:8e:
|
||||||
|
62:c0:cd:41:e9:55:a7:29:33:d6:f6:e7:e5:13:e9:5a:a1:83:
|
||||||
|
85:16:cb:e2:38:9a:55:b1:57:51:ea:cc:ca:5c:46:ab:1d:a5:
|
||||||
|
73:d6:d6:df:57:e8:7c:40:16:63:17:75:b2:13:ac:31:eb:96:
|
||||||
|
85:3b:fb:92:d6:69:4d:ab:e2:1d:22:82:0f:71:66:8d:b0:a9:
|
||||||
|
56:a2:77:5e:f8:56:90:22:1f:ee:e7:79:33:37:c7:9f:a1:06:
|
||||||
|
01:35:fe:13:12:75:2e:d9:2a:04:e5:8f:21:4a:20:de:a5:07:
|
||||||
|
89:aa:0c:c2:d2:ec:a1:47:d6:f6:87:f7:ed:29:f9:69:c6:83:
|
||||||
|
f6:18:8d:7e:7e:3a:53:c7:b3:91:bd:9a:b8:e3:ac:66:de:57:
|
||||||
|
b8:2d:c5:d5:54:61:1b:27:96:e8:34:0d:a9:88:4f:03:5a:27:
|
||||||
|
e0:5f:b5:90:97:9f:57:39:f5:a9:9d:c6:b6:77:1a:bb:86:57:
|
||||||
|
57:0c:79:6e:66:5f:93:c1:f7:df:c8:06:3c:df:c5:f8:ef:b3:
|
||||||
|
e3:61:8b:15:8a:45:4f:db:1d:7f:2b:eb:c9:54:ba:6e:c8:b8:
|
||||||
|
40:ca:de:10:93:a9:a4:8c:17:56:50:37:9c:6b:ba:9c:b0:5f:
|
||||||
|
4c:49:a7:9c:ba:3c:81:37:e3:a2:b3:6a:71:b9:f6:a6:bb:81:
|
||||||
|
f3:5c:40:ae:f5:e1:68:32:e3:af:22:5b:88:aa:df:2e:3b:5d:
|
||||||
|
e2:63:ab:c7:01:a3:c8:3a:e1:06:9f:2f:d1:9f:b4:06:c4:11:
|
||||||
|
83:c2:99:4a:de:f0:c2:32:04:b8:65:26:e9:57:3f:7d:52:d7:
|
||||||
|
d8:1c:6e:2c:55:53:d3:81:1d:b9:9e:0a:c1:34:a6:6a:48:af:
|
||||||
|
3b:d9:6e:84:16:30:33:a6:10:17:36:b4:30:68:fd:95:e9:3e:
|
||||||
|
35:c3:95:71:7a:86:26:a7:46:66:09:95:91:c6:c2:ba:a6:61:
|
||||||
|
c2:a5:b6:38:8e:34:a0:14:f1:d7:0c:11:93:0a:a4:d3:f8:b7:
|
||||||
|
32:fd:12:38:64:9f:68:fe:3d:a1:f6:28:c1:c8:9f:1f:ea:a5:
|
||||||
|
e2:77:fd:ad:d9:21:22:40:b2:9e:8e:81:3f:79:0e:13:19:1e:
|
||||||
|
70:0f:4a:4b:81:ea:92:c5:fa:4f:80:e9:8f:5e:ac:dc:09:74:
|
||||||
|
70:e1:7b:23:68:0c:18:c7:7f:07:4a:39:42:29:d6:c3:62:16:
|
||||||
|
ec:15:73:02:93:a6:a3:5f:21:90:59:8e:e6:b1:0a:be:32:cf:
|
||||||
|
6d:4e:7e:56:3d:87:13:0f
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
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
|
||||||
|
o18hkFmO5rEKvjLPbU5+Vj2HEw8=
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
-----BEGIN DH PARAMETERS-----
|
|
||||||
MIGHAoGBAJWyvKjE+s7OP4Lj1jXKGlJGWT4Vd5YaxPljihTsRe1aXkWAgsuwISXk
|
|
||||||
/TQ8Rx5Zmze7rtwtU0PoYxvuam9FMXYqhw2dVe4qRdeSX78DSiL/YBkQzaxlfWVy
|
|
||||||
RE9+9dzHbCtRVDlN7K1kA+mGWH4/r7NAu4Qm/003V0NTtMwQSqebAgEC
|
|
||||||
-----END DH PARAMETERS-----
|
|
||||||
|
|
||||||
|
@ -1,28 +1,28 @@
|
|||||||
-----BEGIN PRIVATE KEY-----
|
-----BEGIN PRIVATE KEY-----
|
||||||
MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDDzU6xLZDD5rZE
|
MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQClBLFFA+9Eyx8x
|
||||||
NsOpTpTmqS8YisBaefU3ZeN7VJepZZ/7unM/1YLGJtuRh2QaMyTkvyjzf7bSFsDt
|
DF2HYIIlqPdiH6ntggZnI2qwDFk+t8nsFxbiC1UGSSaC6dC7gqR5CG2TL2uiQHM6
|
||||||
9L5lfQwBBblVeWkrCvGnQmHDQQYB7JrSmFDPz9W9Mxf9Q2BWB3lcoKXXJgMnWw0W
|
d6DoR5lAJ/rXOTMmnD3FC4K66khxUxgP9kelAomAFmh3M9GiuzR/OK7EzYXxjYTk
|
||||||
Grt0lEdFp9gWbq8H9hwJdjpyyk4ZTIuucSOD4JUP3QFEhYU5kdcIbDRVw81J4eAZ
|
49wjk76zk7ze27tnauxV9mrAvbUYbi4VBqG58vxyEk38wVo4sjAXwN6DGUz8nMUP
|
||||||
6EdvbjDN05S7qWjW7rJTnCHAHEd18hcsMGwjpwhjEaSdhMrMmhOeL8kuQV0fI8v2
|
wrGGVzCIggf3/5ZoHlV8GD9TXkAgBgKhbvcDS4Lqnk8HlwMz0L8c3rgXv31MOkgt
|
||||||
xfYBliIn9xBZGOVzySPzwFmQceORlW6F3V5w6mwFkmuXqXWXQo98swTu7mb89qVY
|
Qe2C5josb0/9sS0z7dY2jLzy/1KvqjKbz4dF87Nh0SB9A6MvH2wd+bhB6YgEwa65
|
||||||
mR71d3L3AgMBAAECggEBAIMT0UdZSp1quL/nrYqNGa9kuSuDz4uCM3+3jNcGZVU4
|
IzaAWdFPAgMBAAECggEAT55ae46g8MPCWnN5YvqNAOer6IOXhPlh5nx/ms5yduDN
|
||||||
vCYHxpmINLi0UK8W5ROJA3zC4AZKjDgOlW93NXK5iKyyiUTIN3hiJi4jiVDuGbh2
|
Q6SGTW0jSmOb+bkflYE8owsOd1//YisPjauvjrMQ/ZPsotA93kivQvXBTzb/2fG6
|
||||||
DZtH7mmAKAU1zCx2y2osLLmurfbe8qOJF7ShhrZfgWsHFujFhhUdU92dsTkhZ7EU
|
H+V3fuWg+xSUtcLiSE5jz2hFZr40/K2H67oG+oFsFw/Wpn5FRuofeoBo1HMTv+OO
|
||||||
2NF8ScxCo4PbOJoHC3j0ApfwCMxUMAKZF5+08EeKYqK7OAXI79HeIvEbHn3cUDGm
|
8JvDGOC3jNBxqvajf2+YTpHkS2Bm0CujlspMv+LYYJm4kjlmaE+PEKGAqp+WT+rK
|
||||||
bvg6ykwlz2UUO4sg+xdCmn1Bt36HF/4e973Y5fkE/vd9mryHIlu9t7GJgWyUiPr8
|
10HXYQGsOLld3DVfO0aHJQ+ji5WskTtmJxi/Gutra2BL7upiPByvdInCBFL5WObw
|
||||||
BGEoAWDSpPOMd/b9ivtxh9Gd+LW/uitMuBIfrRPgz9kCgYEA+JqeeD2xqF2IzZyq
|
1gQCYZeUgD0Djofmk4Jst8M7fU/v8HDTgyMzy544EQKBgQDOVXuS3wkxz5QqKAt9
|
||||||
i1UqgKe3su2U2zhkgbu1h/1M/reNIZGylF0wFs3P+kNIB2NavmHjXcgSjdJzqRL9
|
js8nAb+M9w84cCn89hLZN60IBBWb933EtRun5M6Izy7PWRnSUH4Oeao9cGU1GsKQ
|
||||||
XEWfFJRmeARo9RTEQEVd8zp1Eo8ISeiksGgvbL4rrNIRR5V5MZytfISRiGCWN6jx
|
AuTLJKfbNVCrYo5dTpRDpK1zgRaiT2IPn8Wi337qP89dcb0NPXpWkzrkmhZJ3C6t
|
||||||
ulJ6EieQk5EcvknGlWpJY/bBsQ0CgYEAyaCLqrR38gVl2Z0t6YlhW/HWAwGt+lf4
|
YkvDp8jhunudCpisWsA5cDGmcQKBgQDMvUyI7wyukMt+VDIi1tnzJgJlezXRRCCH
|
||||||
apN1AS4uykx7wRW2B0y9QUDfsrYeVlbbeRPP4UzPmJez+J2cweoIIeFFyo3KP2L7
|
MO1qMSAn0UIIp/9nR41mdj9gQJby1uc+eL5eLY/KTjZgU9NTOhJ3ZT/GkvoR9xQt
|
||||||
79E3EVYywjXhPg52F7OjFA4Bp970XclIC5Al7kDufSgwZmWdceSx4Jjc5ixyQEC8
|
yZfWz8117OXoJxMgfUITKijtlQSCY4i3kAcA+bEerFIW+6xtNXzte5Q+LH/knmbh
|
||||||
Ad0ThgP6yxMCgYAvC4OFmZcvF1Q2JLmZWGqMojB/KbqLqaZLbqwxqduSMEYC3kF/
|
HmC689hTvwKBgERRwa0L9LtthB3BTKyyUJ0V0xsV4xBI814zDGKoML7qu0z9UcOE
|
||||||
FgttpVEAOQ8+ZqzbbkbKjnwEXpkIm9FaTsqF6HdjquH5zw48Y2QeDSfudSbKZb4U
|
RDf/ZvOdxl4Znpco19RrLJdTU++VgL62dpNc+8d1i9RzubfjgOw05snMAHaV2l5a
|
||||||
rAKdf3dgYvhmJYEjxFSIRcYMmsqSieQEsGrtWJNheYqI8AkmaVCuHBoXWQKBgQCj
|
BNK9NgTSRBMoyfRMWum3rlRrQN4L7dizJ2sNb1JusOd6zrqjAesC3y3BAoGAAdlz
|
||||||
daelNffD2wJuQNI28axfiRjSiSsNuQHpDTCfS1ydnxH5QGu5UUphO4HfdWv03SfC
|
54jBRJJqRCneihIGxfuB6gjC47EJ2i7G9j6bW8C4J/vcgsJStKo8yFHNC0SFsjrE
|
||||||
6f/vDIGEmQBLvyOVxfDf3qzhAMCFUO8kxj1ZrcMq1dmMoNa2cmj0WkKXYNZFrmfd
|
/XTL57ftJdGcBxRvNkTj3pdVSvRAaml3xaj64iXRrdcshQ6cmi+3Tu4ZrFPZ2E6k
|
||||||
D/jgRf3Ss6FBcoIJErnudp8nb8MUOibxb9RjIpjQxwKBgEliKaGN+/QkPTNJ4vXz
|
wY1/3BcSZsK/O/1Ps5V6MVWVkiscIsxzczzgp2ECgYAqC6yFmIbw1Ui/YIqprj8c
|
||||||
609CIilxpE+YVTzlv3YeZP5HqsJTJPS2ARIUr/Pjpbl3LHfYNeeGDCwgkJIK0JJH
|
nb5xl5KGj47ZGFIWeoNIZKOwUZu+POu+WZ4kOvySP276xvLfjLjWl+HHjN73AMaT
|
||||||
iA1M51q6t3zG2y9gKmC15FF0jShoZkRgqBxqrSHAnrCo5t2C48ElxJ3FEU8T75sz
|
RvW2+xwSEfGR4d5wqGGxk5TnJOzi0vd21tGUCGdc+AAYDE/M00skdW8AfK1fUuVm
|
||||||
dlGTbkmR0Wm43Kh++dWICJ3g
|
qkpHixGjosFWeZn9IGyu0g==
|
||||||
-----END PRIVATE KEY-----
|
-----END PRIVATE KEY-----
|
||||||
|
@ -1,40 +1,32 @@
|
|||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
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
|
||||||
-----END CERTIFICATE-----
|
XKdj8vKLmXYl/adm467ECLwGMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQEL
|
||||||
-----BEGIN CERTIFICATE-----
|
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
|
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
|
@ -1,20 +1,87 @@
|
|||||||
|
Certificate:
|
||||||
|
Data:
|
||||||
|
Version: 1 (0x0)
|
||||||
|
Serial Number: 4097 (0x1001)
|
||||||
|
Signature Algorithm: sha256WithRSAEncryption
|
||||||
|
Issuer: C=FI, ST=Helsinki, L=Helsinki, O=MariaDB, CN=Galera CA
|
||||||
|
Validity
|
||||||
|
Not Before: May 20 01:32:38 2025 GMT
|
||||||
|
Not After : May 20 01:32:38 2125 GMT
|
||||||
|
Subject:
|
||||||
|
Subject Public Key Info:
|
||||||
|
Public Key Algorithm: rsaEncryption
|
||||||
|
Public-Key: (2048 bit)
|
||||||
|
Modulus:
|
||||||
|
00:c9:0e:e9:9d:eb:8f:8d:7f:79:aa:55:7f:2d:c0:
|
||||||
|
be:92:10:77:46:78:31:63:38:82:01:91:91:4c:c1:
|
||||||
|
49:85:04:d3:28:0a:49:80:81:1f:3c:3c:00:6f:aa:
|
||||||
|
e1:ad:d1:44:0a:72:2a:82:39:72:12:5e:3d:0e:be:
|
||||||
|
43:f8:11:98:6a:cb:35:a8:f5:05:e1:1b:b1:9f:14:
|
||||||
|
ee:59:9d:4a:34:cc:92:0d:9b:cf:23:db:ba:5e:68:
|
||||||
|
b3:de:2f:37:04:41:c7:84:b0:62:fb:5d:7a:b9:6e:
|
||||||
|
0d:f8:f9:82:23:24:8c:0e:f6:34:b7:93:fe:82:f6:
|
||||||
|
fc:56:45:46:67:63:b1:a7:18:2d:2b:7a:90:92:9c:
|
||||||
|
a0:cc:11:18:68:f1:9d:24:a5:77:40:cc:c3:ae:df:
|
||||||
|
ed:c9:1c:cb:e1:66:0c:04:3e:93:2b:4f:ad:31:c1:
|
||||||
|
33:64:a4:27:7d:27:da:40:bb:bb:d9:a1:f1:b0:bc:
|
||||||
|
43:de:52:22:78:0d:21:ac:20:e0:62:15:4b:60:a4:
|
||||||
|
60:77:34:44:75:76:1f:57:00:23:15:dd:51:29:b2:
|
||||||
|
5e:75:99:b0:72:0b:49:21:31:1f:5f:a4:b9:ef:c4:
|
||||||
|
f1:1e:4c:0d:1f:4b:2d:f1:71:f9:b1:df:3f:9c:01:
|
||||||
|
7e:cd:66:ef:07:e6:e7:9a:95:eb:86:ba:44:05:84:
|
||||||
|
42:2b
|
||||||
|
Exponent: 65537 (0x10001)
|
||||||
|
Signature Algorithm: sha256WithRSAEncryption
|
||||||
|
Signature Value:
|
||||||
|
90:67:64:33:70:bd:c8:15:10:8d:8c:f3:09:48:c8:12:8d:58:
|
||||||
|
25:b6:a7:a5:2f:54:4e:a3:8e:4c:8d:e7:bb:60:2e:1c:1d:0f:
|
||||||
|
c1:62:78:d3:47:18:a0:c6:55:4c:69:38:07:e4:86:7a:c6:35:
|
||||||
|
f3:bd:05:1b:a4:67:ea:d9:ed:72:e5:37:df:7f:97:2f:76:4e:
|
||||||
|
d8:7a:df:de:7f:35:15:de:cd:e0:e3:c2:e1:96:15:79:3f:88:
|
||||||
|
5f:d1:f1:b4:f1:41:21:f1:6a:cd:92:3d:4c:14:fc:5b:17:d0:
|
||||||
|
ec:7d:12:88:18:74:ec:5c:2a:d3:e7:7b:c4:69:53:51:37:71:
|
||||||
|
d1:f8:2a:70:80:e3:b7:b5:00:a6:df:d4:9b:d4:65:5e:e2:53:
|
||||||
|
6e:98:6d:76:26:cd:19:cd:08:ec:81:8b:54:50:53:9b:06:f3:
|
||||||
|
65:83:a9:1b:9c:f0:ed:12:88:c5:0c:f2:02:d4:3f:09:fb:43:
|
||||||
|
f9:1e:13:12:05:c4:e7:47:e7:9e:bf:c0:6a:70:17:3e:f4:29:
|
||||||
|
92:77:a8:1b:d9:1c:3c:e3:ae:5d:c8:98:a6:4b:3d:22:a8:cd:
|
||||||
|
46:8e:8b:4e:b2:0c:a3:3e:9e:fe:98:a1:2c:36:10:f9:b6:63:
|
||||||
|
d4:ae:bb:a8:f3:e8:cd:2f:0e:06:a2:e9:e1:41:3f:25:8b:ec:
|
||||||
|
a1:65:56:ec:d6:98:4b:b3:fc:d1:8f:21:1e:55:3d:28:10:c3:
|
||||||
|
55:30:54:0a:92:f5:33:7e:c6:68:fb:7d:b3:5f:5a:a2:65:4f:
|
||||||
|
25:53:93:3a:11:4a:23:5b:26:59:8e:5d:c5:56:c9:35:f5:55:
|
||||||
|
45:f1:0c:f0:b3:98:62:3f:42:f3:44:17:81:fd:41:80:e5:6e:
|
||||||
|
45:76:19:f0:34:f6:9a:13:76:5e:2e:08:66:71:e0:5d:f8:aa:
|
||||||
|
f9:ef:4b:1d:23:bc:c7:a7:e4:09:61:df:e6:b7:9a:7f:d2:8c:
|
||||||
|
25:f3:26:e2:38:36:1a:1e:23:a9:10:60:08:59:22:52:cf:64:
|
||||||
|
47:68:a0:04:31:33:f7:14:ec:33:87:76:f2:84:d1:37:07:fc:
|
||||||
|
1a:fa:23:94:2a:7e:72:f8:bb:45:17:49:d7:57:46:c1:aa:4c:
|
||||||
|
d2:04:dc:82:7b:33:b9:44:ee:d2:bb:4c:60:f0:93:7b:68:19:
|
||||||
|
77:65:7b:ce:65:d2:16:2d:0b:3d:0b:7d:62:96:86:29:c2:01:
|
||||||
|
57:26:02:15:67:cb:97:5b:2e:a6:65:60:b9:4f:53:ce:3a:6a:
|
||||||
|
35:06:50:d9:1b:be:5b:a0:0e:0a:b4:66:40:a5:6a:40:d1:37:
|
||||||
|
fd:f9:0a:63:22:b4:08:7d:5f:1a:ed:cb:6f:74:17:b6:a3:56:
|
||||||
|
54:24:38:8f:c4:6a:cf:46
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
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
|
||||||
|
CH1fGu3Lb3QXtqNWVCQ4j8Rqz0Y=
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
|
@ -1,28 +1,28 @@
|
|||||||
-----BEGIN PRIVATE KEY-----
|
-----BEGIN PRIVATE KEY-----
|
||||||
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
|
||||||
A7SZFkWYfem8/q/VImjU/CNbOQ==
|
LBW22SFBcrXvQLb6CEC5mQQ=
|
||||||
-----END PRIVATE KEY-----
|
-----END PRIVATE KEY-----
|
||||||
|
@ -4,8 +4,7 @@
|
|||||||
# because of a pair of slow Solaris Sparc machines in pb2,
|
# because of a pair of slow Solaris Sparc machines in pb2,
|
||||||
# this test is marked as big:
|
# this test is marked as big:
|
||||||
--source include/big_test.inc
|
--source include/big_test.inc
|
||||||
# This test often times out with MSAN
|
--source include/not_msan_with_debug.inc
|
||||||
--source include/not_msan.inc
|
|
||||||
|
|
||||||
# MyISAM tables should be used
|
# MyISAM tables should be used
|
||||||
#
|
#
|
||||||
|
@ -42,4 +42,8 @@ connection node_2;
|
|||||||
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing");
|
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing");
|
||||||
call mtr.add_suppression("WSREP: Failed to open SR table for write");
|
call mtr.add_suppression("WSREP: Failed to open SR table for write");
|
||||||
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0");
|
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0");
|
||||||
|
connection node_1;
|
||||||
|
call mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
connection node_2;
|
||||||
|
call mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
DROP TABLE IF EXISTS t1;
|
DROP TABLE IF EXISTS t1;
|
||||||
|
@ -0,0 +1,362 @@
|
|||||||
|
connection node_2;
|
||||||
|
connection node_1;
|
||||||
|
#
|
||||||
|
# 1. BF-BF conflict on MDL locks between: DROP TABLE t6 and DELETE on t1
|
||||||
|
# with foreign key references as below:
|
||||||
|
# - t1<-t2<-t3<-t4
|
||||||
|
# - t3<-t5
|
||||||
|
# - t2<-t6
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
t5_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE,
|
||||||
|
KEY key_t5_id(t5_id)
|
||||||
|
);
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id),
|
||||||
|
CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t4 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id(t3_id),
|
||||||
|
CONSTRAINT key_t3_id FOREIGN KEY (t3_id) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t5 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id_1 INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id_1(t3_id_1),
|
||||||
|
CONSTRAINT key_t3_id_1 FOREIGN KEY (t3_id_1) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t6 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id_1(t2_id),
|
||||||
|
CONSTRAINT key_t2_id_1 FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,2,1234);
|
||||||
|
INSERT INTO t3 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t3 VALUES (2,2,1234);
|
||||||
|
INSERT INTO t4 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t4 VALUES (2,2,1234);
|
||||||
|
INSERT INTO t5 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t5 VALUES (2,2,1234);
|
||||||
|
ALTER TABLE t2 ADD CONSTRAINT key_t5_id FOREIGN KEY (t5_id)
|
||||||
|
REFERENCES t5 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
connection node_1;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
DROP TABLE t6;
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
DELETE FROM t1 WHERE id = 3;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 4 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t4]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t5]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id t5_id f2
|
||||||
|
1 1 1 1234
|
||||||
|
2 2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t4;
|
||||||
|
id t3_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t5;
|
||||||
|
id t3_id_1 f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t6;
|
||||||
|
ERROR 42S02: Table 'test.t6' doesn't exist
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id t5_id f2
|
||||||
|
1 1 1 1234
|
||||||
|
2 2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t4;
|
||||||
|
id t3_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t5;
|
||||||
|
id t3_id_1 f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t6;
|
||||||
|
ERROR 42S02: Table 'test.t6' doesn't exist
|
||||||
|
ALTER TABLE t2 DROP FOREIGN KEY key_t5_id;
|
||||||
|
DROP TABLE t5, t4, t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 2. BF-BF conflict on MDL locks between:
|
||||||
|
# ALTER TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
# DELETE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id)
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
ALTER TABLE t3 ADD CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
DELETE FROM t1 WHERE id = 3;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 2 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 3. BF-BF conflict on MDL locks between:
|
||||||
|
# CREATE TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
# DELETE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
CREATE TABLE t3 (id INT PRIMARY KEY, t2_id INT NOT NULL, f2 INTEGER NOT NULL, KEY key_t2_id(t2_id), CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE);
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
DELETE FROM t1 WHERE id = 3;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 2 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 4. BF-BF conflict on MDL locks between:
|
||||||
|
# OPTIMIZE TABLE t2 (whose parent table are t2 -> t1), and
|
||||||
|
# DELETE on t1.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
OPTIMIZE TABLE t2;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t2 optimize note Table does not support optimize, doing recreate + analyze instead
|
||||||
|
test.t2 optimize status OK
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
DELETE FROM t1 WHERE id = 3;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 1 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 0
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
DROP TABLE t2, t1;
|
@ -0,0 +1,358 @@
|
|||||||
|
connection node_2;
|
||||||
|
connection node_1;
|
||||||
|
#
|
||||||
|
# 1. BF-BF conflict on MDL locks between: DROP TABLE t6 and UPDATE on t1
|
||||||
|
# with foreign key references as below:
|
||||||
|
# - t1<-t2<-t3<-t4
|
||||||
|
# - t3<-t5
|
||||||
|
# - t2<-t6
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
t5_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE,
|
||||||
|
KEY key_t5_id(t5_id)
|
||||||
|
);
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id),
|
||||||
|
CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t4 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id(t3_id),
|
||||||
|
CONSTRAINT key_t3_id FOREIGN KEY (t3_id) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t5 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id_1 INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id_1(t3_id_1),
|
||||||
|
CONSTRAINT key_t3_id_1 FOREIGN KEY (t3_id_1) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t6 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id_1(t2_id),
|
||||||
|
CONSTRAINT key_t2_id_1 FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,2,1234);
|
||||||
|
INSERT INTO t3 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t3 VALUES (2,2,1234);
|
||||||
|
INSERT INTO t4 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t4 VALUES (2,2,1234);
|
||||||
|
INSERT INTO t5 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t5 VALUES (2,2,1234);
|
||||||
|
ALTER TABLE t2 ADD CONSTRAINT key_t5_id FOREIGN KEY (t5_id)
|
||||||
|
REFERENCES t5 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
connection node_1;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
DROP TABLE t6;
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
UPDATE t1 SET f2 = 1 WHERE id=2;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 4 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t4]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t5]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id t5_id f2
|
||||||
|
1 1 1 1234
|
||||||
|
2 2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t4;
|
||||||
|
id t3_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t5;
|
||||||
|
id t3_id_1 f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t6;
|
||||||
|
ERROR 42S02: Table 'test.t6' doesn't exist
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id t5_id f2
|
||||||
|
1 1 1 1234
|
||||||
|
2 2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t4;
|
||||||
|
id t3_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t5;
|
||||||
|
id t3_id_1 f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t6;
|
||||||
|
ERROR 42S02: Table 'test.t6' doesn't exist
|
||||||
|
ALTER TABLE t2 DROP FOREIGN KEY key_t5_id;
|
||||||
|
DROP TABLE t5, t4, t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 2. BF-BF conflict on MDL locks between:
|
||||||
|
# ALTER TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
# UPDATE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id)
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
ALTER TABLE t3 ADD CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
UPDATE t1 SET f2 = 1 WHERE id=2;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 2 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 3. BF-BF conflict on MDL locks between:
|
||||||
|
# CREATE TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
# UPDATE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
CREATE TABLE t3 (id INT PRIMARY KEY, t2_id INT NOT NULL, f2 INTEGER NOT NULL, KEY key_t2_id(t2_id), CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE);
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
UPDATE t1 SET f2 = 1 WHERE id=2;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 2 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t3]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
select * from t3;
|
||||||
|
id t2_id f2
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
#
|
||||||
|
# 4. BF-BF conflict on MDL locks between:
|
||||||
|
# OPTIMIZE TABLE t2 (whose parent table are t2 -> t1), and
|
||||||
|
# UPDATE on t1.
|
||||||
|
#
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
connection node_1;
|
||||||
|
OPTIMIZE TABLE t2;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t2 optimize note Table does not support optimize, doing recreate + analyze instead
|
||||||
|
test.t2 optimize status OK
|
||||||
|
connection node_2;
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
connection node_1;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
UPDATE t1 SET f2 = 1 WHERE id=2;
|
||||||
|
COMMIT;
|
||||||
|
connection node_2;
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
connection node_1;
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: 1 tables]
|
||||||
|
include/assert_grep.inc [Foreign key referenced table found: test.t2]
|
||||||
|
connection node_2;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
connection node_1;
|
||||||
|
select * from t1;
|
||||||
|
id f2
|
||||||
|
1 0
|
||||||
|
2 1
|
||||||
|
select * from t2;
|
||||||
|
id t1_id f2
|
||||||
|
1 1 1234
|
||||||
|
2 2 1234
|
||||||
|
DROP TABLE t2, t1;
|
@ -8,6 +8,8 @@ connection node_2;
|
|||||||
connection node_3;
|
connection node_3;
|
||||||
connection node_4;
|
connection node_4;
|
||||||
connection node_1;
|
connection node_1;
|
||||||
|
SET SESSION wsrep_on = ON;
|
||||||
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
CREATE TABLE t1(pk INT AUTO_INCREMENT PRIMARY KEY);
|
CREATE TABLE t1(pk INT AUTO_INCREMENT PRIMARY KEY);
|
||||||
CREATE PROCEDURE p1(IN max INT)
|
CREATE PROCEDURE p1(IN max INT)
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -48,6 +50,8 @@ CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
|||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
INSERT INTO t2 VALUES (DEFAULT);
|
INSERT INTO t2 VALUES (DEFAULT);
|
||||||
CALL p1(130);
|
CALL p1(130);
|
||||||
|
connection node_2;
|
||||||
|
connection node_3;
|
||||||
connection node_1;
|
connection node_1;
|
||||||
SET GLOBAL debug = "+d,sync.wsrep_sst_donor_after_donation";
|
SET GLOBAL debug = "+d,sync.wsrep_sst_donor_after_donation";
|
||||||
Restarting server 4
|
Restarting server 4
|
||||||
@ -58,8 +62,6 @@ SET SESSION DEBUG_SYNC = "now SIGNAL signal.wsrep_sst_donor_after_donation_conti
|
|||||||
SET GLOBAL debug = "";
|
SET GLOBAL debug = "";
|
||||||
SET DEBUG_SYNC='RESET';
|
SET DEBUG_SYNC='RESET';
|
||||||
Waiting for server 4 to leave the cluster
|
Waiting for server 4 to leave the cluster
|
||||||
SET SESSION wsrep_on = ON;
|
|
||||||
SET SESSION wsrep_sync_wait = 15;
|
|
||||||
connection node_2;
|
connection node_2;
|
||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
SET SESSION wsrep_sync_wait = 15;
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
@ -69,10 +71,18 @@ SET SESSION wsrep_sync_wait = 15;
|
|||||||
connection node_4;
|
connection node_4;
|
||||||
Server 4 left the cluster, killing it...
|
Server 4 left the cluster, killing it...
|
||||||
Killed server 4...
|
Killed server 4...
|
||||||
|
connection node_1;
|
||||||
|
connection node_4;
|
||||||
Restarting server 4...
|
Restarting server 4...
|
||||||
connection node_1;
|
connection node_1;
|
||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
SET SESSION wsrep_sync_wait = 15;
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
|
connection node_2;
|
||||||
|
SET SESSION wsrep_on = ON;
|
||||||
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
|
connection node_3;
|
||||||
|
SET SESSION wsrep_on = ON;
|
||||||
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
connection node_1;
|
connection node_1;
|
||||||
SELECT count(*) AS expect1_390 FROM t1;
|
SELECT count(*) AS expect1_390 FROM t1;
|
||||||
expect1_390
|
expect1_390
|
||||||
|
@ -53,16 +53,26 @@ SET SESSION wsrep_sync_wait = 0;
|
|||||||
--let $start_mysqld_params =--wsrep-new-cluster
|
--let $start_mysqld_params =--wsrep-new-cluster
|
||||||
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
|
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
--let $start_mysqld_params =
|
--let $start_mysqld_params =
|
||||||
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.2.expect
|
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.2.expect
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
|
||||||
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing");
|
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing");
|
||||||
call mtr.add_suppression("WSREP: Failed to open SR table for write");
|
call mtr.add_suppression("WSREP: Failed to open SR table for write");
|
||||||
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0");
|
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0");
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
#
|
||||||
|
# after the membership change on a newly synced node, then this is just a warning
|
||||||
|
#
|
||||||
|
call mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
--connection node_2
|
||||||
|
call mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
|
||||||
#
|
#
|
||||||
# Cleanup
|
# Cleanup
|
||||||
#
|
#
|
||||||
|
452
mysql-test/suite/galera/t/galera_multi_level_fk_ddl_delete.test
Normal file
452
mysql-test/suite/galera/t/galera_multi_level_fk_ddl_delete.test
Normal file
@ -0,0 +1,452 @@
|
|||||||
|
#
|
||||||
|
# BF-BF conflict on MDL locks between DDL and delete query
|
||||||
|
# when multi-level foreign key like t3 -> t2 -> t1
|
||||||
|
# are present.
|
||||||
|
#
|
||||||
|
# If bug is present, expect the wait condition
|
||||||
|
# to timeout and when the DELETE applies, it
|
||||||
|
# will be granted a MDL lock of type SHARED_READ
|
||||||
|
# for table t1. When resumed, the DROP TABLE will
|
||||||
|
# also try to MDL lock t1, causing a BF-BF conflict
|
||||||
|
# on that MDL lock.
|
||||||
|
|
||||||
|
--source include/galera_cluster.inc
|
||||||
|
--source include/have_innodb.inc
|
||||||
|
--source include/have_debug.inc
|
||||||
|
--source include/have_debug_sync.inc
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 1. BF-BF conflict on MDL locks between: DROP TABLE t6 and DELETE on t1
|
||||||
|
--echo # with foreign key references as below:
|
||||||
|
--echo # - t1<-t2<-t3<-t4
|
||||||
|
--echo # - t3<-t5
|
||||||
|
--echo # - t2<-t6
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
t5_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE,
|
||||||
|
KEY key_t5_id(t5_id)
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id),
|
||||||
|
CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t4 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id(t3_id),
|
||||||
|
CONSTRAINT key_t3_id FOREIGN KEY (t3_id) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t5 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id_1 INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id_1(t3_id_1),
|
||||||
|
CONSTRAINT key_t3_id_1 FOREIGN KEY (t3_id_1) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t6 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id_1(t2_id),
|
||||||
|
CONSTRAINT key_t2_id_1 FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t3 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t3 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t4 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t4 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t5 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t5 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
ALTER TABLE t2 ADD CONSTRAINT key_t5_id FOREIGN KEY (t5_id)
|
||||||
|
REFERENCES t5 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS WHERE TABLE_NAME = "t2" AND CONSTRAINT_TYPE = "FOREIGN KEY" AND CONSTRAINT_NAME="key_t5_id"
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = DROP TABLE t6
|
||||||
|
--let $fk_child_query = DELETE FROM t1 WHERE id = 3
|
||||||
|
--let $fk_mdl_lock_num = 5
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 4 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 4
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t4
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t4
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t5
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t5
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify delete and drop table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM test.t1
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
select * from t4;
|
||||||
|
select * from t5;
|
||||||
|
--error ER_NO_SUCH_TABLE
|
||||||
|
select * from t6;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
select * from t4;
|
||||||
|
select * from t5;
|
||||||
|
--error ER_NO_SUCH_TABLE
|
||||||
|
select * from t6;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
ALTER TABLE t2 DROP FOREIGN KEY key_t5_id;
|
||||||
|
DROP TABLE t5, t4, t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 2. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # ALTER TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
--echo # DELETE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id)
|
||||||
|
);
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# ALTER TABLE t3 and wait for it to reach node_2
|
||||||
|
#
|
||||||
|
--let $fk_parent_query = ALTER TABLE t3 ADD CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
#
|
||||||
|
# Issue a DELETE to table that references t1
|
||||||
|
#
|
||||||
|
--let $fk_child_query = DELETE FROM t1 WHERE id = 3
|
||||||
|
--let $fk_mdl_lock_num = 3
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 2 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 6
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 2
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 2
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify delete and alter table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM test.t1
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 3. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # CREATE TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
--echo # DELETE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = CREATE TABLE t3 (id INT PRIMARY KEY, t2_id INT NOT NULL, f2 INTEGER NOT NULL, KEY key_t2_id(t2_id), CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE)
|
||||||
|
--let $fk_child_query = DELETE FROM t1 WHERE id = 3
|
||||||
|
--let $fk_mdl_lock_num = 3
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 2 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 8
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 3
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 3
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify delete and create table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM test.t1
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 4. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # OPTIMIZE TABLE t2 (whose parent table are t2 -> t1), and
|
||||||
|
--echo # DELETE on t1.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
INSERT INTO t1 VALUES (3,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = OPTIMIZE TABLE t2
|
||||||
|
--let $fk_child_query = DELETE FROM t1 WHERE id = 3
|
||||||
|
--let $fk_mdl_lock_num = 2
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 1 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 9
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let $assert_only_after = CURRENT_TEST:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 4
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_delete
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify delete and create table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM test.t1
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t2, t1;
|
451
mysql-test/suite/galera/t/galera_multi_level_fk_ddl_update.test
Normal file
451
mysql-test/suite/galera/t/galera_multi_level_fk_ddl_update.test
Normal file
@ -0,0 +1,451 @@
|
|||||||
|
#
|
||||||
|
# BF-BF conflict on MDL locks between DDL and update query
|
||||||
|
# when multi-level foreign key like t3 -> t2 -> t1
|
||||||
|
# are present.
|
||||||
|
#
|
||||||
|
# If bug is present, expect the wait condition
|
||||||
|
# to timeout and when the UPDATE applies, it
|
||||||
|
# will be granted a MDL lock of type SHARED_READ
|
||||||
|
# for table t1. When resumed, the DROP TABLE will
|
||||||
|
# also try to MDL lock t1, causing a BF-BF conflict
|
||||||
|
# on that MDL lock.
|
||||||
|
|
||||||
|
--source include/galera_cluster.inc
|
||||||
|
--source include/have_innodb.inc
|
||||||
|
--source include/have_debug.inc
|
||||||
|
--source include/have_debug_sync.inc
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 1. BF-BF conflict on MDL locks between: DROP TABLE t6 and UPDATE on t1
|
||||||
|
--echo # with foreign key references as below:
|
||||||
|
--echo # - t1<-t2<-t3<-t4
|
||||||
|
--echo # - t3<-t5
|
||||||
|
--echo # - t2<-t6
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
t5_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE,
|
||||||
|
KEY key_t5_id(t5_id)
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id),
|
||||||
|
CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t4 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id(t3_id),
|
||||||
|
CONSTRAINT key_t3_id FOREIGN KEY (t3_id) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t5 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t3_id_1 INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t3_id_1(t3_id_1),
|
||||||
|
CONSTRAINT key_t3_id_1 FOREIGN KEY (t3_id_1) REFERENCES t3 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t6 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id_1(t2_id),
|
||||||
|
CONSTRAINT key_t2_id_1 FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t3 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t3 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t4 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t4 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
INSERT INTO t5 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t5 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
ALTER TABLE t2 ADD CONSTRAINT key_t5_id FOREIGN KEY (t5_id)
|
||||||
|
REFERENCES t5 (id) ON UPDATE CASCADE ON DELETE CASCADE;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS WHERE TABLE_NAME = "t2" AND CONSTRAINT_TYPE = "FOREIGN KEY" AND CONSTRAINT_NAME="key_t5_id"
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = DROP TABLE t6
|
||||||
|
--let $fk_child_query = UPDATE t1 SET f2 = 1 WHERE id=2
|
||||||
|
--let $fk_mdl_lock_num = 5
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 4 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 4
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t4
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t4
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t5
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 1
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t5
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify update and drop table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM test.t1 where id=2 and f2=1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
select * from t4;
|
||||||
|
select * from t5;
|
||||||
|
--error ER_NO_SUCH_TABLE
|
||||||
|
select * from t6;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
select * from t4;
|
||||||
|
select * from t5;
|
||||||
|
--error ER_NO_SUCH_TABLE
|
||||||
|
select * from t6;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
ALTER TABLE t2 DROP FOREIGN KEY key_t5_id;
|
||||||
|
DROP TABLE t5, t4, t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 2. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # ALTER TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
--echo # UPDATE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t3 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t2_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t2_id(t2_id)
|
||||||
|
);
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# ALTER TABLE t3 and wait for it to reach node_2
|
||||||
|
#
|
||||||
|
--let $fk_parent_query = ALTER TABLE t3 ADD CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
#
|
||||||
|
# Issue a UPDATE to table that references t1
|
||||||
|
# Notice that we update field f2, not the primary key,
|
||||||
|
# and not foreign key. Bug does not manifest if we update
|
||||||
|
# one of those fields (because FK keys appended in those cases).
|
||||||
|
#
|
||||||
|
--let $fk_child_query = UPDATE t1 SET f2 = 1 WHERE id=2
|
||||||
|
--let $fk_mdl_lock_num = 3
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 2 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 6
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 2
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 2
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify update and drop table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM test.t1 where id=2 and f2=1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 3. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # CREATE TABLE t3 (whose parent table are t3 -> t2 -> t1), and
|
||||||
|
--echo # UPDATE on t1 with t2 referencing t1, and t3 referencing t2.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = CREATE TABLE t3 (id INT PRIMARY KEY, t2_id INT NOT NULL, f2 INTEGER NOT NULL, KEY key_t2_id(t2_id), CONSTRAINT key_t2_id FOREIGN KEY (t2_id) REFERENCES t2 (id) ON UPDATE CASCADE ON DELETE CASCADE)
|
||||||
|
--let $fk_child_query = UPDATE t1 SET f2 = 1 WHERE id=2
|
||||||
|
--let $fk_mdl_lock_num = 3
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 2 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 8
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let $assert_only_after = CURRENT_TEST:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 3
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t3
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 3
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t3
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify update and drop table has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM test.t1 where id=2 and f2=1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
select * from t3;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t3, t2, t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # 4. BF-BF conflict on MDL locks between:
|
||||||
|
--echo # OPTIMIZE TABLE t2 (whose parent table are t2 -> t1), and
|
||||||
|
--echo # UPDATE on t1.
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
#
|
||||||
|
# Setup
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL wsrep_slave_threads=2;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
id INTEGER PRIMARY KEY,
|
||||||
|
f2 INTEGER
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE t2 (
|
||||||
|
id INT PRIMARY KEY,
|
||||||
|
t1_id INT NOT NULL,
|
||||||
|
f2 INTEGER NOT NULL,
|
||||||
|
KEY key_t1_id(t1_id),
|
||||||
|
CONSTRAINT key_t1_id FOREIGN KEY (t1_id) REFERENCES t1 (id) ON UPDATE CASCADE ON DELETE CASCADE
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO t1 VALUES (1,0);
|
||||||
|
INSERT INTO t1 VALUES (2,0);
|
||||||
|
|
||||||
|
INSERT INTO t2 VALUES (1,1,1234);
|
||||||
|
INSERT INTO t2 VALUES (2,2,1234);
|
||||||
|
|
||||||
|
|
||||||
|
--let $fk_parent_query = OPTIMIZE TABLE t2
|
||||||
|
--let $fk_child_query = UPDATE t1 SET f2 = 1 WHERE id=2
|
||||||
|
--let $fk_mdl_lock_num = 2
|
||||||
|
--source galera_multi_level_foreign_key.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify Foreign key for referenced table added.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
--let assert_text= Foreign key referenced table found: 1 tables
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 9
|
||||||
|
--let assert_select= Foreign key referenced table found:
|
||||||
|
--let $assert_only_after = CURRENT_TEST:
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
--let assert_text= Foreign key referenced table found: test.t2
|
||||||
|
--let $assert_file= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let assert_count= 4
|
||||||
|
--let assert_select= Foreign key referenced table found: test.t2
|
||||||
|
--let assert_only_after= CURRENT_TEST: galera.galera_multi_level_fk_ddl_update
|
||||||
|
--source include/assert_grep.inc
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Verify update has succeded.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM test.t1 where id=2 and f2=1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
select * from t1;
|
||||||
|
select * from t2;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
DROP TABLE t2, t1;
|
60
mysql-test/suite/galera/t/galera_multi_level_foreign_key.inc
Normal file
60
mysql-test/suite/galera/t/galera_multi_level_foreign_key.inc
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
#
|
||||||
|
# Execute parent query on node_1 and wait for it to reach node_2
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,sync.wsrep_apply_toi';
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
--eval $fk_parent_query
|
||||||
|
|
||||||
|
--connection node_2
|
||||||
|
SET DEBUG_SYNC = "now WAIT_FOR sync.wsrep_apply_toi_reached";
|
||||||
|
|
||||||
|
SET SESSION wsrep_sync_wait = 0;
|
||||||
|
--let $expected_apply_waits = query_get_value("SHOW STATUS LIKE 'wsrep_apply_waits'", Value, 1)
|
||||||
|
--let $expected_apply_waits = `select $expected_apply_waits + 1`
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Execute child query on node_1.
|
||||||
|
# If bug is present, expect the wait condition
|
||||||
|
# to timeout and when the child query applies, it
|
||||||
|
# will be granted a MDL lock on parent table.
|
||||||
|
# When resumed, the parent query will
|
||||||
|
# also try to acquire MDL lock on parent table,
|
||||||
|
# causing a BF-BF conflict on that MDL lock.
|
||||||
|
#
|
||||||
|
--connection node_1
|
||||||
|
SET GLOBAL DEBUG_DBUG = '+d,wsrep_print_foreign_keys_table';
|
||||||
|
START TRANSACTION;
|
||||||
|
--eval $fk_child_query
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = $fk_mdl_lock_num FROM performance_schema.metadata_locks WHERE OBJECT_SCHEMA='test' AND LOCK_STATUS="GRANTED"
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
COMMIT;
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Expect the child query to depend on the parent query,
|
||||||
|
# therefore it should wait for the parent query to
|
||||||
|
# finish before it can be applied.
|
||||||
|
#
|
||||||
|
--connection node_2
|
||||||
|
--let $status_var = wsrep_apply_waits
|
||||||
|
--let $status_var_value = $expected_apply_waits
|
||||||
|
--source include/wait_for_status_var.inc
|
||||||
|
|
||||||
|
SET GLOBAL DEBUG_DBUG = '-d,sync.wsrep_apply_toi';
|
||||||
|
SET DEBUG_SYNC = "now SIGNAL signal.wsrep_apply_toi";
|
||||||
|
|
||||||
|
|
||||||
|
#
|
||||||
|
# Cleanup
|
||||||
|
#
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
SET DEBUG_SYNC = 'RESET';
|
||||||
|
SET GLOBAL DEBUG_DBUG = "";
|
||||||
|
SET GLOBAL wsrep_slave_threads=DEFAULT;
|
@ -5,7 +5,7 @@ loose-galera-ssl-cipher=1
|
|||||||
wsrep-debug=1
|
wsrep-debug=1
|
||||||
|
|
||||||
[mysqld.1]
|
[mysqld.1]
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;cert.log_conflicts=YES;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;cert.log_conflicts=YES;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
|
||||||
[mysqld.2]
|
[mysqld.2]
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;cert.log_conflicts=YES;repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;cert.log_conflicts=YES;repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
@ -5,7 +5,7 @@ loose-galera-ssl-upgrade=1
|
|||||||
wsrep-debug=1
|
wsrep-debug=1
|
||||||
|
|
||||||
[mysqld.1]
|
[mysqld.1]
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
|
||||||
[mysqld.2]
|
[mysqld.2]
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
@ -61,6 +61,8 @@ SET SESSION wsrep_sync_wait=0;
|
|||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
--let $wait_condition = SELECT COUNT(*) = 2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1001 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
SELECT COUNT(*) AS EXPECT_3 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 't1';
|
SELECT COUNT(*) AS EXPECT_3 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 't1';
|
||||||
SELECT COUNT(*) AS EXPECT_2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
SELECT COUNT(*) AS EXPECT_2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
||||||
@ -72,6 +74,8 @@ SELECT COUNT(*) AS EXPECT_1001 FROM t1;
|
|||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
--let $wait_condition = SELECT COUNT(*) = 2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
--let $wait_condition = SELECT COUNT(*) = 2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1001 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
SELECT COUNT(*) AS EXPECT_3 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 't1';
|
SELECT COUNT(*) AS EXPECT_3 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 't1';
|
||||||
SELECT COUNT(*) AS EXPECT_2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
SELECT COUNT(*) AS EXPECT_2 FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 't1';
|
||||||
|
@ -20,6 +20,10 @@ source ../wsrep/include/check_galera_version.inc;
|
|||||||
|
|
||||||
# create table t1 and procedure p1 to generate wirtesets
|
# create table t1 and procedure p1 to generate wirtesets
|
||||||
--connection node_1
|
--connection node_1
|
||||||
|
|
||||||
|
--let $members = 4
|
||||||
|
--source include/wsrep_wait_membership.inc
|
||||||
|
|
||||||
CREATE TABLE t1(pk INT AUTO_INCREMENT PRIMARY KEY);
|
CREATE TABLE t1(pk INT AUTO_INCREMENT PRIMARY KEY);
|
||||||
|
|
||||||
DELIMITER |;
|
DELIMITER |;
|
||||||
@ -39,11 +43,17 @@ DELIMITER ;|
|
|||||||
CALL p1(130);
|
CALL p1(130);
|
||||||
|
|
||||||
--connection node_4
|
--connection node_4
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = 't1';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 130 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
--echo Shutting down server 4...
|
--echo Shutting down server 4...
|
||||||
--let $node_4_server_id= `SELECT @@server_id`
|
--let $node_4_server_id= `SELECT @@server_id`
|
||||||
--let $node_4_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$node_4_server_id.expect
|
--let $node_4_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$node_4_server_id.expect
|
||||||
--let $node_4_pid_file= `SELECT @@pid_file`
|
--let $node_4_pid_file= `SELECT @@pid_file`
|
||||||
--source include/shutdown_mysqld.inc
|
--source include/shutdown_mysqld.inc
|
||||||
|
--source include/wait_until_disconnected.inc
|
||||||
|
|
||||||
# Wait for node #4 to leave cluster
|
# Wait for node #4 to leave cluster
|
||||||
--let $members = 3
|
--let $members = 3
|
||||||
@ -65,16 +75,23 @@ CALL p1(130);
|
|||||||
SET SESSION wsrep_on = OFF;
|
SET SESSION wsrep_on = OFF;
|
||||||
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 260 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
SET SESSION wsrep_on = OFF;
|
SET SESSION wsrep_on = OFF;
|
||||||
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
|
||||||
--connection node_3
|
--connection node_3
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 260 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
SET SESSION wsrep_on = OFF;
|
SET SESSION wsrep_on = OFF;
|
||||||
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
CREATE TABLE t2(pk INT AUTO_INCREMENT PRIMARY KEY);
|
||||||
SET SESSION wsrep_on = ON;
|
SET SESSION wsrep_on = ON;
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
|
||||||
# This should cause error during IST
|
# This should cause error during IST
|
||||||
INSERT INTO t2 VALUES (DEFAULT);
|
INSERT INTO t2 VALUES (DEFAULT);
|
||||||
@ -82,6 +99,13 @@ INSERT INTO t2 VALUES (DEFAULT);
|
|||||||
# make sure nodes 1,2,3 progress far enough for commit cut update
|
# make sure nodes 1,2,3 progress far enough for commit cut update
|
||||||
CALL p1(130);
|
CALL p1(130);
|
||||||
|
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 390 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
--connection node_3
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 390 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
# prepare to stop SST donor thread when it receives a request from starting node #4
|
# prepare to stop SST donor thread when it receives a request from starting node #4
|
||||||
SET GLOBAL debug = "+d,sync.wsrep_sst_donor_after_donation";
|
SET GLOBAL debug = "+d,sync.wsrep_sst_donor_after_donation";
|
||||||
@ -96,14 +120,12 @@ SET SESSION DEBUG_SYNC = "now WAIT_FOR sync.wsrep_sst_donor_after_donation_reach
|
|||||||
SET SESSION DEBUG_SYNC = "now SIGNAL signal.wsrep_sst_donor_after_donation_continue";
|
SET SESSION DEBUG_SYNC = "now SIGNAL signal.wsrep_sst_donor_after_donation_continue";
|
||||||
SET GLOBAL debug = "";
|
SET GLOBAL debug = "";
|
||||||
SET DEBUG_SYNC='RESET';
|
SET DEBUG_SYNC='RESET';
|
||||||
|
|
||||||
#
|
#
|
||||||
# After this point node #4 shall proceed to IST and bail out
|
# After this point node #4 shall proceed to IST and bail out
|
||||||
#
|
#
|
||||||
|
|
||||||
--echo Waiting for server 4 to leave the cluster
|
--echo Waiting for server 4 to leave the cluster
|
||||||
--let $members = 3
|
--let $members = 3
|
||||||
--source include/wsrep_wait_membership.inc
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
--source include/wsrep_wait_membership.inc
|
--source include/wsrep_wait_membership.inc
|
||||||
--connection node_3
|
--connection node_3
|
||||||
@ -124,14 +146,27 @@ SET DEBUG_SYNC='RESET';
|
|||||||
EOF
|
EOF
|
||||||
--echo Killed server 4...
|
--echo Killed server 4...
|
||||||
--source include/wait_until_disconnected.inc
|
--source include/wait_until_disconnected.inc
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
--source include/wait_until_ready.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 'Synced' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_state_comment';
|
||||||
|
--let $wait_condition_on_error_output = SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_state_comment';
|
||||||
|
--source include/wait_condition_with_debug.inc
|
||||||
|
|
||||||
|
--connection node_4
|
||||||
--echo Restarting server 4...
|
--echo Restarting server 4...
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
--source include/galera_wait_ready.inc
|
--source include/galera_wait_ready.inc
|
||||||
|
|
||||||
|
|
||||||
# Confirm node #4 has rejoined
|
# Confirm node #4 has rejoined
|
||||||
--connection node_1
|
--connection node_1
|
||||||
--let $members = 4
|
--let $members = 4
|
||||||
--source include/wsrep_wait_membership.inc
|
--source include/wsrep_wait_membership.inc
|
||||||
|
--connection node_2
|
||||||
|
--source include/wsrep_wait_membership.inc
|
||||||
|
--connection node_3
|
||||||
|
--source include/wsrep_wait_membership.inc
|
||||||
|
|
||||||
# Confirm that all is good and all nodes have identical data
|
# Confirm that all is good and all nodes have identical data
|
||||||
|
|
||||||
@ -148,6 +183,10 @@ SELECT count(*) AS expect3_390 FROM t1;
|
|||||||
SELECT count(*) AS expect3_1 FROM t2;
|
SELECT count(*) AS expect3_1 FROM t2;
|
||||||
|
|
||||||
--connection node_4
|
--connection node_4
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 390 FROM t1;
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
--let $wait_condition = SELECT COUNT(*) = 1 FROM t2;
|
||||||
|
--source include/wait_condition.inc
|
||||||
SELECT count(*) AS expect4_390 FROM t1;
|
SELECT count(*) AS expect4_390 FROM t1;
|
||||||
SELECT count(*) AS expect4_1 FROM t2;
|
SELECT count(*) AS expect4_1 FROM t2;
|
||||||
|
|
||||||
|
@ -47,9 +47,13 @@ CALL mtr.add_suppression("Slave SQL: Error 'Unknown database 'test'' on query\\.
|
|||||||
CALL mtr.add_suppression("Query apply failed");
|
CALL mtr.add_suppression("Query apply failed");
|
||||||
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
||||||
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
||||||
|
CALL mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
CALL mtr.add_suppression("WSREP: Sending JOIN failed: ");
|
||||||
connection node_3;
|
connection node_3;
|
||||||
Node 3 synced
|
Node 3 synced
|
||||||
CALL mtr.add_suppression("Slave SQL: Error 'Table 't1' already exists' on query\\. Default database: 'test'\\. Query: 'CREATE TABLE test\\.t1 \\(f1 INTEGER\\)', Error_code: 1050");
|
CALL mtr.add_suppression("Slave SQL: Error 'Table 't1' already exists' on query\\. Default database: 'test'\\. Query: 'CREATE TABLE test\\.t1 \\(f1 INTEGER\\)', Error_code: 1050");
|
||||||
CALL mtr.add_suppression("Query apply failed");
|
CALL mtr.add_suppression("Query apply failed");
|
||||||
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
||||||
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
||||||
|
CALL mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
CALL mtr.add_suppression("WSREP: Sending JOIN failed: ");
|
||||||
|
@ -12,10 +12,12 @@ connection node_3;
|
|||||||
Suspending node ...
|
Suspending node ...
|
||||||
connection node_1;
|
connection node_1;
|
||||||
SET SESSION wsrep_sync_wait=0;
|
SET SESSION wsrep_sync_wait=0;
|
||||||
|
connection node_2;
|
||||||
|
SET SESSION wsrep_sync_wait=0;
|
||||||
|
connection node_1;
|
||||||
CREATE TABLE t1 (f1 INTEGER) engine=InnoDB;
|
CREATE TABLE t1 (f1 INTEGER) engine=InnoDB;
|
||||||
INSERT INTO t1 VALUES (1);
|
INSERT INTO t1 VALUES (1);
|
||||||
connection node_2;
|
connection node_2;
|
||||||
SET SESSION wsrep_sync_wait=0;
|
|
||||||
SET SESSION wsrep_sync_wait = 15;
|
SET SESSION wsrep_sync_wait = 15;
|
||||||
SELECT COUNT(*) FROM t1;
|
SELECT COUNT(*) FROM t1;
|
||||||
COUNT(*)
|
COUNT(*)
|
||||||
@ -29,4 +31,5 @@ SELECT COUNT(*) FROM t1;
|
|||||||
COUNT(*)
|
COUNT(*)
|
||||||
1
|
1
|
||||||
connection node_1;
|
connection node_1;
|
||||||
|
connection node_2;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -92,6 +92,8 @@ CALL mtr.add_suppression("Slave SQL: Error 'Unknown database 'test'' on query\\.
|
|||||||
CALL mtr.add_suppression("Query apply failed");
|
CALL mtr.add_suppression("Query apply failed");
|
||||||
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
||||||
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
||||||
|
CALL mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
CALL mtr.add_suppression("WSREP: Sending JOIN failed: ");
|
||||||
|
|
||||||
--connection node_3
|
--connection node_3
|
||||||
--let $wait_condition = SELECT VARIABLE_VALUE = 'ON' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_ready'
|
--let $wait_condition = SELECT VARIABLE_VALUE = 'ON' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_ready'
|
||||||
@ -101,5 +103,7 @@ CALL mtr.add_suppression("Slave SQL: Error 'Table 't1' already exists' on query\
|
|||||||
CALL mtr.add_suppression("Query apply failed");
|
CALL mtr.add_suppression("Query apply failed");
|
||||||
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on ");
|
||||||
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown");
|
||||||
|
CALL mtr.add_suppression("WSREP: Cert position .* less than last committed");
|
||||||
|
CALL mtr.add_suppression("WSREP: Sending JOIN failed: ");
|
||||||
|
|
||||||
--source ../galera/include/auto_increment_offset_restore.inc
|
--source ../galera/include/auto_increment_offset_restore.inc
|
||||||
|
@ -5,7 +5,7 @@ wsrep_sst_method=rsync
|
|||||||
|
|
||||||
[mysqld.1]
|
[mysqld.1]
|
||||||
wsrep_node_name='node.1'
|
wsrep_node_name='node.1'
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
|
||||||
[mysqld.2]
|
[mysqld.2]
|
||||||
wsrep_node_name='node.2'
|
wsrep_node_name='node.2'
|
||||||
@ -13,4 +13,4 @@ wsrep_provider_options='repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#gale
|
|||||||
|
|
||||||
[mysqld.3]
|
[mysqld.3]
|
||||||
wsrep_node_name='node.3'
|
wsrep_node_name='node.3'
|
||||||
wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.3.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
wsrep_provider_options='socket.ssl=yes;socket.ssl_ca=@ENV.MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.3.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M'
|
||||||
|
@ -50,7 +50,7 @@ SELECT COUNT(*) = 1 FROM t1;
|
|||||||
# Restart node with SSL enabled
|
# Restart node with SSL enabled
|
||||||
--source include/shutdown_mysqld.inc
|
--source include/shutdown_mysqld.inc
|
||||||
--let $restart_noprint = 1
|
--let $restart_noprint = 1
|
||||||
--let $restart_parameters = --wsrep_cluster_address=gcomm://127.0.0.1:$NODE_GALERAPORT_1 --wsrep_provider_options=base_port=$NODE_GALERAPORT_2;socket.ssl=yes;socket.ssl_ca=$MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_cert=$MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=$MYSQL_TEST_DIR/std_data/galera-key.pem
|
--let $restart_parameters = --wsrep_cluster_address=gcomm://127.0.0.1:$NODE_GALERAPORT_1 --wsrep_provider_options=base_port=$NODE_GALERAPORT_2;socket.ssl=yes;socket.ssl_ca=$MYSQL_TEST_DIR/std_data/galera-upgrade-ca-cert.pem;socket.ssl_cert=$MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=$MYSQL_TEST_DIR/std_data/galera-key.pem
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
--source include/galera_wait_ready.inc
|
--source include/galera_wait_ready.inc
|
||||||
|
|
||||||
|
@ -0,0 +1,4 @@
|
|||||||
|
!include ../galera_3nodes.cnf
|
||||||
|
|
||||||
|
[mysqld]
|
||||||
|
wsrep-debug=1
|
@ -43,6 +43,12 @@ SET SESSION wsrep_sync_wait=0;
|
|||||||
--let $wait_condition = SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
--let $wait_condition = SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
--connection node_2
|
||||||
|
SET SESSION wsrep_sync_wait=0;
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
--eval SET GLOBAL wsrep_provider_options = '$wsrep_provider_options_node1';
|
--eval SET GLOBAL wsrep_provider_options = '$wsrep_provider_options_node1';
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
@ -52,10 +58,6 @@ CREATE TABLE t1 (f1 INTEGER) engine=InnoDB;
|
|||||||
INSERT INTO t1 VALUES (1);
|
INSERT INTO t1 VALUES (1);
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
SET SESSION wsrep_sync_wait=0;
|
|
||||||
--let $wait_condition = SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
|
||||||
--source include/wait_condition.inc
|
|
||||||
|
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
--eval SET GLOBAL wsrep_provider_options = '$wsrep_provider_options_node2';
|
--eval SET GLOBAL wsrep_provider_options = '$wsrep_provider_options_node2';
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
@ -86,6 +88,10 @@ SELECT COUNT(*) FROM t1;
|
|||||||
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
|
--connection node_2
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size'
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
# Restore original auto_increment_offset values.
|
# Restore original auto_increment_offset values.
|
||||||
|
47
mysql-test/suite/innodb/r/alloc_fail.result
Normal file
47
mysql-test/suite/innodb/r/alloc_fail.result
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
#
|
||||||
|
# MDEV-36017 Alter table aborts when temporary
|
||||||
|
# directory is full
|
||||||
|
#
|
||||||
|
SET SESSION DEFAULT_STORAGE_ENGINE=InnoDB;
|
||||||
|
CREATE TABLE t1(f1 CHAR(100) NOT NULL, f2 CHAR(100) NOT NULL,
|
||||||
|
f3 CHAR(100) NOT NULL, f4 CHAR(100) NOT NULL,
|
||||||
|
f5 CHAR(100) NOT NULL)ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT 'a', 'b', 'c', 'd', 'e' FROM seq_1_to_65536;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,write_to_tmp_file_fail" FOR
|
||||||
|
CREATE TABLE t2 as SELECT * FROM t1;
|
||||||
|
ERROR HY000: Got error 59 'Temp file write failure' from InnoDB
|
||||||
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_1024;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,write_to_tmp_file_fail" FOR
|
||||||
|
ALTER TABLE t1 FORCE, ALGORITHM=COPY;
|
||||||
|
ERROR HY000: Got error 59 'Temp file write failure' from InnoDB
|
||||||
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_4096;
|
||||||
|
SET DEBUG_SYNC="inplace_after_index_build SIGNAL dml_start WAIT_FOR dml_commit";
|
||||||
|
ALTER TABLE t1 ADD KEY(f1), ADD INDEX(f3(10));
|
||||||
|
connect con1,localhost,root,,,;
|
||||||
|
SET DEBUG_SYNC="now WAIT_FOR dml_start";
|
||||||
|
BEGIN;
|
||||||
|
INSERT INTO t1 SELECT * FROM t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,os_file_write_fail" FOR COMMIT;
|
||||||
|
SET DEBUG_SYNC="now SIGNAL dml_commit";
|
||||||
|
connection default;
|
||||||
|
ERROR HY000: Temporary file write failure
|
||||||
|
disconnect con1;
|
||||||
|
CHECK TABLE t1;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 check status OK
|
||||||
|
DROP TABLE t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,ddl_log_write_fail" FOR
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL)ENGINE=InnoDB;
|
||||||
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1(f1 TEXT, index(f1(2)))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 VALUES('a');
|
||||||
|
set statement DEBUG_DBUG="+d,btr_page_alloc_fail" for
|
||||||
|
UPDATE t1 set f1= REPEAT('b', 12000);
|
||||||
|
ERROR HY000: The table 't1' is full
|
||||||
|
DROP TABLE t1;
|
25
mysql-test/suite/innodb/r/alter_temp_fail.result
Normal file
25
mysql-test/suite/innodb/r/alter_temp_fail.result
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
#
|
||||||
|
# MDEV-36017 Alter table aborts when temporary
|
||||||
|
# directory is full
|
||||||
|
#
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_4096;
|
||||||
|
SET DEBUG_SYNC="inplace_after_index_build SIGNAL dml_start WAIT_FOR dml_commit";
|
||||||
|
ALTER TABLE t1 ADD KEY(f1), ADD INDEX(f3(10));
|
||||||
|
connect con1,localhost,root,,,;
|
||||||
|
SET DEBUG_SYNC="now WAIT_FOR dml_start";
|
||||||
|
BEGIN;
|
||||||
|
INSERT INTO t1 SELECT * FROM t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,os_file_write_fail" FOR COMMIT;
|
||||||
|
SET DEBUG_SYNC="now SIGNAL dml_commit";
|
||||||
|
connection default;
|
||||||
|
ERROR HY000: Temporary file write failure
|
||||||
|
disconnect con1;
|
||||||
|
CHECK TABLE t1;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.t1 check status OK
|
||||||
|
DROP TABLE t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,ddl_log_write_fail" FOR
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL)ENGINE=InnoDB;
|
||||||
|
DROP TABLE t1;
|
@ -76,8 +76,7 @@ SET @saved_debug_dbug = @@SESSION.debug_dbug;
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_1";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_1";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -86,8 +85,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_2";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_2";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -96,8 +94,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_3";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_3";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -106,8 +103,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_4";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_4";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -116,8 +112,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_5";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_5";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -126,8 +121,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_6";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_6";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -136,8 +130,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_7";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_7";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -146,8 +139,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_8";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_8";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -156,8 +148,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_10";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_10";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -166,8 +157,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_11";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_11";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
@ -176,8 +166,7 @@ INSERT INTO t1 VALUES (1);
|
|||||||
SET SESSION debug_dbug="+d,ib_export_io_write_failure_12";
|
SET SESSION debug_dbug="+d,ib_export_io_write_failure_12";
|
||||||
FLUSH TABLES t1 FOR EXPORT;
|
FLUSH TABLES t1 FOR EXPORT;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flush() failed
|
Warning 1004 Can't create file './test/t1.cfg' (errno: 9 "Bad file descriptor")
|
||||||
Warning 1811 IO Write error: (9, Bad file descriptor) t1.cfg flose() failed
|
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
SET SESSION debug_dbug=@saved_debug_dbug;
|
SET SESSION debug_dbug=@saved_debug_dbug;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -18,6 +18,15 @@ SET STATEMENT foreign_key_checks=0, unique_checks=0 FOR
|
|||||||
INSERT INTO t1 SELECT seq*4,seq*4 FROM seq_1_to_262144;
|
INSERT INTO t1 SELECT seq*4,seq*4 FROM seq_1_to_262144;
|
||||||
SET STATEMENT foreign_key_checks=0, unique_checks=0 FOR
|
SET STATEMENT foreign_key_checks=0, unique_checks=0 FOR
|
||||||
INSERT INTO t2 SELECT seq*4,seq*4 FROM seq_1_to_16384;
|
INSERT INTO t2 SELECT seq*4,seq*4 FROM seq_1_to_16384;
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index;
|
||||||
|
@@GLOBAL.innodb_adaptive_hash_index
|
||||||
|
1
|
||||||
|
SET STATEMENT max_statement_time=1e-9 FOR
|
||||||
|
SET GLOBAL innodb_buffer_pool_size = 7340032;
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index;
|
||||||
|
@@GLOBAL.innodb_adaptive_hash_index
|
||||||
|
1
|
||||||
|
FOUND 1 /innodb_buffer_pool_size=7m.*resized from|innodb_buffer_pool_size change aborted/ in mysqld.1.err
|
||||||
set global innodb_buffer_pool_size = 7340032;
|
set global innodb_buffer_pool_size = 7340032;
|
||||||
select count(val) from t1;
|
select count(val) from t1;
|
||||||
count(val)
|
count(val)
|
||||||
|
@ -2,6 +2,16 @@ SET @save_limit=@@GLOBAL.innodb_limit_optimistic_insert_debug;
|
|||||||
SET @save_size=@@GLOBAL.innodb_buffer_pool_size;
|
SET @save_size=@@GLOBAL.innodb_buffer_pool_size;
|
||||||
SET GLOBAL innodb_limit_optimistic_insert_debug=2;
|
SET GLOBAL innodb_limit_optimistic_insert_debug=2;
|
||||||
SET GLOBAL innodb_buffer_pool_size=16777216;
|
SET GLOBAL innodb_buffer_pool_size=16777216;
|
||||||
|
call mtr.add_suppression("innodb_buffer_pool_size change aborted");
|
||||||
|
SET @old_innodb_adaptive_hash_index = @@innodb_adaptive_hash_index;
|
||||||
|
SET GLOBAL innodb_adaptive_hash_index = ON;
|
||||||
|
SET STATEMENT debug_dbug='+d,buf_shrink_fail' FOR
|
||||||
|
SET GLOBAL innodb_buffer_pool_size=8388608;
|
||||||
|
ERROR HY000: innodb_buffer_pool_size change aborted
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index,@@GLOBAL.innodb_buffer_pool_size;
|
||||||
|
@@GLOBAL.innodb_adaptive_hash_index @@GLOBAL.innodb_buffer_pool_size
|
||||||
|
1 16777216
|
||||||
|
SET GLOBAL innodb_adaptive_hash_index = @old_innodb_adaptive_hash_index;
|
||||||
CREATE TEMPORARY TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
|
CREATE TEMPORARY TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
|
||||||
INSERT INTO t1 SELECT seq FROM seq_1_to_200;
|
INSERT INTO t1 SELECT seq FROM seq_1_to_200;
|
||||||
SET GLOBAL innodb_max_purge_lag_wait=0;
|
SET GLOBAL innodb_max_purge_lag_wait=0;
|
||||||
|
@ -580,4 +580,20 @@ WHERE variable_name = 'innodb_bulk_operations';
|
|||||||
bulk_operations
|
bulk_operations
|
||||||
1
|
1
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
call mtr.add_suppression("Found 1 prepared XA transactions");
|
||||||
|
#
|
||||||
|
# MDEV-36771 Assertion `bulk_insert == TRX_NO_BULK' failed
|
||||||
|
# in trx_t::assert_freed from innodb_shutdown
|
||||||
|
#
|
||||||
|
CREATE TABLE t1(f1 INT)ENGINE=InnoDB;
|
||||||
|
XA START 'a';
|
||||||
|
INSERT INTO t1 VALUES(1);
|
||||||
|
XA END 'a';
|
||||||
|
XA PREPARE 'a';
|
||||||
|
# restart
|
||||||
|
XA COMMIT 'a';
|
||||||
|
SELECT * FROM t1;
|
||||||
|
f1
|
||||||
|
1
|
||||||
|
DROP TABLE t1;
|
||||||
# End of 10.11 tests
|
# End of 10.11 tests
|
||||||
|
2
mysql-test/suite/innodb/t/alloc_fail.opt
Normal file
2
mysql-test/suite/innodb/t/alloc_fail.opt
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
--innodb_sort_buffer_size=64k
|
||||||
|
--innodb_rollback_on_timeout=1
|
55
mysql-test/suite/innodb/t/alloc_fail.test
Normal file
55
mysql-test/suite/innodb/t/alloc_fail.test
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
--source include/have_innodb.inc
|
||||||
|
--source include/have_sequence.inc
|
||||||
|
--source include/have_debug.inc
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36017 Alter table aborts when temporary
|
||||||
|
--echo # directory is full
|
||||||
|
--echo #
|
||||||
|
SET SESSION DEFAULT_STORAGE_ENGINE=InnoDB;
|
||||||
|
CREATE TABLE t1(f1 CHAR(100) NOT NULL, f2 CHAR(100) NOT NULL,
|
||||||
|
f3 CHAR(100) NOT NULL, f4 CHAR(100) NOT NULL,
|
||||||
|
f5 CHAR(100) NOT NULL)ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT 'a', 'b', 'c', 'd', 'e' FROM seq_1_to_65536;
|
||||||
|
--error ER_GET_ERRMSG
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,write_to_tmp_file_fail" FOR
|
||||||
|
CREATE TABLE t2 as SELECT * FROM t1;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_1024;
|
||||||
|
--error ER_GET_ERRMSG
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,write_to_tmp_file_fail" FOR
|
||||||
|
ALTER TABLE t1 FORCE, ALGORITHM=COPY;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_4096;
|
||||||
|
SET DEBUG_SYNC="inplace_after_index_build SIGNAL dml_start WAIT_FOR dml_commit";
|
||||||
|
SEND ALTER TABLE t1 ADD KEY(f1), ADD INDEX(f3(10));
|
||||||
|
|
||||||
|
connect(con1,localhost,root,,,);
|
||||||
|
SET DEBUG_SYNC="now WAIT_FOR dml_start";
|
||||||
|
BEGIN;
|
||||||
|
INSERT INTO t1 SELECT * FROM t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,os_file_write_fail" FOR COMMIT;
|
||||||
|
SET DEBUG_SYNC="now SIGNAL dml_commit";
|
||||||
|
|
||||||
|
connection default;
|
||||||
|
--error ER_TEMP_FILE_WRITE_FAILURE
|
||||||
|
reap;
|
||||||
|
disconnect con1;
|
||||||
|
CHECK TABLE t1;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,ddl_log_write_fail" FOR
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL)ENGINE=InnoDB;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
CREATE TABLE t1(f1 TEXT, index(f1(2)))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 VALUES('a');
|
||||||
|
--error ER_RECORD_FILE_FULL
|
||||||
|
set statement DEBUG_DBUG="+d,btr_page_alloc_fail" for
|
||||||
|
UPDATE t1 set f1= REPEAT('b', 12000);
|
||||||
|
DROP TABLE t1;
|
1
mysql-test/suite/innodb/t/alter_temp_fail.opt
Normal file
1
mysql-test/suite/innodb/t/alter_temp_fail.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--innodb_sort_buffer_size=64k
|
30
mysql-test/suite/innodb/t/alter_temp_fail.test
Normal file
30
mysql-test/suite/innodb/t/alter_temp_fail.test
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
--source include/have_innodb.inc
|
||||||
|
--source include/have_sequence.inc
|
||||||
|
--source include/have_debug.inc
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36017 Alter table aborts when temporary
|
||||||
|
--echo # directory is full
|
||||||
|
--echo #
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100),
|
||||||
|
f3 CHAR(100))ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 SELECT seq, 'a', 'b' FROM seq_1_to_4096;
|
||||||
|
SET DEBUG_SYNC="inplace_after_index_build SIGNAL dml_start WAIT_FOR dml_commit";
|
||||||
|
SEND ALTER TABLE t1 ADD KEY(f1), ADD INDEX(f3(10));
|
||||||
|
|
||||||
|
connect(con1,localhost,root,,,);
|
||||||
|
SET DEBUG_SYNC="now WAIT_FOR dml_start";
|
||||||
|
BEGIN;
|
||||||
|
INSERT INTO t1 SELECT * FROM t1;
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,os_file_write_fail" FOR COMMIT;
|
||||||
|
SET DEBUG_SYNC="now SIGNAL dml_commit";
|
||||||
|
|
||||||
|
connection default;
|
||||||
|
--error ER_TEMP_FILE_WRITE_FAILURE
|
||||||
|
reap;
|
||||||
|
disconnect con1;
|
||||||
|
CHECK TABLE t1;
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
SET STATEMENT DEBUG_DBUG="+d,ddl_log_write_fail" FOR
|
||||||
|
CREATE TABLE t1(f1 INT NOT NULL)ENGINE=InnoDB;
|
||||||
|
DROP TABLE t1;
|
@ -1,5 +1,6 @@
|
|||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
--source include/have_sequence.inc
|
--source include/have_sequence.inc
|
||||||
|
--source include/not_embedded.inc # there are no messages in mysqld.1.err
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # MDEV-29445: Reorganize buffer pool (and remove chunks)
|
--echo # MDEV-29445: Reorganize buffer pool (and remove chunks)
|
||||||
@ -42,6 +43,17 @@ INSERT INTO t2 SELECT seq*4,seq*4 FROM seq_1_to_16384;
|
|||||||
SET GLOBAL innodb_read_only_compressed=@save_innodb_read_only_compressed;
|
SET GLOBAL innodb_read_only_compressed=@save_innodb_read_only_compressed;
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
|
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index;
|
||||||
|
--error 0,ER_WRONG_USAGE
|
||||||
|
SET STATEMENT max_statement_time=1e-9 FOR
|
||||||
|
SET GLOBAL innodb_buffer_pool_size = 7340032;
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index;
|
||||||
|
|
||||||
|
--let SEARCH_FILE= $MYSQLTEST_VARDIR/log/mysqld.1.err
|
||||||
|
--let SEARCH_PATTERN= InnoDB: Trying to shrink innodb_buffer_pool_size=7m
|
||||||
|
--let SEARCH_PATTERN= innodb_buffer_pool_size=7m.*resized from|innodb_buffer_pool_size change aborted
|
||||||
|
--source include/search_pattern_in_file.inc
|
||||||
|
|
||||||
# Attempt to shrink the buffer pool. This may occasionally fail.
|
# Attempt to shrink the buffer pool. This may occasionally fail.
|
||||||
--error 0,ER_WRONG_USAGE
|
--error 0,ER_WRONG_USAGE
|
||||||
set global innodb_buffer_pool_size = 7340032;
|
set global innodb_buffer_pool_size = 7340032;
|
||||||
|
@ -8,6 +8,16 @@ SET @save_size=@@GLOBAL.innodb_buffer_pool_size;
|
|||||||
SET GLOBAL innodb_limit_optimistic_insert_debug=2;
|
SET GLOBAL innodb_limit_optimistic_insert_debug=2;
|
||||||
SET GLOBAL innodb_buffer_pool_size=16777216;
|
SET GLOBAL innodb_buffer_pool_size=16777216;
|
||||||
|
|
||||||
|
call mtr.add_suppression("innodb_buffer_pool_size change aborted");
|
||||||
|
|
||||||
|
SET @old_innodb_adaptive_hash_index = @@innodb_adaptive_hash_index;
|
||||||
|
SET GLOBAL innodb_adaptive_hash_index = ON;
|
||||||
|
--error ER_WRONG_USAGE
|
||||||
|
SET STATEMENT debug_dbug='+d,buf_shrink_fail' FOR
|
||||||
|
SET GLOBAL innodb_buffer_pool_size=8388608;
|
||||||
|
SELECT @@GLOBAL.innodb_adaptive_hash_index,@@GLOBAL.innodb_buffer_pool_size;
|
||||||
|
SET GLOBAL innodb_adaptive_hash_index = @old_innodb_adaptive_hash_index;
|
||||||
|
|
||||||
CREATE TEMPORARY TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
|
CREATE TEMPORARY TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
|
||||||
INSERT INTO t1 SELECT seq FROM seq_1_to_200;
|
INSERT INTO t1 SELECT seq FROM seq_1_to_200;
|
||||||
|
|
||||||
|
@ -638,4 +638,19 @@ SELECT variable_value-@old_bulk_op bulk_operations
|
|||||||
FROM information_schema.global_status
|
FROM information_schema.global_status
|
||||||
WHERE variable_name = 'innodb_bulk_operations';
|
WHERE variable_name = 'innodb_bulk_operations';
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
call mtr.add_suppression("Found 1 prepared XA transactions");
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36771 Assertion `bulk_insert == TRX_NO_BULK' failed
|
||||||
|
--echo # in trx_t::assert_freed from innodb_shutdown
|
||||||
|
--echo #
|
||||||
|
CREATE TABLE t1(f1 INT)ENGINE=InnoDB;
|
||||||
|
XA START 'a';
|
||||||
|
INSERT INTO t1 VALUES(1);
|
||||||
|
XA END 'a';
|
||||||
|
XA PREPARE 'a';
|
||||||
|
--source include/restart_mysqld.inc
|
||||||
|
XA COMMIT 'a';
|
||||||
|
SELECT * FROM t1;
|
||||||
|
DROP TABLE t1;
|
||||||
--echo # End of 10.11 tests
|
--echo # End of 10.11 tests
|
||||||
|
@ -4,8 +4,7 @@
|
|||||||
--source include/innodb_page_size.inc
|
--source include/innodb_page_size.inc
|
||||||
--source include/have_sequence.inc
|
--source include/have_sequence.inc
|
||||||
--source include/not_valgrind.inc
|
--source include/not_valgrind.inc
|
||||||
# This test often times out with MSAN
|
--source include/no_msan_without_big.inc
|
||||||
--source include/not_msan.inc
|
|
||||||
|
|
||||||
create table t (
|
create table t (
|
||||||
b point not null,d point not null, spatial key (d),spatial key (b)
|
b point not null,d point not null, spatial key (d),spatial key (b)
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
--source include/big_test.inc
|
--source include/big_test.inc
|
||||||
# This test is too slow for valgrind
|
# This test is too slow for valgrind
|
||||||
--source include/not_valgrind.inc
|
--source include/not_valgrind.inc
|
||||||
--source include/not_msan.inc
|
--source include/not_msan_with_debug.inc
|
||||||
|
|
||||||
drop table if exists t1,t2;
|
drop table if exists t1,t2;
|
||||||
|
|
||||||
|
@ -6,6 +6,7 @@
|
|||||||
--source include/have_perfschema.inc
|
--source include/have_perfschema.inc
|
||||||
# Test requires: sp-protocol/ps-protocol/view-protocol/cursor-protocol disabled
|
# Test requires: sp-protocol/ps-protocol/view-protocol/cursor-protocol disabled
|
||||||
--source include/no_protocol.inc
|
--source include/no_protocol.inc
|
||||||
|
--source include/not_msan_with_debug.inc
|
||||||
# Thread stack overrun on solaris
|
# Thread stack overrun on solaris
|
||||||
let $have_solaris = `select convert(@@version_compile_os using latin1) LIKE ("solaris%")`;
|
let $have_solaris = `select convert(@@version_compile_os using latin1) LIKE ("solaris%")`;
|
||||||
if ($have_solaris)
|
if ($have_solaris)
|
||||||
|
12
mysql-test/suite/s3/clone.result
Normal file
12
mysql-test/suite/s3/clone.result
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#
|
||||||
|
# SELECT using ror_merged scan fails with s3 tables
|
||||||
|
#
|
||||||
|
DROP TABLE IF EXISTS t1;
|
||||||
|
Warnings:
|
||||||
|
Note 1051 Unknown table 'test.t1'
|
||||||
|
CREATE TABLE t1 (a INT, b INT, KEY(a), KEY(b)) ENGINE=Aria;
|
||||||
|
INSERT INTO t1 VALUES (0,0),(0,10),(3,10);
|
||||||
|
ALTER TABLE t1 ENGINE=S3;
|
||||||
|
SELECT * FROM t1 WHERE a = 99 OR b = 2;
|
||||||
|
a b
|
||||||
|
DROP TABLE t1;
|
14
mysql-test/suite/s3/clone.test
Normal file
14
mysql-test/suite/s3/clone.test
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
--source include/have_s3.inc
|
||||||
|
--source include/have_sequence.inc
|
||||||
|
--source include/have_innodb.inc
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # SELECT using ror_merged scan fails with s3 tables
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS t1;
|
||||||
|
CREATE TABLE t1 (a INT, b INT, KEY(a), KEY(b)) ENGINE=Aria;
|
||||||
|
INSERT INTO t1 VALUES (0,0),(0,10),(3,10);
|
||||||
|
ALTER TABLE t1 ENGINE=S3;
|
||||||
|
SELECT * FROM t1 WHERE a = 99 OR b = 2;
|
||||||
|
DROP TABLE t1;
|
@ -419,3 +419,73 @@ DROP SEQUENCE s2;
|
|||||||
#
|
#
|
||||||
# End of 10.6 tests
|
# End of 10.6 tests
|
||||||
#
|
#
|
||||||
|
#
|
||||||
|
# MDEV-36032 Check when doing ALTER TABLE table_name sequence=1 that table can be a sequence
|
||||||
|
#
|
||||||
|
create sequence s;
|
||||||
|
alter table s sequence=0;
|
||||||
|
insert into s values (3,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
alter table s sequence=1;
|
||||||
|
ERROR HY000: Internal error: More than one row in the table
|
||||||
|
drop table s;
|
||||||
|
create sequence s;
|
||||||
|
alter table s sequence=0;
|
||||||
|
delete from s;
|
||||||
|
insert into s values (2,500,200,1,1,1000,0,0);
|
||||||
|
select * from s;
|
||||||
|
next_not_cached_value minimum_value maximum_value start_value increment cache_size cycle_option cycle_count
|
||||||
|
2 500 200 1 1 1000 0 0
|
||||||
|
alter table s sequence=1;
|
||||||
|
ERROR HY000: Sequence 'test.s' has out of range value for options
|
||||||
|
check table s;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.s check status OK
|
||||||
|
select * from s;
|
||||||
|
next_not_cached_value minimum_value maximum_value start_value increment cache_size cycle_option cycle_count
|
||||||
|
2 500 200 1 1 1000 0 0
|
||||||
|
check table s;
|
||||||
|
Table Op Msg_type Msg_text
|
||||||
|
test.s check status OK
|
||||||
|
drop table s;
|
||||||
|
CREATE TABLE `s` (
|
||||||
|
# `next_not_cached_value` bigint(21) NOT NULL,
|
||||||
|
`minimum_value` bigint(21) NOT NULL,
|
||||||
|
`maximum_value` bigint(21) NOT NULL,
|
||||||
|
`start_value` bigint(21) NOT NULL COMMENT 'start value when sequences is created or value if RESTART is used',
|
||||||
|
`increment` bigint(21) NOT NULL COMMENT 'increment value',
|
||||||
|
`cache_size` bigint(21) unsigned NOT NULL,
|
||||||
|
`cycle_option` tinyint(1) unsigned NOT NULL COMMENT '0 if no cycles are allowed, 1 if the sequence should begin a new cycle when maximum_value is passed',
|
||||||
|
`cycle_count` bigint(21) NOT NULL COMMENT 'How many cycles have been done'
|
||||||
|
) ENGINE=innodb;
|
||||||
|
alter table s sequence=1;
|
||||||
|
ERROR HY000: Sequence 'test.s' table structure is invalid (Wrong number of columns)
|
||||||
|
drop table s;
|
||||||
|
create sequence s;
|
||||||
|
alter table s drop column next_not_cached_value;
|
||||||
|
ERROR HY000: Sequence 'test.s' table structure is invalid (Wrong number of columns)
|
||||||
|
drop sequence s;
|
||||||
|
CREATE TABLE `s1` (
|
||||||
|
`next_not_cached_value` bigint(21) NOT NULL,
|
||||||
|
`minimum_value` bigint(21) NOT NULL,
|
||||||
|
`maximum_value` bigint(21) NOT NULL,
|
||||||
|
`start_value` bigint(21) NOT NULL COMMENT 'start value when sequences is created or value if RESTART is used',
|
||||||
|
`increment` bigint(21) NOT NULL COMMENT 'increment value',
|
||||||
|
`cache_size` bigint(21) unsigned NOT NULL,
|
||||||
|
`cycle_option` tinyint(1) unsigned NOT NULL COMMENT '0 if no cycles are allowed, 1 if the sequence should begin a new cycle when maximum_value is passed',
|
||||||
|
`cycle_count` bigint(21) NOT NULL COMMENT 'How many cycles have been done'
|
||||||
|
) ENGINE=innodb;
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
ERROR HY000: Internal error: Fewer than one row in the table
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (1,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (2,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
ERROR HY000: Internal error: More than one row in the table
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (3,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
ERROR HY000: Internal error: More than one row in the table
|
||||||
|
drop table s1;
|
||||||
|
# End of 10.11 tests
|
||||||
|
@ -295,3 +295,84 @@ DROP SEQUENCE s2;
|
|||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.6 tests
|
--echo # End of 10.6 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36032 Check when doing ALTER TABLE table_name sequence=1 that table can be a sequence
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
## Too many rows
|
||||||
|
create sequence s;
|
||||||
|
alter table s sequence=0;
|
||||||
|
insert into s values (3,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
--error ER_INTERNAL_ERROR
|
||||||
|
alter table s sequence=1;
|
||||||
|
drop table s;
|
||||||
|
|
||||||
|
## Insert a wrong row (min > max)
|
||||||
|
create sequence s;
|
||||||
|
alter table s sequence=0;
|
||||||
|
delete from s;
|
||||||
|
insert into s values (2,500,200,1,1,1000,0,0);
|
||||||
|
select * from s;
|
||||||
|
--error ER_SEQUENCE_INVALID_DATA
|
||||||
|
alter table s sequence=1;
|
||||||
|
check table s;
|
||||||
|
select * from s;
|
||||||
|
check table s;
|
||||||
|
drop table s;
|
||||||
|
|
||||||
|
## Invalid table structure (already implemented before MDEV-36032)
|
||||||
|
CREATE TABLE `s` (
|
||||||
|
# `next_not_cached_value` bigint(21) NOT NULL,
|
||||||
|
`minimum_value` bigint(21) NOT NULL,
|
||||||
|
`maximum_value` bigint(21) NOT NULL,
|
||||||
|
`start_value` bigint(21) NOT NULL COMMENT 'start value when sequences is created or value if RESTART is used',
|
||||||
|
`increment` bigint(21) NOT NULL COMMENT 'increment value',
|
||||||
|
`cache_size` bigint(21) unsigned NOT NULL,
|
||||||
|
`cycle_option` tinyint(1) unsigned NOT NULL COMMENT '0 if no cycles are allowed, 1 if the sequence should begin a new cycle when maximum_value is passed',
|
||||||
|
`cycle_count` bigint(21) NOT NULL COMMENT 'How many cycles have been done'
|
||||||
|
) ENGINE=innodb;
|
||||||
|
--error ER_SEQUENCE_INVALID_TABLE_STRUCTURE
|
||||||
|
alter table s sequence=1;
|
||||||
|
drop table s;
|
||||||
|
|
||||||
|
## Altering a sequence table to a wrong structure is detected (already
|
||||||
|
## implemented before MDEV-36032)
|
||||||
|
create sequence s;
|
||||||
|
--error ER_SEQUENCE_INVALID_TABLE_STRUCTURE
|
||||||
|
alter table s drop column next_not_cached_value;
|
||||||
|
drop sequence s;
|
||||||
|
|
||||||
|
## Create a normal table then alter to sequence
|
||||||
|
CREATE TABLE `s1` (
|
||||||
|
`next_not_cached_value` bigint(21) NOT NULL,
|
||||||
|
`minimum_value` bigint(21) NOT NULL,
|
||||||
|
`maximum_value` bigint(21) NOT NULL,
|
||||||
|
`start_value` bigint(21) NOT NULL COMMENT 'start value when sequences is created or value if RESTART is used',
|
||||||
|
`increment` bigint(21) NOT NULL COMMENT 'increment value',
|
||||||
|
`cache_size` bigint(21) unsigned NOT NULL,
|
||||||
|
`cycle_option` tinyint(1) unsigned NOT NULL COMMENT '0 if no cycles are allowed, 1 if the sequence should begin a new cycle when maximum_value is passed',
|
||||||
|
`cycle_count` bigint(21) NOT NULL COMMENT 'How many cycles have been done'
|
||||||
|
) ENGINE=innodb;
|
||||||
|
|
||||||
|
--error ER_INTERNAL_ERROR
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
# (for coverage) alter a non sequence table with sequence=0
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (1,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (2,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
--error ER_INTERNAL_ERROR
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
|
||||||
|
# (for coverage) alter a non sequence table with sequence=0
|
||||||
|
alter table s1 sequence=0;
|
||||||
|
insert into s1 values (3,1,9223372036854775806,1,1,1000,0,0);
|
||||||
|
--error ER_INTERNAL_ERROR
|
||||||
|
alter table s1 sequence=1;
|
||||||
|
|
||||||
|
drop table s1;
|
||||||
|
|
||||||
|
--echo # End of 10.11 tests
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
--source include/have_perfschema.inc
|
--source include/have_perfschema.inc
|
||||||
|
--source include/have_profiling.inc
|
||||||
--source include/word_size.inc
|
--source include/word_size.inc
|
||||||
--source include/platform.inc
|
--source include/platform.inc
|
||||||
--vertical_results
|
--vertical_results
|
||||||
|
@ -32,6 +32,16 @@ NUMERIC_BLOCK_SIZE NULL
|
|||||||
ENUM_VALUE_LIST DEFAULT,COPY,INPLACE,NOCOPY,INSTANT
|
ENUM_VALUE_LIST DEFAULT,COPY,INPLACE,NOCOPY,INSTANT
|
||||||
READ_ONLY NO
|
READ_ONLY NO
|
||||||
COMMAND_LINE_ARGUMENT OPTIONAL
|
COMMAND_LINE_ARGUMENT OPTIONAL
|
||||||
|
VARIABLE_NAME ANALYZE_MAX_LENGTH
|
||||||
|
VARIABLE_SCOPE SESSION
|
||||||
|
VARIABLE_TYPE INT UNSIGNED
|
||||||
|
VARIABLE_COMMENT Fields which length in bytes more than this are skipped by ANALYZE TABLE PERSISTENT unless explicitly listed in the FOR COLUMNS () clause
|
||||||
|
NUMERIC_MIN_VALUE 32
|
||||||
|
NUMERIC_MAX_VALUE 4294967295
|
||||||
|
NUMERIC_BLOCK_SIZE 1
|
||||||
|
ENUM_VALUE_LIST NULL
|
||||||
|
READ_ONLY NO
|
||||||
|
COMMAND_LINE_ARGUMENT REQUIRED
|
||||||
VARIABLE_NAME ANALYZE_SAMPLE_PERCENTAGE
|
VARIABLE_NAME ANALYZE_SAMPLE_PERCENTAGE
|
||||||
VARIABLE_SCOPE SESSION
|
VARIABLE_SCOPE SESSION
|
||||||
VARIABLE_TYPE DOUBLE
|
VARIABLE_TYPE DOUBLE
|
||||||
|
@ -32,6 +32,16 @@ NUMERIC_BLOCK_SIZE NULL
|
|||||||
ENUM_VALUE_LIST DEFAULT,COPY,INPLACE,NOCOPY,INSTANT
|
ENUM_VALUE_LIST DEFAULT,COPY,INPLACE,NOCOPY,INSTANT
|
||||||
READ_ONLY NO
|
READ_ONLY NO
|
||||||
COMMAND_LINE_ARGUMENT OPTIONAL
|
COMMAND_LINE_ARGUMENT OPTIONAL
|
||||||
|
VARIABLE_NAME ANALYZE_MAX_LENGTH
|
||||||
|
VARIABLE_SCOPE SESSION
|
||||||
|
VARIABLE_TYPE INT UNSIGNED
|
||||||
|
VARIABLE_COMMENT Fields which length in bytes more than this are skipped by ANALYZE TABLE PERSISTENT unless explicitly listed in the FOR COLUMNS () clause
|
||||||
|
NUMERIC_MIN_VALUE 32
|
||||||
|
NUMERIC_MAX_VALUE 4294967295
|
||||||
|
NUMERIC_BLOCK_SIZE 1
|
||||||
|
ENUM_VALUE_LIST NULL
|
||||||
|
READ_ONLY NO
|
||||||
|
COMMAND_LINE_ARGUMENT REQUIRED
|
||||||
VARIABLE_NAME ANALYZE_SAMPLE_PERCENTAGE
|
VARIABLE_NAME ANALYZE_SAMPLE_PERCENTAGE
|
||||||
VARIABLE_SCOPE SESSION
|
VARIABLE_SCOPE SESSION
|
||||||
VARIABLE_TYPE DOUBLE
|
VARIABLE_TYPE DOUBLE
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
#
|
#
|
||||||
--source include/not_asan.inc
|
--source include/not_asan.inc
|
||||||
--source include/not_ubsan.inc
|
--source include/not_ubsan.inc
|
||||||
|
--source include/not_msan.inc
|
||||||
--replace_result 392192 299008
|
--replace_result 392192 299008
|
||||||
select @@global.thread_stack;
|
select @@global.thread_stack;
|
||||||
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
|
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
|
||||||
|
@ -55,3 +55,34 @@ ERROR HY000: Function or expression 'b' cannot be used in the GENERATED ALWAYS A
|
|||||||
#
|
#
|
||||||
# End of 10.3 tests
|
# End of 10.3 tests
|
||||||
#
|
#
|
||||||
|
#
|
||||||
|
# MDEV-29155 CREATE OR REPLACE with self-referencing CHECK hangs forever, cannot be killed
|
||||||
|
#
|
||||||
|
create table t1 (a int);
|
||||||
|
create table t2 (b int)
|
||||||
|
# create or replace table t (b int);
|
||||||
|
create table t3 (c int, check(exists(select a from t1) or exists(select b from t2)));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
create table t3 (c int, check(exists(select c from t3)));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
create table t3 (d int);
|
||||||
|
create or replace table t3 (c int, check(exists(select a from t1) or exists(select b from t2)));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
drop table t3;
|
||||||
|
create table t3 (d int);
|
||||||
|
create or replace table t3 (c int, check(exists(select c from t3)));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
drop table t3;
|
||||||
|
create table t3 (c int);
|
||||||
|
alter table t3 add check(exists(select a from t1) or exists(select b from t2));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
alter table t3 add check(exists(select c from t3));
|
||||||
|
ERROR 42000: CHECK does not support subqueries or stored functions
|
||||||
|
create table t3 (c int default (select a from t1));
|
||||||
|
ERROR HY000: Function or expression 'select ...' cannot be used in the DEFAULT clause of `c`
|
||||||
|
create table t3 (c int, d int generated always as (select a from t1 limit 1));
|
||||||
|
ERROR HY000: Function or expression 'select ...' cannot be used in the GENERATED ALWAYS AS clause of `d`
|
||||||
|
drop tables t1, t2, t3;
|
||||||
|
#
|
||||||
|
# End of 10.4 tests
|
||||||
|
#
|
||||||
|
@ -64,3 +64,36 @@ create table t1 (a int auto_increment primary key,
|
|||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.3 tests
|
--echo # End of 10.3 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-29155 CREATE OR REPLACE with self-referencing CHECK hangs forever, cannot be killed
|
||||||
|
--echo #
|
||||||
|
create table t1 (a int);
|
||||||
|
create table t2 (b int)
|
||||||
|
# create or replace table t (b int);
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
create table t3 (c int, check(exists(select a from t1) or exists(select b from t2)));
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
create table t3 (c int, check(exists(select c from t3)));
|
||||||
|
create table t3 (d int);
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
create or replace table t3 (c int, check(exists(select a from t1) or exists(select b from t2)));
|
||||||
|
drop table t3;
|
||||||
|
create table t3 (d int);
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
create or replace table t3 (c int, check(exists(select c from t3)));
|
||||||
|
drop table t3;
|
||||||
|
create table t3 (c int);
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
alter table t3 add check(exists(select a from t1) or exists(select b from t2));
|
||||||
|
--error ER_SUBQUERIES_NOT_SUPPORTED
|
||||||
|
alter table t3 add check(exists(select c from t3));
|
||||||
|
--error ER_GENERATED_COLUMN_FUNCTION_IS_NOT_ALLOWED
|
||||||
|
create table t3 (c int default (select a from t1));
|
||||||
|
--error ER_GENERATED_COLUMN_FUNCTION_IS_NOT_ALLOWED
|
||||||
|
create table t3 (c int, d int generated always as (select a from t1 limit 1));
|
||||||
|
drop tables t1, t2, t3;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # End of 10.4 tests
|
||||||
|
--echo #
|
||||||
|
@ -3443,6 +3443,15 @@ insert into t values (1),(2);
|
|||||||
DELETE from t;
|
DELETE from t;
|
||||||
drop table t;
|
drop table t;
|
||||||
#
|
#
|
||||||
|
# MDEV-36817 Server crashes in do_mark_index_columns instead of
|
||||||
|
# ER_DUP_ENTRY on partitioned table
|
||||||
|
#
|
||||||
|
create table t (f int, unique(f)) engine=innodb partition by key (f) partitions 2;
|
||||||
|
insert into t (f) values (1), (3);
|
||||||
|
update t set f = 0;
|
||||||
|
ERROR 23000: Duplicate entry '0' for key 'f'
|
||||||
|
drop table t;
|
||||||
|
#
|
||||||
# End of 10.5 tests
|
# End of 10.5 tests
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
@ -3487,6 +3496,18 @@ f()
|
|||||||
drop table t;
|
drop table t;
|
||||||
drop function f;
|
drop function f;
|
||||||
#
|
#
|
||||||
|
# MDEV-33370 Assertion `!is_set() || (m_status == DA_OK_BULK &&
|
||||||
|
# is_bulk_op())' failed after ALTER TABLE of versioned table
|
||||||
|
#
|
||||||
|
create table t1 (i int) with system versioning
|
||||||
|
partition by system_time interval 1 month (
|
||||||
|
partition ver_p1 history,
|
||||||
|
partition ver_p2 history,
|
||||||
|
partition ver_pn current);
|
||||||
|
alter table `t1` partition by system_time interval 7 year ;
|
||||||
|
ERROR 22003: TIMESTAMP value is out of range in 'INTERVAL'
|
||||||
|
drop table t1;
|
||||||
|
#
|
||||||
# End of 10.11 tests
|
# End of 10.11 tests
|
||||||
#
|
#
|
||||||
set global innodb_stats_persistent= @save_persistent;
|
set global innodb_stats_persistent= @save_persistent;
|
||||||
|
@ -2691,6 +2691,16 @@ insert into t values (1),(2);
|
|||||||
DELETE from t;
|
DELETE from t;
|
||||||
drop table t;
|
drop table t;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-36817 Server crashes in do_mark_index_columns instead of
|
||||||
|
--echo # ER_DUP_ENTRY on partitioned table
|
||||||
|
--echo #
|
||||||
|
create table t (f int, unique(f)) engine=innodb partition by key (f) partitions 2;
|
||||||
|
insert into t (f) values (1), (3);
|
||||||
|
--error ER_DUP_ENTRY
|
||||||
|
update t set f = 0;
|
||||||
|
drop table t;
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.5 tests
|
--echo # End of 10.5 tests
|
||||||
--echo #
|
--echo #
|
||||||
@ -2756,6 +2766,20 @@ select f();
|
|||||||
drop table t;
|
drop table t;
|
||||||
drop function f;
|
drop function f;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-33370 Assertion `!is_set() || (m_status == DA_OK_BULK &&
|
||||||
|
--echo # is_bulk_op())' failed after ALTER TABLE of versioned table
|
||||||
|
--echo #
|
||||||
|
create table t1 (i int) with system versioning
|
||||||
|
partition by system_time interval 1 month (
|
||||||
|
partition ver_p1 history,
|
||||||
|
partition ver_p2 history,
|
||||||
|
partition ver_pn current);
|
||||||
|
|
||||||
|
--error ER_DATA_OUT_OF_RANGE
|
||||||
|
alter table `t1` partition by system_time interval 7 year ;
|
||||||
|
drop table t1;
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.11 tests
|
--echo # End of 10.11 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -78,19 +78,19 @@ ELSEIF(MSVC_ARM64)
|
|||||||
ENDIF()
|
ENDIF()
|
||||||
ELSEIF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64|i386|i686")
|
ELSEIF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64|i386|i686")
|
||||||
SET(MYSYS_SOURCES ${MYSYS_SOURCES} crc32/crc32_x86.c crc32/crc32c_x86.cc)
|
SET(MYSYS_SOURCES ${MYSYS_SOURCES} crc32/crc32_x86.c crc32/crc32c_x86.cc)
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC AND CMAKE_C_COMPILER_VERSION VERSION_LESS "5")
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND CMAKE_C_COMPILER_VERSION VERSION_LESS "5")
|
||||||
SET_SOURCE_FILES_PROPERTIES(crc32/crc32_x86.c PROPERTIES
|
SET_SOURCE_FILES_PROPERTIES(crc32/crc32_x86.c PROPERTIES
|
||||||
COMPILE_FLAGS "-msse4.2 -mpclmul")
|
COMPILE_FLAGS "-msse4.2 -mpclmul")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
IF(CMAKE_SIZEOF_VOID_P EQUAL 8)
|
IF(CMAKE_SIZEOF_VOID_P EQUAL 8)
|
||||||
SET(MYSYS_SOURCES ${MYSYS_SOURCES} crc32/crc32c_amd64.cc)
|
SET(MYSYS_SOURCES ${MYSYS_SOURCES} crc32/crc32c_amd64.cc)
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC AND CMAKE_C_COMPILER_VERSION VERSION_LESS "5")
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND CMAKE_C_COMPILER_VERSION VERSION_LESS "5")
|
||||||
SET_SOURCE_FILES_PROPERTIES(crc32/crc32c_amd64.cc PROPERTIES
|
SET_SOURCE_FILES_PROPERTIES(crc32/crc32c_amd64.cc PROPERTIES
|
||||||
COMPILE_FLAGS "-msse4.2 -mpclmul")
|
COMPILE_FLAGS "-msse4.2 -mpclmul")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ELSEIF(CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64")
|
ELSEIF(CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64")
|
||||||
IF(CMAKE_COMPILER_IS_GNUCC)
|
IF(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||||
include(CheckCXXSourceCompiles)
|
include(CheckCXXSourceCompiles)
|
||||||
|
|
||||||
CHECK_CXX_SOURCE_COMPILES("
|
CHECK_CXX_SOURCE_COMPILES("
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user