Auto-merge from mysql-5.5.
This commit is contained in:
commit
98f69947aa
@ -52,7 +52,6 @@ EXTRA_DIST = FINISH.sh \
|
|||||||
compile-pentium-icc-yassl \
|
compile-pentium-icc-yassl \
|
||||||
compile-pentium-max \
|
compile-pentium-max \
|
||||||
compile-pentium-myodbc \
|
compile-pentium-myodbc \
|
||||||
compile-pentium-mysqlfs-debug \
|
|
||||||
compile-pentium-pgcc \
|
compile-pentium-pgcc \
|
||||||
compile-pentium-valgrind-max \
|
compile-pentium-valgrind-max \
|
||||||
compile-pentium64 \
|
compile-pentium64 \
|
||||||
|
@ -14,7 +14,6 @@ Usage: $0 [-h|-n] [configure-options]
|
|||||||
-h, --help Show this help message.
|
-h, --help Show this help message.
|
||||||
-n, --just-print Don't actually run any commands; just print them.
|
-n, --just-print Don't actually run any commands; just print them.
|
||||||
-c, --just-configure Stop after running configure.
|
-c, --just-configure Stop after running configure.
|
||||||
--with-debug=full Build with full debug.
|
|
||||||
--warning-mode=[old|pedantic|maintainer]
|
--warning-mode=[old|pedantic|maintainer]
|
||||||
Influences the debug flags. Old is default.
|
Influences the debug flags. Old is default.
|
||||||
--prefix=path Build with prefix 'path'.
|
--prefix=path Build with prefix 'path'.
|
||||||
@ -30,8 +29,6 @@ parse_options()
|
|||||||
case "$1" in
|
case "$1" in
|
||||||
--prefix=*)
|
--prefix=*)
|
||||||
prefix=`get_key_value "$1"`;;
|
prefix=`get_key_value "$1"`;;
|
||||||
--with-debug=full)
|
|
||||||
full_debug="=full";;
|
|
||||||
--warning-mode=*)
|
--warning-mode=*)
|
||||||
warning_mode=`get_key_value "$1"`;;
|
warning_mode=`get_key_value "$1"`;;
|
||||||
-c | --just-configure)
|
-c | --just-configure)
|
||||||
@ -60,7 +57,6 @@ fi
|
|||||||
prefix="/usr/local/mysql"
|
prefix="/usr/local/mysql"
|
||||||
just_print=
|
just_print=
|
||||||
just_configure=
|
just_configure=
|
||||||
full_debug=
|
|
||||||
warning_mode=
|
warning_mode=
|
||||||
maintainer_mode=
|
maintainer_mode=
|
||||||
|
|
||||||
@ -116,7 +112,6 @@ else
|
|||||||
cxx_warnings="$warnings -Wno-unused-parameter"
|
cxx_warnings="$warnings -Wno-unused-parameter"
|
||||||
# cxx_warnings="$cxx_warnings -Woverloaded-virtual -Wsign-promo"
|
# cxx_warnings="$cxx_warnings -Woverloaded-virtual -Wsign-promo"
|
||||||
cxx_warnings="$cxx_warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
|
cxx_warnings="$cxx_warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
|
||||||
# Added unless --with-debug=full
|
|
||||||
debug_extra_cflags="-O0 -g3 -gdwarf-2"
|
debug_extra_cflags="-O0 -g3 -gdwarf-2"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -141,11 +136,8 @@ base_cxxflags="-felide-constructors -fno-exceptions -fno-rtti"
|
|||||||
# Be as fast as we can be without losing our ability to backtrace.
|
# Be as fast as we can be without losing our ability to backtrace.
|
||||||
fast_cflags="-O3 -fno-omit-frame-pointer"
|
fast_cflags="-O3 -fno-omit-frame-pointer"
|
||||||
|
|
||||||
debug_configs="--with-debug$full_debug"
|
debug_configs="--with-debug"
|
||||||
if [ -z "$full_debug" ]
|
|
||||||
then
|
|
||||||
debug_cflags="$debug_cflags $debug_extra_cflags"
|
debug_cflags="$debug_cflags $debug_extra_cflags"
|
||||||
fi
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Configuration options.
|
# Configuration options.
|
||||||
|
@ -148,7 +148,6 @@ Usage: $0 [options]
|
|||||||
--extended-help Show extended help message
|
--extended-help Show extended help message
|
||||||
--without-debug Build non-debug version
|
--without-debug Build non-debug version
|
||||||
--with-debug Build debug version
|
--with-debug Build debug version
|
||||||
--with-debug=full Build with full debug.
|
|
||||||
--configure-only Stop after running configure.
|
--configure-only Stop after running configure.
|
||||||
--use-autotools Start by running autoconf, automake,.. tools
|
--use-autotools Start by running autoconf, automake,.. tools
|
||||||
--no-autotools Start from configure
|
--no-autotools Start from configure
|
||||||
@ -262,10 +261,6 @@ extended_usage()
|
|||||||
This flag prevents the use of GPL libraries which cannot be used
|
This flag prevents the use of GPL libraries which cannot be used
|
||||||
under a commercial license, such as the readline library.
|
under a commercial license, such as the readline library.
|
||||||
|
|
||||||
--with-debug[=full]
|
|
||||||
This option will ensure that the version is built with debug
|
|
||||||
information enabled; the optimisation level is decreased to -O.
|
|
||||||
|
|
||||||
--developer
|
--developer
|
||||||
This option changes a number of things to make the version built
|
This option changes a number of things to make the version built
|
||||||
more appropriate to the debugging and testing needs of developers.
|
more appropriate to the debugging and testing needs of developers.
|
||||||
@ -658,11 +653,6 @@ parse_options()
|
|||||||
--datadir=*)
|
--datadir=*)
|
||||||
datadir=`get_key_value "$1"`
|
datadir=`get_key_value "$1"`
|
||||||
;;
|
;;
|
||||||
--with-debug=full)
|
|
||||||
full_debug="=full"
|
|
||||||
with_debug_flag="yes"
|
|
||||||
fast_flag="no"
|
|
||||||
;;
|
|
||||||
--without-debug)
|
--without-debug)
|
||||||
with_debug_flag="no"
|
with_debug_flag="no"
|
||||||
if test "x$fast_flag" != "xyes" ; then
|
if test "x$fast_flag" != "xyes" ; then
|
||||||
@ -1044,10 +1034,7 @@ set_warning_flags()
|
|||||||
# C++ warnings
|
# C++ warnings
|
||||||
cxx_warnings="$warnings -Woverloaded-virtual -Wsign-promo -Wreorder"
|
cxx_warnings="$warnings -Woverloaded-virtual -Wsign-promo -Wreorder"
|
||||||
cxx_warnings="$warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
|
cxx_warnings="$warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
|
||||||
# Added unless --with-debug=full
|
|
||||||
if test "x$full_debug" = "x" ; then
|
|
||||||
compiler_flags="$compiler_flags -Wuninitialized"
|
compiler_flags="$compiler_flags -Wuninitialized"
|
||||||
fi
|
|
||||||
elif test "x$warning_mode" = "xpedantic" ; then
|
elif test "x$warning_mode" = "xpedantic" ; then
|
||||||
warnings="-W -Wall -ansi -pedantic -Wno-long-long -D_POSIX_SOURCE"
|
warnings="-W -Wall -ansi -pedantic -Wno-long-long -D_POSIX_SOURCE"
|
||||||
c_warnings="$warnings"
|
c_warnings="$warnings"
|
||||||
@ -1113,7 +1100,7 @@ set_base_configs()
|
|||||||
base_configs="$base_configs --localstatedir=$datadir"
|
base_configs="$base_configs --localstatedir=$datadir"
|
||||||
fi
|
fi
|
||||||
if test "x$with_debug_flag" = "xyes" ; then
|
if test "x$with_debug_flag" = "xyes" ; then
|
||||||
base_configs="$base_configs --with-debug$full_debug"
|
base_configs="$base_configs --with-debug"
|
||||||
fi
|
fi
|
||||||
base_configs="$base_configs --enable-local-infile"
|
base_configs="$base_configs --enable-local-infile"
|
||||||
base_configs="$base_configs --enable-thread-safe-client"
|
base_configs="$base_configs --enable-thread-safe-client"
|
||||||
@ -1546,7 +1533,6 @@ gpl="yes"
|
|||||||
version_text=
|
version_text=
|
||||||
developer_flag="no"
|
developer_flag="no"
|
||||||
just_configure=
|
just_configure=
|
||||||
full_debug=
|
|
||||||
warning_mode=
|
warning_mode=
|
||||||
with_flags=
|
with_flags=
|
||||||
error_inject_flag=
|
error_inject_flag=
|
||||||
|
146
BUILD/check-cpu
146
BUILD/check-cpu
@ -7,6 +7,79 @@
|
|||||||
# check_cpu_args : Arguments for GCC compiler settings
|
# check_cpu_args : Arguments for GCC compiler settings
|
||||||
#
|
#
|
||||||
|
|
||||||
|
check_compiler_cpu_flags () {
|
||||||
|
# different compiler versions have different option names
|
||||||
|
# for CPU specific command line options
|
||||||
|
if test -z "$CC" ; then
|
||||||
|
cc="gcc";
|
||||||
|
else
|
||||||
|
cc=$CC
|
||||||
|
fi
|
||||||
|
|
||||||
|
# check if compiler is gcc and dump its version
|
||||||
|
cc_verno=`$cc -dumpversion 2>/dev/null`
|
||||||
|
if test "x$?" = "x0" ; then
|
||||||
|
set -- `echo $cc_verno | tr '.' ' '`
|
||||||
|
cc_ver="GCC"
|
||||||
|
cc_major=$1
|
||||||
|
cc_minor=$2
|
||||||
|
cc_patch=$3
|
||||||
|
cc_comp=`expr $cc_major '*' 100 '+' $cc_minor`
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$cc_ver--$cc_verno" in
|
||||||
|
*GCC*)
|
||||||
|
# different gcc backends (and versions) have different CPU flags
|
||||||
|
case `gcc -dumpmachine` in
|
||||||
|
i?86-* | x86_64-*)
|
||||||
|
if test "$cc_comp" -lt 304 ; then
|
||||||
|
check_cpu_cflags="-mcpu=${cpu_arg}"
|
||||||
|
elif test "$cc_comp" -ge 402 ; then
|
||||||
|
check_cpu_cflags="-mtune=native"
|
||||||
|
else
|
||||||
|
check_cpu_cflags="-mtune=${cpu_arg}"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
ppc-*)
|
||||||
|
check_cpu_cflags="-mcpu=${cpu_arg} -mtune=${cpu_arg}"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
check_cpu_cflags=""
|
||||||
|
return
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
2.95.*)
|
||||||
|
# GCC 2.95 doesn't expose its name in --version output
|
||||||
|
check_cpu_cflags="-m${cpu_arg}"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
check_cpu_cflags=""
|
||||||
|
return
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# now we check whether the compiler really understands the cpu type
|
||||||
|
touch __test.c
|
||||||
|
|
||||||
|
while [ "$cpu_arg" ] ; do
|
||||||
|
printf "testing $cpu_arg ... " >&2
|
||||||
|
|
||||||
|
# compile check
|
||||||
|
eval "$cc -c $check_cpu_cflags __test.c" 2>/dev/null
|
||||||
|
if test "x$?" = "x0" ; then
|
||||||
|
echo ok >&2
|
||||||
|
break;
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo failed >&2
|
||||||
|
check_cpu_cflags=""
|
||||||
|
break;
|
||||||
|
done
|
||||||
|
rm __test.*
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
check_cpu () {
|
check_cpu () {
|
||||||
CPUINFO=/proc/cpuinfo
|
CPUINFO=/proc/cpuinfo
|
||||||
if test -n "$TEST_CPUINFO" ; then
|
if test -n "$TEST_CPUINFO" ; then
|
||||||
@ -179,83 +252,14 @@ check_cpu () {
|
|||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# different compiler versions have different option names
|
if test "x$compiler" = "x" ; then
|
||||||
# for CPU specific command line options
|
check_compiler_cpu_flags
|
||||||
if test -z "$CC" ; then
|
|
||||||
cc="gcc";
|
|
||||||
else
|
|
||||||
cc=$CC
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$core2" = "xyes" ; then
|
if test "x$core2" = "xyes" ; then
|
||||||
cpu_arg="core2"
|
cpu_arg="core2"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$compiler" != "x" ; then
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
# check if compiler is gcc and dump its version
|
|
||||||
cc_verno=`$cc -dumpversion 2>/dev/null`
|
|
||||||
if test "x$?" = "x0" ; then
|
|
||||||
set -- `echo $cc_verno | tr '.' ' '`
|
|
||||||
cc_ver="GCC"
|
|
||||||
cc_major=$1
|
|
||||||
cc_minor=$2
|
|
||||||
cc_patch=$3
|
|
||||||
cc_comp=`expr $cc_major '*' 100 '+' $cc_minor`
|
|
||||||
fi
|
|
||||||
|
|
||||||
case "$cc_ver--$cc_verno" in
|
|
||||||
*GCC*)
|
|
||||||
# different gcc backends (and versions) have different CPU flags
|
|
||||||
case `gcc -dumpmachine` in
|
|
||||||
i?86-* | x86_64-*)
|
|
||||||
if test "$cc_comp" -lt 304 ; then
|
|
||||||
check_cpu_cflags="-mcpu=${cpu_arg}"
|
|
||||||
elif test "$cc_comp" -ge 402 ; then
|
|
||||||
check_cpu_cflags="-mtune=native"
|
|
||||||
else
|
|
||||||
check_cpu_cflags="-mtune=${cpu_arg}"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
ppc-*)
|
|
||||||
check_cpu_cflags="-mcpu=${cpu_arg} -mtune=${cpu_arg}"
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
check_cpu_cflags=""
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
;;
|
|
||||||
2.95.*)
|
|
||||||
# GCC 2.95 doesn't expose its name in --version output
|
|
||||||
check_cpu_cflags="-m${cpu_arg}"
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
check_cpu_cflags=""
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# now we check whether the compiler really understands the cpu type
|
|
||||||
touch __test.c
|
|
||||||
|
|
||||||
while [ "$cpu_arg" ] ; do
|
|
||||||
printf "testing $cpu_arg ... " >&2
|
|
||||||
|
|
||||||
# compile check
|
|
||||||
eval "$cc -c $check_cpu_cflags __test.c" 2>/dev/null
|
|
||||||
if test "x$?" = "x0" ; then
|
|
||||||
echo ok >&2
|
|
||||||
break;
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo failed >&2
|
|
||||||
check_cpu_cflags=""
|
|
||||||
break;
|
|
||||||
done
|
|
||||||
rm __test.*
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4,16 +4,6 @@ path=`dirname $0`
|
|||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_configs="$max_configs --with-ndb-test --with-ndb-ccflags='-DERROR_INSERT'"
|
extra_configs="$max_configs --with-ndb-test --with-ndb-ccflags='-DERROR_INSERT'"
|
||||||
if [ "$full_debug" ]
|
extra_flags="$fast_cflags $max_cflags -g"
|
||||||
then
|
|
||||||
extra_flags="$debug_cflags"
|
|
||||||
c_warnings="$c_warnings $debug_extra_warnings"
|
|
||||||
cxx_warnings="$cxx_warnings $debug_extra_warnings"
|
|
||||||
extra_configs="$debug_configs $extra_configs"
|
|
||||||
else
|
|
||||||
extra_flags="$fast_cflags"
|
|
||||||
fi
|
|
||||||
|
|
||||||
extra_flags="$extra_flags $max_cflags -g"
|
|
||||||
|
|
||||||
. "$path/FINISH.sh"
|
. "$path/FINISH.sh"
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
|
|
||||||
path=`dirname $0`
|
path=`dirname $0`
|
||||||
set -- "$@" --with-debug=full
|
|
||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_flags="$pentium_cflags $debug_cflags"
|
extra_flags="$pentium_cflags $debug_cflags"
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
|
|
||||||
path=`dirname $0`
|
path=`dirname $0`
|
||||||
set -- "$@" --with-debug=full
|
|
||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_flags="$pentium_cflags $debug_cflags"
|
extra_flags="$pentium_cflags $debug_cflags"
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
|
|
||||||
path=`dirname $0`
|
path=`dirname $0`
|
||||||
set -- "$@" --with-debug=full
|
|
||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_flags="$pentium_cflags $debug_cflags"
|
extra_flags="$pentium_cflags $debug_cflags"
|
||||||
|
@ -6,6 +6,6 @@ path=`dirname $0`
|
|||||||
extra_flags="$pentium_cflags $debug_cflags"
|
extra_flags="$pentium_cflags $debug_cflags"
|
||||||
extra_configs="$pentium_configs $debug_configs"
|
extra_configs="$pentium_configs $debug_configs"
|
||||||
|
|
||||||
extra_configs="$extra_configs --with-debug=full --with-ssl=/usr"
|
extra_configs="$extra_configs --with-debug --with-ssl=/usr"
|
||||||
|
|
||||||
. "$path/FINISH.sh"
|
. "$path/FINISH.sh"
|
||||||
|
@ -6,6 +6,6 @@ path=`dirname $0`
|
|||||||
extra_flags="$pentium_cflags $debug_cflags"
|
extra_flags="$pentium_cflags $debug_cflags"
|
||||||
extra_configs="$pentium_configs $debug_configs"
|
extra_configs="$pentium_configs $debug_configs"
|
||||||
|
|
||||||
extra_configs="$extra_configs --with-debug=full --with-ssl"
|
extra_configs="$extra_configs --with-debug --with-ssl"
|
||||||
|
|
||||||
. "$path/FINISH.sh"
|
. "$path/FINISH.sh"
|
||||||
|
@ -1,11 +0,0 @@
|
|||||||
#! /bin/sh
|
|
||||||
|
|
||||||
path=`dirname $0`
|
|
||||||
. "$path/SETUP.sh"
|
|
||||||
|
|
||||||
extra_flags="$pentium_cflags $debug_cflags"
|
|
||||||
extra_configs="$pentium_configs $debug_configs $static_link"
|
|
||||||
|
|
||||||
extra_configs="$extra_configs --with-debug=full --with-mysqlfs --without-server --without-pstack"
|
|
||||||
|
|
||||||
. "$path/FINISH.sh"
|
|
@ -1,7 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
|
|
||||||
path=`dirname $0`
|
path=`dirname $0`
|
||||||
set -- "$@" --with-debug=full
|
|
||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_flags="$pentium64_cflags $debug_cflags"
|
extra_flags="$pentium64_cflags $debug_cflags"
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
|
|
||||||
path=`dirname $0`
|
path=`dirname $0`
|
||||||
set -- "$@" --with-debug=full
|
|
||||||
. "$path/SETUP.sh"
|
. "$path/SETUP.sh"
|
||||||
|
|
||||||
extra_flags="$pentium64_cflags $debug_cflags"
|
extra_flags="$pentium64_cflags $debug_cflags"
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006-2008 MySQL AB, 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -34,7 +34,6 @@ ENDIF()
|
|||||||
SET(CUSTOM_C_FLAGS $ENV{CFLAGS})
|
SET(CUSTOM_C_FLAGS $ENV{CFLAGS})
|
||||||
|
|
||||||
OPTION(WITH_DEBUG "Use dbug/safemutex" OFF)
|
OPTION(WITH_DEBUG "Use dbug/safemutex" OFF)
|
||||||
OPTION(WITH_DEBUG_FULL "Use dbug and safemutex. Slow." OFF)
|
|
||||||
|
|
||||||
# Distinguish between community and non-community builds, with the
|
# Distinguish between community and non-community builds, with the
|
||||||
# default being a community build. This does not impact the feature
|
# default being a community build. This does not impact the feature
|
||||||
@ -46,7 +45,8 @@ OPTION(COMMUNITY_BUILD "Set to true if this is a community build" ON)
|
|||||||
SET(MANUFACTURER_DOCSTRING
|
SET(MANUFACTURER_DOCSTRING
|
||||||
"Set the entity that appears as the manufacturer of packages that support a manufacturer field.")
|
"Set the entity that appears as the manufacturer of packages that support a manufacturer field.")
|
||||||
IF(NOT DEFINED MANUFACTURER)
|
IF(NOT DEFINED MANUFACTURER)
|
||||||
SET(MANUFACTURER "Built from Source" CACHE BOOL ${MANUFACTURER_DOCSTRING})
|
SET(MANUFACTURER "Built from Source" CACHE STRING ${MANUFACTURER_DOCSTRING})
|
||||||
|
MARK_AS_ADVANCED(MANUFACTURER)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
# We choose to provide WITH_DEBUG as alias to standard CMAKE_BUILD_TYPE=Debug
|
# We choose to provide WITH_DEBUG as alias to standard CMAKE_BUILD_TYPE=Debug
|
||||||
@ -59,7 +59,7 @@ SET(BUILDTYPE_DOCSTRING
|
|||||||
"Choose the type of build, options are: None(CMAKE_CXX_FLAGS or
|
"Choose the type of build, options are: None(CMAKE_CXX_FLAGS or
|
||||||
CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel")
|
CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel")
|
||||||
|
|
||||||
IF(WITH_DEBUG OR WITH_DEBUG_FULL)
|
IF(WITH_DEBUG)
|
||||||
SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE)
|
SET(CMAKE_BUILD_TYPE "Debug" CACHE STRING ${BUILDTYPE_DOCSTRING} FORCE)
|
||||||
SET(OLD_WITH_DEBUG 1 CACHE INTERNAL "" FORCE)
|
SET(OLD_WITH_DEBUG 1 CACHE INTERNAL "" FORCE)
|
||||||
ELSEIF(NOT HAVE_CMAKE_BUILD_TYPE OR OLD_WITH_DEBUG)
|
ELSEIF(NOT HAVE_CMAKE_BUILD_TYPE OR OLD_WITH_DEBUG)
|
||||||
@ -161,13 +161,6 @@ IF(ENABLE_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")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
OPTION(WITH_ERROR_INJECT
|
|
||||||
"Enable error injection in MySQL Server (debug builds only)" OFF)
|
|
||||||
IF(WITH_ERROR_INJECT)
|
|
||||||
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DERROR_INJECT_SUPPORT")
|
|
||||||
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DERROR_INJECT_SUPPORT")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
OPTION(ENABLED_LOCAL_INFILE
|
OPTION(ENABLED_LOCAL_INFILE
|
||||||
"If we should should enable LOAD DATA LOCAL by default" ${IF_WIN})
|
"If we should should enable LOAD DATA LOCAL by default" ${IF_WIN})
|
||||||
MARK_AS_ADVANCED(ENABLED_LOCAL_INFILE)
|
MARK_AS_ADVANCED(ENABLED_LOCAL_INFILE)
|
||||||
@ -201,15 +194,10 @@ ENDIF()
|
|||||||
|
|
||||||
# Add safemutex for debug configurations, except on Windows
|
# Add safemutex for debug configurations, except on Windows
|
||||||
# (safemutex has never worked on Windows)
|
# (safemutex has never worked on Windows)
|
||||||
IF(WITH_DEBUG OR WITH_DEBUG_FULL AND NOT WIN32)
|
IF(WITH_DEBUG AND NOT WIN32)
|
||||||
FOREACH(LANG C CXX)
|
FOREACH(LANG C CXX)
|
||||||
IF(WITH_DEBUG_FULL)
|
|
||||||
SET(CMAKE_${LANG}_FLAGS_DEBUG
|
SET(CMAKE_${LANG}_FLAGS_DEBUG
|
||||||
"${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
|
"${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
|
||||||
ELSE()
|
|
||||||
SET(CMAKE_${LANG}_FLAGS_DEBUG
|
|
||||||
"${CMAKE_${LANG}_FLAGS_DEBUG} -DSAFE_MUTEX")
|
|
||||||
ENDIF()
|
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -209,6 +209,9 @@ static void add_one_option(DYNAMIC_STRING* ds,
|
|||||||
case GET_STR:
|
case GET_STR:
|
||||||
arg= argument;
|
arg= argument;
|
||||||
break;
|
break;
|
||||||
|
case GET_BOOL:
|
||||||
|
arg= (*(my_bool *)opt->value) ? "1" : "0";
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
die("internal error at %s: %d",__FILE__, __LINE__);
|
die("internal error at %s: %d",__FILE__, __LINE__);
|
||||||
}
|
}
|
||||||
|
@ -179,11 +179,6 @@ foreach my $option (@ARGV)
|
|||||||
$cmakeargs = $cmakeargs." -DMYSQL_DATADIR=".substr($option,14);
|
$cmakeargs = $cmakeargs." -DMYSQL_DATADIR=".substr($option,14);
|
||||||
next;
|
next;
|
||||||
}
|
}
|
||||||
if ($option =~ /with-debug=full/)
|
|
||||||
{
|
|
||||||
$cmakeargs = $cmakeargs." -DWITH_DEBUG_FULL=1";
|
|
||||||
next;
|
|
||||||
}
|
|
||||||
if ($option =~ /mysql-maintainer-mode/)
|
if ($option =~ /mysql-maintainer-mode/)
|
||||||
{
|
{
|
||||||
$cmakeargs = $cmakeargs." -DMYSQL_MAINTAINER_MODE=" .
|
$cmakeargs = $cmakeargs." -DMYSQL_MAINTAINER_MODE=" .
|
||||||
|
@ -57,11 +57,17 @@ MACRO(MYSQL_ADD_PLUGIN)
|
|||||||
SET(WITHOUT_NDBCLUSTER 1)
|
SET(WITHOUT_NDBCLUSTER 1)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
IF(ARG_DEFAULT)
|
||||||
|
IF(NOT DEFINED WITH_${plugin} AND
|
||||||
|
NOT DEFINED WITH_${plugin}_STORAGE_ENGINE)
|
||||||
|
SET(WITH_${plugin} 1)
|
||||||
|
ENDIF()
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
IF(WITH_${plugin}_STORAGE_ENGINE
|
IF(WITH_${plugin}_STORAGE_ENGINE
|
||||||
OR WITH_{$plugin}
|
OR WITH_{$plugin}
|
||||||
OR WITH_ALL
|
OR WITH_ALL
|
||||||
OR WITH_MAX
|
OR WITH_MAX
|
||||||
OR ARG_DEFAULT
|
|
||||||
AND NOT WITHOUT_${plugin}_STORAGE_ENGINE
|
AND NOT WITHOUT_${plugin}_STORAGE_ENGINE
|
||||||
AND NOT WITHOUT_${plugin}
|
AND NOT WITHOUT_${plugin}
|
||||||
AND NOT ARG_MODULE_ONLY)
|
AND NOT ARG_MODULE_ONLY)
|
||||||
@ -88,6 +94,7 @@ MACRO(MYSQL_ADD_PLUGIN)
|
|||||||
IF(NOT ARG_DEPENDENCIES)
|
IF(NOT ARG_DEPENDENCIES)
|
||||||
SET(ARG_DEPENDENCIES)
|
SET(ARG_DEPENDENCIES)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
SET(BUILD_PLUGIN 1)
|
||||||
# Build either static library or module
|
# Build either static library or module
|
||||||
IF (WITH_${plugin} AND NOT ARG_MODULE_ONLY)
|
IF (WITH_${plugin} AND NOT ARG_MODULE_ONLY)
|
||||||
ADD_LIBRARY(${target} STATIC ${SOURCES})
|
ADD_LIBRARY(${target} STATIC ${SOURCES})
|
||||||
@ -148,9 +155,6 @@ MACRO(MYSQL_ADD_PLUGIN)
|
|||||||
DTRACE_INSTRUMENT(${target})
|
DTRACE_INSTRUMENT(${target})
|
||||||
SET_TARGET_PROPERTIES (${target} PROPERTIES PREFIX ""
|
SET_TARGET_PROPERTIES (${target} PROPERTIES PREFIX ""
|
||||||
COMPILE_DEFINITIONS "MYSQL_DYNAMIC_PLUGIN")
|
COMPILE_DEFINITIONS "MYSQL_DYNAMIC_PLUGIN")
|
||||||
IF(ARG_LINK_LIBRARIES)
|
|
||||||
TARGET_LINK_LIBRARIES (${target} ${ARG_LINK_LIBRARIES})
|
|
||||||
ENDIF()
|
|
||||||
TARGET_LINK_LIBRARIES (${target} mysqlservices)
|
TARGET_LINK_LIBRARIES (${target} mysqlservices)
|
||||||
|
|
||||||
# Plugin uses symbols defined in mysqld executable.
|
# Plugin uses symbols defined in mysqld executable.
|
||||||
@ -175,7 +179,20 @@ MACRO(MYSQL_ADD_PLUGIN)
|
|||||||
# Install dynamic library
|
# Install dynamic library
|
||||||
MYSQL_INSTALL_TARGETS(${target} DESTINATION ${INSTALL_PLUGINDIR} COMPONENT Server)
|
MYSQL_INSTALL_TARGETS(${target} DESTINATION ${INSTALL_PLUGINDIR} COMPONENT Server)
|
||||||
INSTALL_DEBUG_TARGET(${target} DESTINATION ${INSTALL_PLUGINDIR}/debug)
|
INSTALL_DEBUG_TARGET(${target} DESTINATION ${INSTALL_PLUGINDIR}/debug)
|
||||||
|
ELSE()
|
||||||
|
IF(WITHOUT_${plugin})
|
||||||
|
# Update cache variable
|
||||||
|
STRING(REPLACE "WITH_" "WITHOUT_" without_var ${with_var})
|
||||||
|
SET(${without_var} ON CACHE BOOL "Don't build ${plugin}"
|
||||||
|
FORCE)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
SET(BUILD_PLUGIN 0)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
IF(BUILD_PLUGIN AND ARG_LINK_LIBRARIES)
|
||||||
|
TARGET_LINK_LIBRARIES (${target} ${ARG_LINK_LIBRARIES})
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
ENDMACRO()
|
ENDMACRO()
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2007 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -206,7 +206,7 @@ AC_DEFUN([MYSQL_SETUP_NDBCLUSTER], [
|
|||||||
NDB_DEFS="-DNDB_DEBUG_FULL -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD"
|
NDB_DEFS="-DNDB_DEBUG_FULL -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD"
|
||||||
else
|
else
|
||||||
# no extra ndb debug but still do asserts if debug version
|
# no extra ndb debug but still do asserts if debug version
|
||||||
if test "$with_debug" = "yes" -o "$with_debug" = "full"
|
if test "$with_debug" = "yes"
|
||||||
then
|
then
|
||||||
NDB_DEFS=""
|
NDB_DEFS=""
|
||||||
else
|
else
|
||||||
|
25
configure.in
25
configure.in
@ -1732,22 +1732,14 @@ then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
AC_ARG_WITH(debug,
|
AC_ARG_WITH(debug,
|
||||||
[ --with-debug Add debug code
|
[AS_HELP_STRING([--with-debug], [Add debug code @<:@default=no@:>@])],
|
||||||
--with-debug=full Add debug code (adds memory checker, very slow)],
|
|
||||||
[with_debug=$withval],
|
[with_debug=$withval],
|
||||||
[with_debug=no])
|
[with_debug=no])
|
||||||
if test "$with_debug" = "yes"
|
if test "$with_debug" = "yes"
|
||||||
then
|
then
|
||||||
# Medium debug.
|
|
||||||
AC_DEFINE([DBUG_ON], [1], [Use libdbug])
|
AC_DEFINE([DBUG_ON], [1], [Use libdbug])
|
||||||
CFLAGS="$DEBUG_CFLAGS $DEBUG_OPTIMIZE_CC -DSAFE_MUTEX $CFLAGS"
|
CFLAGS="$DEBUG_CFLAGS $DEBUG_OPTIMIZE_CC -DSAFE_MUTEX $CFLAGS"
|
||||||
CXXFLAGS="$DEBUG_CXXFLAGS $DEBUG_OPTIMIZE_CXX -DSAFE_MUTEX $CXXFLAGS"
|
CXXFLAGS="$DEBUG_CXXFLAGS $DEBUG_OPTIMIZE_CXX -DSAFE_MUTEX $CXXFLAGS"
|
||||||
elif test "$with_debug" = "full"
|
|
||||||
then
|
|
||||||
# Full debug. Very slow in some cases
|
|
||||||
AC_DEFINE([DBUG_ON], [1], [Use libdbug])
|
|
||||||
CFLAGS="$DEBUG_CFLAGS -DSAFE_MUTEX $CFLAGS"
|
|
||||||
CXXFLAGS="$DEBUG_CXXFLAGS -DSAFE_MUTEX $CXXFLAGS"
|
|
||||||
else
|
else
|
||||||
# Optimized version. No debug
|
# Optimized version. No debug
|
||||||
AC_DEFINE([DBUG_OFF], [1], [Don't use libdbug])
|
AC_DEFINE([DBUG_OFF], [1], [Don't use libdbug])
|
||||||
@ -1783,21 +1775,6 @@ else
|
|||||||
AC_MSG_RESULT([no])
|
AC_MSG_RESULT([no])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# If we should allow error injection tests
|
|
||||||
AC_ARG_WITH(error-inject,
|
|
||||||
AC_HELP_STRING([--with-error-inject],[Enable error injection in MySQL Server]),
|
|
||||||
[ with_error_inject=$withval ],
|
|
||||||
[ with_error_inject=no ])
|
|
||||||
|
|
||||||
if test $with_debug != "no"
|
|
||||||
then
|
|
||||||
if test "$with_error_inject" = "yes"
|
|
||||||
then
|
|
||||||
AC_DEFINE([ERROR_INJECT_SUPPORT], [1],
|
|
||||||
[Enable error injection in MySQL Server])
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_ARG_WITH([fast-mutexes],
|
AC_ARG_WITH([fast-mutexes],
|
||||||
AC_HELP_STRING([--with-fast-mutexes],
|
AC_HELP_STRING([--with-fast-mutexes],
|
||||||
[Compile with fast mutexes (default is disabled)]),
|
[Compile with fast mutexes (default is disabled)]),
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(
|
INCLUDE_DIRECTORIES(
|
||||||
${CMAKE_SOURCE_DIR}/include
|
${CMAKE_SOURCE_DIR}/include
|
||||||
${ZLIB_INCLUDE_DIR}
|
${ZLIB_INCLUDE_DIR}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -200,7 +200,7 @@ if (`SELECT $CRC_ARG_type = 1`) {
|
|||||||
if (`SELECT $CRC_ARG_type = 2`) {
|
if (`SELECT $CRC_ARG_type = 2`) {
|
||||||
# It will be unsafe to call this procedure.
|
# It will be unsafe to call this procedure.
|
||||||
--let $CRC_name= proc_$CRC_ARG_level
|
--let $CRC_name= proc_$CRC_ARG_level
|
||||||
--let $CRC_create= CREATE PROCEDURE $CRC_name() BEGIN INSERT INTO ta$CRC_ARG_level VALUES (47); $CRC_ARG_stmt_sidef; END
|
--let $CRC_create= CREATE PROCEDURE $CRC_name() BEGIN $CRC_ARG_stmt_sidef; INSERT INTO ta$CRC_ARG_level VALUES (47); END
|
||||||
--let $CRC_RET_stmt_sidef= CALL $CRC_name()
|
--let $CRC_RET_stmt_sidef= CALL $CRC_name()
|
||||||
--let $CRC_RET_value=
|
--let $CRC_RET_value=
|
||||||
--let $CRC_RET_sel_retval=
|
--let $CRC_RET_sel_retval=
|
||||||
@ -344,25 +344,8 @@ if (`SELECT '$CRC_RET_stmt_sidef' != ''`) {
|
|||||||
if (`SELECT '$event_type' != 'Table_map'`) {
|
if (`SELECT '$event_type' != 'Table_map'`) {
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--echo ******** Failure! Event number 3 was a '$event_type', not a 'Table_map'. ********
|
--echo ******** Failure! Event number 3 was a '$event_type', not a 'Table_map'. ********
|
||||||
|
SHOW BINLOG EVENTS;
|
||||||
# Currently, there is a bug causing some statements to be logged
|
--die Wrong events in binlog.
|
||||||
# partially in statement format. Hence, we don't fail here, we
|
|
||||||
# just print the events (masking out nondeterministic components
|
|
||||||
# of the output) and continue. When binloggging works perfectly,
|
|
||||||
# we should instead execute:
|
|
||||||
#--enable_query_log
|
|
||||||
#SHOW BINLOG EVENTS;
|
|
||||||
#--die Wrong events in binlog.
|
|
||||||
|
|
||||||
# Here, we should really source
|
|
||||||
# include/show_binlog_events.inc. But due to BUG#41913, that
|
|
||||||
# doesn't work, and we have to inline the entire file here. Sigh
|
|
||||||
# :-(
|
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR 107 <binlog_start>
|
|
||||||
--replace_column 2 # 4 # 5 #
|
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/ /file_id=[0-9]+/file_id=#/ /block_len=[0-9]+/block_len=#/
|
|
||||||
--eval SHOW BINLOG EVENTS FROM 107
|
|
||||||
--disable_query_log
|
|
||||||
}
|
}
|
||||||
SET binlog_format = STATEMENT;
|
SET binlog_format = STATEMENT;
|
||||||
|
|
||||||
|
30
mysql-test/include/mysql_upgrade_preparation.inc
Normal file
30
mysql-test/include/mysql_upgrade_preparation.inc
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
# Include this in any test using mysql_upgrade
|
||||||
|
|
||||||
|
# Can't run test of external client with embedded server
|
||||||
|
-- source include/not_embedded.inc
|
||||||
|
|
||||||
|
# Only run test if "mysql_upgrade" is found
|
||||||
|
--require r/have_mysql_upgrade.result
|
||||||
|
--disable_query_log
|
||||||
|
select LENGTH("$MYSQL_UPGRADE")>0 as have_mysql_upgrade;
|
||||||
|
--enable_query_log
|
||||||
|
|
||||||
|
#
|
||||||
|
# Hack:
|
||||||
|
#
|
||||||
|
# If running with Valgrind ($VALGRIND_TEST <> 0) then the resource
|
||||||
|
# consumption (CPU) for upgrading a large log table will be intense.
|
||||||
|
# Therefore, truncate the log table in advance and issue a statement
|
||||||
|
# that should be logged.
|
||||||
|
#
|
||||||
|
if (`SELECT $VALGRIND_TEST`)
|
||||||
|
{
|
||||||
|
--disable_query_log
|
||||||
|
--disable_result_log
|
||||||
|
--disable_abort_on_error
|
||||||
|
TRUNCATE TABLE mysql.general_log;
|
||||||
|
SELECT 1;
|
||||||
|
--enable_abort_on_error
|
||||||
|
--enable_result_log
|
||||||
|
--enable_query_log
|
||||||
|
}
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -3126,6 +3126,15 @@ sub install_db ($$) {
|
|||||||
mtr_add_arg($args, "--lc-messages-dir=%s", $path_language);
|
mtr_add_arg($args, "--lc-messages-dir=%s", $path_language);
|
||||||
mtr_add_arg($args, "--character-sets-dir=%s", $path_charsetsdir);
|
mtr_add_arg($args, "--character-sets-dir=%s", $path_charsetsdir);
|
||||||
|
|
||||||
|
# InnoDB arguments that affect file location and sizes may
|
||||||
|
# need to be given to the bootstrap process as well as the
|
||||||
|
# server process.
|
||||||
|
foreach my $extra_opt ( @opt_extra_mysqld_opt ) {
|
||||||
|
if ($extra_opt =~ /--innodb/) {
|
||||||
|
mtr_add_arg($args, $extra_opt);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
|
# If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
|
||||||
# configure --disable-grant-options), mysqld will not recognize the
|
# configure --disable-grant-options), mysqld will not recognize the
|
||||||
# --bootstrap or --skip-grant-tables options. The user can set
|
# --bootstrap or --skip-grant-tables options. The user can set
|
||||||
@ -3925,11 +3934,6 @@ sub mysqld_arguments ($$$$) {
|
|||||||
|
|
||||||
mtr_add_arg($args, "%s--local-infile", $prefix);
|
mtr_add_arg($args, "%s--local-infile", $prefix);
|
||||||
|
|
||||||
if ( $idx > 0 or !$use_innodb)
|
|
||||||
{
|
|
||||||
mtr_add_arg($args, "%s--loose-skip-innodb", $prefix);
|
|
||||||
}
|
|
||||||
|
|
||||||
my $cluster= $clusters->[$mysqld->{'cluster'}];
|
my $cluster= $clusters->[$mysqld->{'cluster'}];
|
||||||
if ( $cluster->{'pid'} || # Cluster is started
|
if ( $cluster->{'pid'} || # Cluster is started
|
||||||
$cluster->{'use_running'} ) # Using running cluster
|
$cluster->{'use_running'} ) # Using running cluster
|
||||||
|
@ -2888,6 +2888,15 @@ sub mysql_install_db {
|
|||||||
mtr_add_arg($args, "--lc-messages-dir=%s", $install_lang);
|
mtr_add_arg($args, "--lc-messages-dir=%s", $install_lang);
|
||||||
mtr_add_arg($args, "--character-sets-dir=%s", $install_chsdir);
|
mtr_add_arg($args, "--character-sets-dir=%s", $install_chsdir);
|
||||||
|
|
||||||
|
# InnoDB arguments that affect file location and sizes may
|
||||||
|
# need to be given to the bootstrap process as well as the
|
||||||
|
# server process.
|
||||||
|
foreach my $extra_opt ( @opt_extra_mysqld_opt ) {
|
||||||
|
if ($extra_opt =~ /--innodb/) {
|
||||||
|
mtr_add_arg($args, $extra_opt);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
|
# If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
|
||||||
# configure --disable-grant-options), mysqld will not recognize the
|
# configure --disable-grant-options), mysqld will not recognize the
|
||||||
# --bootstrap or --skip-grant-tables options. The user can set
|
# --bootstrap or --skip-grant-tables options. The user can set
|
||||||
|
@ -1714,3 +1714,14 @@ NULL NULL NULL NULL NULL
|
|||||||
drop table t1;
|
drop table t1;
|
||||||
#
|
#
|
||||||
End of 5.1 tests
|
End of 5.1 tests
|
||||||
|
#
|
||||||
|
# Bug#55648: Server crash on MIX/MAX on maximum time value
|
||||||
|
#
|
||||||
|
CREATE TABLE t1(c1 TIME NOT NULL);
|
||||||
|
INSERT INTO t1 VALUES('837:59:59');
|
||||||
|
INSERT INTO t1 VALUES('838:59:59');
|
||||||
|
SELECT MAX(c1) FROM t1;
|
||||||
|
MAX(c1)
|
||||||
|
838:59:59
|
||||||
|
DROP TABLE t1;
|
||||||
|
# End of the bug#55648
|
||||||
|
32
mysql-test/r/mysql_upgrade_ssl.result
Normal file
32
mysql-test/r/mysql_upgrade_ssl.result
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
#
|
||||||
|
# Bug#55672 mysql_upgrade dies with internal error
|
||||||
|
#
|
||||||
|
mtr.global_suppressions OK
|
||||||
|
mtr.test_suppressions OK
|
||||||
|
mysql.columns_priv OK
|
||||||
|
mysql.db OK
|
||||||
|
mysql.event OK
|
||||||
|
mysql.func OK
|
||||||
|
mysql.general_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
|
mysql.help_category OK
|
||||||
|
mysql.help_keyword OK
|
||||||
|
mysql.help_relation OK
|
||||||
|
mysql.help_topic OK
|
||||||
|
mysql.host OK
|
||||||
|
mysql.ndb_binlog_index OK
|
||||||
|
mysql.plugin OK
|
||||||
|
mysql.proc OK
|
||||||
|
mysql.procs_priv OK
|
||||||
|
mysql.servers OK
|
||||||
|
mysql.slow_log
|
||||||
|
Error : You can't use locks with log tables.
|
||||||
|
status : OK
|
||||||
|
mysql.tables_priv OK
|
||||||
|
mysql.time_zone OK
|
||||||
|
mysql.time_zone_leap_second OK
|
||||||
|
mysql.time_zone_name OK
|
||||||
|
mysql.time_zone_transition OK
|
||||||
|
mysql.time_zone_transition_type OK
|
||||||
|
mysql.user OK
|
@ -28,6 +28,25 @@ INSERT INTO t1 VALUES (1,2), (2,3);
|
|||||||
UPDATE t1 SET b='4' WHERE a=1 LIMIT 1;
|
UPDATE t1 SET b='4' WHERE a=1 LIMIT 1;
|
||||||
UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1;
|
UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1 (a VARCHAR(1000));
|
||||||
|
INSERT INTO t1 VALUES (CURRENT_USER());
|
||||||
|
INSERT INTO t1 VALUES (FOUND_ROWS());
|
||||||
|
INSERT INTO t1 VALUES (GET_LOCK('tmp', 1));
|
||||||
|
INSERT INTO t1 VALUES (IS_FREE_LOCK('tmp'));
|
||||||
|
INSERT INTO t1 VALUES (IS_USED_LOCK('tmp'));
|
||||||
|
INSERT INTO t1 VALUES (LOAD_FILE('../../std_data/words2.dat'));
|
||||||
|
INSERT INTO t1 VALUES (MASTER_POS_WAIT('dummy arg', 4711, 1));
|
||||||
|
INSERT INTO t1 VALUES (RELEASE_LOCK('tmp'));
|
||||||
|
INSERT INTO t1 VALUES (ROW_COUNT());
|
||||||
|
INSERT INTO t1 VALUES (SESSION_USER());
|
||||||
|
INSERT INTO t1 VALUES (SLEEP(1));
|
||||||
|
INSERT INTO t1 VALUES (SYSDATE());
|
||||||
|
INSERT INTO t1 VALUES (SYSTEM_USER());
|
||||||
|
INSERT INTO t1 VALUES (USER());
|
||||||
|
INSERT INTO t1 VALUES (UUID());
|
||||||
|
INSERT INTO t1 VALUES (UUID_SHORT());
|
||||||
|
INSERT INTO t1 VALUES (VERSION());
|
||||||
|
INSERT INTO t1 VALUES (RAND());
|
||||||
DROP DATABASE b42851;
|
DROP DATABASE b42851;
|
||||||
USE test;
|
USE test;
|
||||||
#
|
#
|
||||||
@ -67,8 +86,11 @@ Note 1592 Unsafe statement written to the binary log using statement format sinc
|
|||||||
SELECT sf_bug50192();
|
SELECT sf_bug50192();
|
||||||
sf_bug50192()
|
sf_bug50192()
|
||||||
1
|
1
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
|
||||||
SHOW WARNINGS;
|
SHOW WARNINGS;
|
||||||
Level Code Message
|
Level Code Message
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
|
||||||
DROP FUNCTION sf_bug50192;
|
DROP FUNCTION sf_bug50192;
|
||||||
DROP TRIGGER tr_bug50192;
|
DROP TRIGGER tr_bug50192;
|
||||||
DROP TABLE t1, t2;
|
DROP TABLE t1, t2;
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -72,6 +72,26 @@ UPDATE t1 SET b='4' WHERE a=1 LIMIT 1;
|
|||||||
UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1;
|
UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
CREATE TABLE t1 (a VARCHAR(1000));
|
||||||
|
INSERT INTO t1 VALUES (CURRENT_USER()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (FOUND_ROWS()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (GET_LOCK('tmp', 1)); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (IS_FREE_LOCK('tmp')); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (IS_USED_LOCK('tmp')); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (LOAD_FILE('../../std_data/words2.dat')); #marked unsafe in BUG#39701
|
||||||
|
INSERT INTO t1 VALUES (MASTER_POS_WAIT('dummy arg', 4711, 1));
|
||||||
|
INSERT INTO t1 VALUES (RELEASE_LOCK('tmp')); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (ROW_COUNT()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (SESSION_USER()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (SLEEP(1)); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (SYSDATE()); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (SYSTEM_USER()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (USER()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (UUID()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (UUID_SHORT()); #marked unsafe before BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (VERSION()); #marked unsafe in BUG#47995
|
||||||
|
INSERT INTO t1 VALUES (RAND()); #marked unsafe in BUG#49222
|
||||||
|
|
||||||
# clean up
|
# clean up
|
||||||
DROP DATABASE b42851;
|
DROP DATABASE b42851;
|
||||||
|
|
||||||
|
@ -468,6 +468,7 @@ BEGIN
|
|||||||
END|
|
END|
|
||||||
DELIMITER ;|
|
DELIMITER ;|
|
||||||
--echo "One unsafe warning should be issued in the following statement"
|
--echo "One unsafe warning should be issued in the following statement"
|
||||||
|
--error ER_STORED_FUNCTION_PREVENTS_SWITCH_SQL_LOG_BIN
|
||||||
SELECT fun_check_log_bin();
|
SELECT fun_check_log_bin();
|
||||||
--echo "SQL_LOG_BIN should be ON still"
|
--echo "SQL_LOG_BIN should be ON still"
|
||||||
SHOW VARIABLES LIKE "SQL_LOG_BIN";
|
SHOW VARIABLES LIKE "SQL_LOG_BIN";
|
||||||
|
@ -11,5 +11,4 @@
|
|||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
binlog_truncate_innodb : BUG#42643 2009-02-06 mats Changes to InnoDB requires to complete fix for BUG#36763
|
binlog_truncate_innodb : BUG#42643 2009-02-06 mats Changes to InnoDB requires to complete fix for BUG#36763
|
||||||
binlog_unsafe : BUG#50312 2010-01-13 lsoares Warnings for unsafe sub-statement not returned to client
|
|
||||||
binlog_spurious_ddl_errors : BUG#54195 2010-06-03 alik binlog_spurious_ddl_errors.test fails, thus disabled
|
binlog_spurious_ddl_errors : BUG#54195 2010-06-03 alik binlog_spurious_ddl_errors.test fails, thus disabled
|
||||||
|
@ -29,6 +29,8 @@ end;
|
|||||||
select * from t2 order by a;
|
select * from t2 order by a;
|
||||||
a b
|
a b
|
||||||
call test_cursor();
|
call test_cursor();
|
||||||
|
Warnings:
|
||||||
|
Error 1329 No data - zero rows fetched, selected, or processed
|
||||||
select * from t2 order by a;
|
select * from t2 order by a;
|
||||||
a b
|
a b
|
||||||
1 10
|
1 10
|
||||||
|
@ -72,6 +72,8 @@ before call db1.p1()
|
|||||||
INSERT INTO db1.t2 VALUES ('before call db1.p2()');
|
INSERT INTO db1.t2 VALUES ('before call db1.p2()');
|
||||||
BEGIN;
|
BEGIN;
|
||||||
CALL db1.p2();
|
CALL db1.p2();
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
ROLLBACK;
|
ROLLBACK;
|
||||||
INSERT INTO db1.t2 VALUES ('after call db1.p2()');
|
INSERT INTO db1.t2 VALUES ('after call db1.p2()');
|
||||||
SELECT * FROM db1.t1;
|
SELECT * FROM db1.t1;
|
||||||
|
@ -3661,6 +3661,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (135, 4);
|
SELECT fc_i_nt_5_suc (135, 4);
|
||||||
fc_i_nt_5_suc (135, 4)
|
fc_i_nt_5_suc (135, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -3689,6 +3691,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (136, 4);
|
CALL pc_i_nt_5_suc (136, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -3781,6 +3785,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (139, 4);
|
SELECT fc_i_nt_5_suc (139, 4);
|
||||||
fc_i_nt_5_suc (139, 4)
|
fc_i_nt_5_suc (139, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -3809,6 +3815,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-trig << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-trig << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (140, 4);
|
CALL pc_i_nt_5_suc (140, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -3907,6 +3915,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (143, 4);
|
SELECT fc_i_nt_5_suc (143, 4);
|
||||||
fc_i_nt_5_suc (143, 4)
|
fc_i_nt_5_suc (143, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -3937,6 +3947,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (144, 4);
|
CALL pc_i_nt_5_suc (144, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4033,6 +4045,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (147, 4);
|
SELECT fc_i_nt_5_suc (147, 4);
|
||||||
fc_i_nt_5_suc (147, 4)
|
fc_i_nt_5_suc (147, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4063,6 +4077,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (148, 4);
|
CALL pc_i_nt_5_suc (148, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> C << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4295,6 +4311,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (155, 4);
|
SELECT fc_i_nt_5_suc (155, 4);
|
||||||
fc_i_nt_5_suc (155, 4)
|
fc_i_nt_5_suc (155, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4325,6 +4343,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (156, 4);
|
CALL pc_i_nt_5_suc (156, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4423,6 +4443,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (159, 4);
|
SELECT fc_i_nt_5_suc (159, 4);
|
||||||
fc_i_nt_5_suc (159, 4)
|
fc_i_nt_5_suc (159, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4453,6 +4475,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-trig << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-trig << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (160, 4);
|
CALL pc_i_nt_5_suc (160, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4557,6 +4581,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (163, 4);
|
SELECT fc_i_nt_5_suc (163, 4);
|
||||||
fc_i_nt_5_suc (163, 4)
|
fc_i_nt_5_suc (163, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4589,6 +4615,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (164, 4);
|
CALL pc_i_nt_5_suc (164, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4691,6 +4719,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
SELECT fc_i_nt_5_suc (167, 4);
|
SELECT fc_i_nt_5_suc (167, 4);
|
||||||
fc_i_nt_5_suc (167, 4)
|
fc_i_nt_5_suc (167, 4)
|
||||||
fc_i_nt_5_suc
|
fc_i_nt_5_suc
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-func << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -4723,6 +4753,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> T-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> T-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (168, 4);
|
CALL pc_i_nt_5_suc (168, 4);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> N-proc << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> R << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
@ -5291,6 +5323,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (185, 2);
|
CALL pc_i_nt_5_suc (185, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',185), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',185), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5329,6 +5363,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (186, 2);
|
CALL pc_i_nt_5_suc (186, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',186), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',186), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5367,6 +5403,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (187, 2);
|
CALL pc_i_nt_5_suc (187, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',187), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',187), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5407,6 +5445,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (188, 2);
|
CALL pc_i_nt_5_suc (188, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',188), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',188), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5885,6 +5925,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (201, 2);
|
CALL pc_i_nt_5_suc (201, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',201), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',201), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5925,6 +5967,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (202, 2);
|
CALL pc_i_nt_5_suc (202, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',202), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',202), NAME_CONST('in_stmt_id',1))
|
||||||
@ -5967,6 +6011,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (203, 2);
|
CALL pc_i_nt_5_suc (203, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',203), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',203), NAME_CONST('in_stmt_id',1))
|
||||||
@ -6007,6 +6053,8 @@ Log_name Pos Event_type Server_id End_log_pos Info
|
|||||||
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
-e-e-e-e-e-e-e-e-e-e-e- >> B << -e-e-e-e-e-e-e-e-e-e-e-
|
||||||
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
-b-b-b-b-b-b-b-b-b-b-b- >> N-proc << -b-b-b-b-b-b-b-b-b-b-b-
|
||||||
CALL pc_i_nt_5_suc (204, 2);
|
CALL pc_i_nt_5_suc (204, 2);
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it accesses a non-transactional table after accessing a transactional table within the same transaction.
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',204), NAME_CONST('in_stmt_id',1))
|
master-bin.000001 # Query # # use `test`; INSERT INTO nt_5(trans_id, stmt_id) VALUES ( NAME_CONST('p_trans_id',204), NAME_CONST('in_stmt_id',1))
|
||||||
|
@ -39,6 +39,8 @@ INSERT INTO t2 VALUES (NULL);
|
|||||||
RETURN i;
|
RETURN i;
|
||||||
END//
|
END//
|
||||||
CALL p1();
|
CALL p1();
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
|
||||||
show binlog events from <binlog_start>;
|
show binlog events from <binlog_start>;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
@ -123,6 +125,8 @@ SELECT * FROM t2;
|
|||||||
id
|
id
|
||||||
DROP TRIGGER tr1;
|
DROP TRIGGER tr1;
|
||||||
CALL p2();
|
CALL p2();
|
||||||
|
Warnings:
|
||||||
|
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
|
||||||
show binlog events from <binlog_start>;
|
show binlog events from <binlog_start>;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Query # # BEGIN
|
master-bin.000001 # Query # # BEGIN
|
||||||
|
@ -38,6 +38,8 @@ INSERT INTO t1 VALUES ('MySQL','1993-02-04'),('ROCKS', '1990-08-27'),('Texas', '
|
|||||||
END|
|
END|
|
||||||
CALL p2();
|
CALL p2();
|
||||||
CALL p1();
|
CALL p1();
|
||||||
|
Warnings:
|
||||||
|
Error 1329 No data - zero rows fetched, selected, or processed
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
DROP TABLE t2;
|
DROP TABLE t2;
|
||||||
DROP PROCEDURE p1;
|
DROP PROCEDURE p1;
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
|
|
||||||
rpl_ndb_stm_innodb : Bug#54850 2010-07-02 alik rpl_ndb.rpl_ndb_stm_innodb and rpl_ndb.rpl_ndb_2other fails
|
rpl_ndb_stm_innodb : Bug#54850 2010-07-02 alik rpl_ndb.rpl_ndb_stm_innodb and rpl_ndb.rpl_ndb_2other fails
|
||||||
rpl_ndb_2other : Bug#54850 2010-07-02 alik rpl_ndb.rpl_ndb_stm_innodb and rpl_ndb.rpl_ndb_2other fails
|
rpl_ndb_2other : Bug#54850 2010-07-02 alik rpl_ndb.rpl_ndb_stm_innodb and rpl_ndb.rpl_ndb_2other fails
|
||||||
|
rpl_ndb_row_implicit_commit_binlog : Bug#55849 2010-08-09 alik rpl_ndb.rpl_ndb_row_implicit_commit_binlog fails
|
||||||
|
|
||||||
# the below testcase have been reworked to avoid the bug, test contains comment, keep bug open
|
# the below testcase have been reworked to avoid the bug, test contains comment, keep bug open
|
||||||
rpl_ndb_2ndb : Bug#45974: rpl_ndb_2ndb fails sporadically
|
rpl_ndb_2ndb : Bug#45974: rpl_ndb_2ndb fails sporadically
|
||||||
|
@ -1085,3 +1085,13 @@ drop table t1;
|
|||||||
--echo #
|
--echo #
|
||||||
--echo End of 5.1 tests
|
--echo End of 5.1 tests
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug#55648: Server crash on MIX/MAX on maximum time value
|
||||||
|
--echo #
|
||||||
|
CREATE TABLE t1(c1 TIME NOT NULL);
|
||||||
|
INSERT INTO t1 VALUES('837:59:59');
|
||||||
|
INSERT INTO t1 VALUES('838:59:59');
|
||||||
|
SELECT MAX(c1) FROM t1;
|
||||||
|
DROP TABLE t1;
|
||||||
|
--echo # End of the bug#55648
|
||||||
|
|
||||||
|
@ -1,31 +1,4 @@
|
|||||||
# Can't run test of external client with embedded server
|
-- source include/mysql_upgrade_preparation.inc
|
||||||
-- source include/not_embedded.inc
|
|
||||||
|
|
||||||
# Only run test if "mysql_upgrade" is found
|
|
||||||
--require r/have_mysql_upgrade.result
|
|
||||||
--disable_query_log
|
|
||||||
select LENGTH("$MYSQL_UPGRADE")>0 as have_mysql_upgrade;
|
|
||||||
--enable_query_log
|
|
||||||
|
|
||||||
#
|
|
||||||
# Hack:
|
|
||||||
#
|
|
||||||
# If running with Valgrind ($VALGRIND_TEST <> 0) then the resource
|
|
||||||
# consumption (CPU) for upgrading a large log table will be intense.
|
|
||||||
# Therefore, truncate the log table in advance and issue a statement
|
|
||||||
# that should be logged.
|
|
||||||
#
|
|
||||||
if (`SELECT $VALGRIND_TEST`)
|
|
||||||
{
|
|
||||||
--disable_query_log
|
|
||||||
--disable_result_log
|
|
||||||
--disable_abort_on_error
|
|
||||||
TRUNCATE TABLE mysql.general_log;
|
|
||||||
SELECT 1;
|
|
||||||
--enable_abort_on_error
|
|
||||||
--enable_result_log
|
|
||||||
--enable_query_log
|
|
||||||
}
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Basic test that we can run mysql_upgrde and that it finds the
|
# Basic test that we can run mysql_upgrde and that it finds the
|
||||||
|
10
mysql-test/t/mysql_upgrade_ssl.test
Normal file
10
mysql-test/t/mysql_upgrade_ssl.test
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
# mysql_upgrade tests requiring SSL support
|
||||||
|
|
||||||
|
-- source include/have_ssl_communication.inc
|
||||||
|
-- source include/mysql_upgrade_preparation.inc
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug#55672 mysql_upgrade dies with internal error
|
||||||
|
--echo #
|
||||||
|
--exec $MYSQL_UPGRADE --skip-verbose --ssl --force 2>&1
|
||||||
|
--exit
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB, 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,8 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/mysys)
|
INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/mysys)
|
||||||
|
|
||||||
SET(MYSYS_SOURCES array.c charset-def.c charset.c checksum.c default.c
|
SET(MYSYS_SOURCES array.c charset-def.c charset.c checksum.c default.c
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2010 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -144,7 +144,7 @@ mysql_declare_plugin(audit_null)
|
|||||||
MYSQL_AUDIT_PLUGIN, /* type */
|
MYSQL_AUDIT_PLUGIN, /* type */
|
||||||
&audit_null_descriptor, /* descriptor */
|
&audit_null_descriptor, /* descriptor */
|
||||||
"NULL_AUDIT", /* name */
|
"NULL_AUDIT", /* name */
|
||||||
"MySQL AB", /* author */
|
"Oracle Corp", /* author */
|
||||||
"Simple NULL Audit", /* description */
|
"Simple NULL Audit", /* description */
|
||||||
PLUGIN_LICENSE_GPL,
|
PLUGIN_LICENSE_GPL,
|
||||||
audit_null_plugin_init, /* init function (when loaded) */
|
audit_null_plugin_init, /* init function (when loaded) */
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems,Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,8 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
SET(SEMISYNC_MASTER_SOURCES
|
SET(SEMISYNC_MASTER_SOURCES
|
||||||
semisync.cc semisync_master.cc semisync_master_plugin.cc
|
semisync.cc semisync_master.cc semisync_master_plugin.cc
|
||||||
semisync.h semisync_master.h)
|
semisync.h semisync_master.h)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
|
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
|
||||||
|
|
||||||
SET(REGEX_SOURCES regcomp.c regerror.c regexec.c regfree.c reginit.c)
|
SET(REGEX_SOURCES regcomp.c regerror.c regexec.c regfree.c reginit.c)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
# Build comp_sql - used for embedding SQL in C or C++ programs
|
# Build comp_sql - used for embedding SQL in C or C++ programs
|
||||||
IF(NOT CMAKE_CROSSCOMPILING)
|
IF(NOT CMAKE_CROSSCOMPILING)
|
||||||
ADD_EXECUTABLE(comp_sql comp_sql.c)
|
ADD_EXECUTABLE(comp_sql comp_sql.c)
|
||||||
@ -24,6 +23,7 @@ ENDIF()
|
|||||||
# Build mysql_fix_privilege_tables.sql (concatenate 2 sql scripts)
|
# Build mysql_fix_privilege_tables.sql (concatenate 2 sql scripts)
|
||||||
IF(NOT WIN32 OR CMAKE_CROSSCOMPILING)
|
IF(NOT WIN32 OR CMAKE_CROSSCOMPILING)
|
||||||
FIND_PROGRAM(CAT_EXECUTABLE cat DOC "path to the executable")
|
FIND_PROGRAM(CAT_EXECUTABLE cat DOC "path to the executable")
|
||||||
|
MARK_AS_ADVANCED(CAT_EXECUTABLE)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(CAT_EXECUTABLE)
|
IF(CAT_EXECUTABLE)
|
||||||
@ -251,43 +251,40 @@ IF(POLICY CMP0007)
|
|||||||
CMAKE_POLICY(SET CMP0007 OLD)
|
CMAKE_POLICY(SET CMP0007 OLD)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
LIST(REMOVE_ITEM mysqlclient_LIB_DEPENDS "")
|
# Extract dependencies using CMake's internal ${target}_LIB_DEPENDS variable
|
||||||
LIST(REMOVE_DUPLICATES mysqlclient_LIB_DEPENDS)
|
# returned string in ${var} is can be passed to linker's command line
|
||||||
FOREACH(lib ${mysqlclient_LIB_DEPENDS})
|
MACRO(EXTRACT_LINK_LIBRARIES target var)
|
||||||
|
IF(${target}_LIB_DEPENDS)
|
||||||
|
LIST(REMOVE_ITEM ${target}_LIB_DEPENDS "")
|
||||||
|
LIST(REMOVE_DUPLICATES ${target}_LIB_DEPENDS)
|
||||||
|
FOREACH(lib ${${target}_LIB_DEPENDS})
|
||||||
# Filter out "general", it is not a library, just CMake hint
|
# Filter out "general", it is not a library, just CMake hint
|
||||||
IF(NOT lib STREQUAL "general" AND NOT CLIENT_LIBS MATCHES "-l${lib} ")
|
# Also, remove duplicates
|
||||||
|
IF(NOT lib STREQUAL "general" AND NOT ${var} MATCHES "-l${lib} ")
|
||||||
IF (lib MATCHES "^\\-l")
|
IF (lib MATCHES "^\\-l")
|
||||||
SET(CLIENT_LIBS "${CLIENT_LIBS} ${lib} ")
|
SET(${var} "${${var}} ${lib} ")
|
||||||
ELSEIF(lib MATCHES "^/")
|
ELSEIF(lib MATCHES "^/")
|
||||||
# Full path, convert to just filename, strip "lib" prefix and extension
|
# Full path, convert to just filename, strip "lib" prefix and extension
|
||||||
GET_FILENAME_COMPONENT(lib "${lib}" NAME_WE)
|
GET_FILENAME_COMPONENT(lib "${lib}" NAME_WE)
|
||||||
STRING(REGEX REPLACE "^lib" "" lib "${lib}")
|
STRING(REGEX REPLACE "^lib" "" lib "${lib}")
|
||||||
SET(CLIENT_LIBS "${CLIENT_LIBS}-l${lib} " )
|
SET(${var} "${${var}}-l${lib} " )
|
||||||
ELSE()
|
ELSE()
|
||||||
SET(CLIENT_LIBS "${CLIENT_LIBS}-l${lib} " )
|
SET(${var} "${${var}}-l${lib} " )
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
|
||||||
|
|
||||||
IF(LIBDL AND NOT LIBDL MATCHES "-l")
|
|
||||||
SET(LIBDL "-l${LIBDL}")
|
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(LIBWRAP)
|
|
||||||
SET(WRAPLIBS "-lwrap")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
SET(LIBS "${CLIENT_LIBS}")
|
|
||||||
|
|
||||||
IF(LIBCRYPT)
|
|
||||||
SET(LIBS "${LIBS} -l${LIBCRYPT}")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
IF(MSVC)
|
IF(MSVC)
|
||||||
STRING(REPLACE "-l" "" CLIENT_LIBS "${CLIENT_LIBS}")
|
STRING(REPLACE "-l" "" ${var} "${${var}}")
|
||||||
STRING(REPLACE "-l" "" LIBS "${LIBS}" )
|
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
ENDMACRO()
|
||||||
|
|
||||||
|
EXTRACT_LINK_LIBRARIES(mysqlclient CLIENT_LIBS)
|
||||||
|
EXTRACT_LINK_LIBRARIES(mysqlserver LIBS)
|
||||||
|
|
||||||
|
# mysql_config evaluates ${LIBDL}, we want to avoid it
|
||||||
|
# as our CLIENT_LIBS and LIBS are already correct
|
||||||
|
SET(LIBDL)
|
||||||
|
|
||||||
SET(NON_THREADED_LIBS ${CLIENT_LIBS})
|
SET(NON_THREADED_LIBS ${CLIENT_LIBS})
|
||||||
SET(mysql_config_COMPONENT COMPONENT Development)
|
SET(mysql_config_COMPONENT COMPONENT Development)
|
||||||
|
@ -108,7 +108,7 @@ fi
|
|||||||
# We intentionally add a space to the beginning and end of lib strings, simplifies replace later
|
# We intentionally add a space to the beginning and end of lib strings, simplifies replace later
|
||||||
libs=" $ldflags -L$pkglibdir -lmysqlclient @ZLIB_DEPS@ @NON_THREADED_LIBS@"
|
libs=" $ldflags -L$pkglibdir -lmysqlclient @ZLIB_DEPS@ @NON_THREADED_LIBS@"
|
||||||
libs="$libs @openssl_libs@ @STATIC_NSS_FLAGS@ "
|
libs="$libs @openssl_libs@ @STATIC_NSS_FLAGS@ "
|
||||||
libs_r=" $ldflags -L$pkglibdir -lmysqlclient_r @ZLIB_DEPS@ @LIBS@ @openssl_libs@ "
|
libs_r=" $ldflags -L$pkglibdir -lmysqlclient_r @ZLIB_DEPS@ @CLIENT_LIBS@ @openssl_libs@ "
|
||||||
embedded_libs=" $ldflags -L$pkglibdir -lmysqld @LIBDL@ @ZLIB_DEPS@ @LIBS@ @WRAPLIBS@ @openssl_libs@ "
|
embedded_libs=" $ldflags -L$pkglibdir -lmysqld @LIBDL@ @ZLIB_DEPS@ @LIBS@ @WRAPLIBS@ @openssl_libs@ "
|
||||||
|
|
||||||
if [ -r "$pkglibdir/libmygcc.a" ]; then
|
if [ -r "$pkglibdir/libmygcc.a" ]; then
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -14,12 +14,6 @@
|
|||||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
# Install sql-bench files
|
# Install sql-bench files
|
||||||
FILE(GLOB all_files
|
|
||||||
${CMAKE_SOURCE_DIR}/sql-bench/*
|
|
||||||
${CMAKE_SOURCE_DIR}/sql-bench/Data/ATIS/*
|
|
||||||
${CMAKE_SOURCE_DIR}/sql-bench/Data/Wisconsin/*
|
|
||||||
${CMAKE_SOURCE_DIR}/sql-bench/limits/*
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(NOT INSTALL_SQLBENCHDIR)
|
IF(NOT INSTALL_SQLBENCHDIR)
|
||||||
RETURN()
|
RETURN()
|
||||||
@ -31,30 +25,39 @@ ELSE()
|
|||||||
SET(prefix ${INSTALL_SQLBENCHDIR}/)
|
SET(prefix ${INSTALL_SQLBENCHDIR}/)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
GET_FILENAME_COMPONENT(basedir ${CMAKE_SOURCE_DIR} ABSOLUTE)
|
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/Data/ATIS
|
||||||
|
DESTINATION ${prefix}sql-bench/Data)
|
||||||
|
|
||||||
|
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/Data/Wisconsin
|
||||||
|
DESTINATION ${prefix}sql-bench/Data)
|
||||||
|
|
||||||
|
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/limits
|
||||||
|
DESTINATION ${prefix}sql-bench)
|
||||||
|
|
||||||
|
FILE(GLOB all_files ${CMAKE_CURRENT_SOURCE_DIR}/*)
|
||||||
|
|
||||||
FOREACH(file ${all_files})
|
FOREACH(file ${all_files})
|
||||||
IF(NOT IS_DIRECTORY ${file} AND NOT ${file} MATCHES "Make|as3ap|/example$" )
|
IF(NOT IS_DIRECTORY ${file} AND NOT ${file} MATCHES "Make|as3ap|/example$" )
|
||||||
FILE(RELATIVE_PATH relpath ${basedir} ${file})
|
|
||||||
SET(target_relpath ${relpath})
|
|
||||||
GET_FILENAME_COMPONENT(ext ${file} EXT)
|
GET_FILENAME_COMPONENT(ext ${file} EXT)
|
||||||
GET_FILENAME_COMPONENT(dir ${relpath} PATH)
|
GET_FILENAME_COMPONENT(name ${file} NAME)
|
||||||
|
SET(target ${name})
|
||||||
IF(ext MATCHES ".sh$")
|
IF(ext MATCHES ".sh$")
|
||||||
# Those are perl files actually
|
# Those are perl files actually
|
||||||
STRING(REPLACE ".sh" "" target_relpath ${target_relpath} )
|
STRING(REPLACE ".sh" "" target ${target} )
|
||||||
IF(WIN32)
|
IF(WIN32)
|
||||||
IF(NOT ext MATCHES ".pl")
|
IF(NOT ext MATCHES ".pl")
|
||||||
SET(target_relpath "${target_relpath}.pl")
|
SET(target "${target}.pl")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
SET(target "${CMAKE_BINARY_DIR}/${target_relpath}")
|
SET(target "${CMAKE_CURRENT_BINARY_DIR}/${target}")
|
||||||
CONFIGURE_FILE(${file} ${target} COPYONLY)
|
CONFIGURE_FILE(${file} ${target} COPYONLY)
|
||||||
IF (ext MATCHES ".bat")
|
IF (ext MATCHES ".bat")
|
||||||
IF(WIN32)
|
IF(WIN32)
|
||||||
INSTALL(FILES ${target} DESTINATION ${prefix}${dir})
|
INSTALL(FILES ${target} DESTINATION ${prefix}sql-bench)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ELSE()
|
ELSE()
|
||||||
INSTALL(FILES ${target} DESTINATION ${prefix}${dir})
|
INSTALL(FILES ${target} DESTINATION ${prefix}sql-bench)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(
|
INCLUDE_DIRECTORIES(
|
||||||
${CMAKE_SOURCE_DIR}/include
|
${CMAKE_SOURCE_DIR}/include
|
||||||
${CMAKE_SOURCE_DIR}/sql
|
${CMAKE_SOURCE_DIR}/sql
|
||||||
@ -42,7 +41,6 @@ SET (SQL_SOURCE
|
|||||||
../sql-common/client.c derror.cc des_key_file.cc
|
../sql-common/client.c derror.cc des_key_file.cc
|
||||||
discover.cc ../libmysql/errmsg.c field.cc field_conv.cc
|
discover.cc ../libmysql/errmsg.c field.cc field_conv.cc
|
||||||
filesort.cc gstream.cc sha2.cc
|
filesort.cc gstream.cc sha2.cc
|
||||||
ha_partition.cc
|
|
||||||
handler.cc hash_filo.h sql_plugin_services.h
|
handler.cc hash_filo.h sql_plugin_services.h
|
||||||
hostname.cc init.cc item.cc item_buff.cc item_cmpfunc.cc
|
hostname.cc init.cc item.cc item_buff.cc item_cmpfunc.cc
|
||||||
item_create.cc item_func.cc item_geofunc.cc item_row.cc
|
item_create.cc item_func.cc item_geofunc.cc item_row.cc
|
||||||
@ -83,6 +81,7 @@ MYSQL_ADD_PLUGIN(partition ha_partition.cc STORAGE_ENGINE DEFAULT STATIC_ONLY
|
|||||||
RECOMPILE_FOR_EMBEDDED)
|
RECOMPILE_FOR_EMBEDDED)
|
||||||
|
|
||||||
ADD_LIBRARY(sql STATIC ${SQL_SOURCE})
|
ADD_LIBRARY(sql STATIC ${SQL_SOURCE})
|
||||||
|
ADD_DEPENDENCIES(sql GenServerSource)
|
||||||
DTRACE_INSTRUMENT(sql)
|
DTRACE_INSTRUMENT(sql)
|
||||||
TARGET_LINK_LIBRARIES(sql ${MYSQLD_STATIC_PLUGIN_LIBS}
|
TARGET_LINK_LIBRARIES(sql ${MYSQLD_STATIC_PLUGIN_LIBS}
|
||||||
mysys dbug strings vio regex
|
mysys dbug strings vio regex
|
||||||
@ -189,6 +188,7 @@ ADD_EXECUTABLE(gen_lex_hash gen_lex_hash.cc)
|
|||||||
ADD_CUSTOM_COMMAND(
|
ADD_CUSTOM_COMMAND(
|
||||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/lex_hash.h
|
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/lex_hash.h
|
||||||
COMMAND gen_lex_hash > lex_hash.h
|
COMMAND gen_lex_hash > lex_hash.h
|
||||||
|
DEPENDS gen_lex_hash
|
||||||
)
|
)
|
||||||
|
|
||||||
MYSQL_ADD_EXECUTABLE(mysql_tzinfo_to_sql tztime.cc)
|
MYSQL_ADD_EXECUTABLE(mysql_tzinfo_to_sql tztime.cc)
|
||||||
@ -266,18 +266,20 @@ IF(WIN32 AND MYSQLD_EXECUTABLE)
|
|||||||
ENDIF()
|
ENDIF()
|
||||||
MAKE_DIRECTORY(${CMAKE_CURRENT_BINARY_DIR}/data)
|
MAKE_DIRECTORY(${CMAKE_CURRENT_BINARY_DIR}/data)
|
||||||
ADD_CUSTOM_COMMAND(
|
ADD_CUSTOM_COMMAND(
|
||||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/data/mysql/user.frm
|
OUTPUT initdb.dep
|
||||||
COMMAND ${CMAKE_COMMAND}
|
COMMAND ${CMAKE_COMMAND}
|
||||||
${CONFIG_PARAM} -P ${CMAKE_CURRENT_BINARY_DIR}/create_initial_db.cmake
|
${CONFIG_PARAM} -P ${CMAKE_CURRENT_BINARY_DIR}/create_initial_db.cmake
|
||||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data
|
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E touch initdb.dep
|
||||||
|
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
||||||
DEPENDS mysqld
|
DEPENDS mysqld
|
||||||
)
|
)
|
||||||
ADD_CUSTOM_TARGET(initial_database
|
ADD_CUSTOM_TARGET(initial_database
|
||||||
ALL
|
ALL
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/data/mysql/user.frm
|
DEPENDS initdb.dep
|
||||||
)
|
)
|
||||||
INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data DESTINATION . COMPONENT DataFiles
|
INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data DESTINATION .
|
||||||
PATTERN "bootstrap.sql" EXCLUDE)
|
COMPONENT DataFiles PATTERN "initdb.dep" EXCLUDE PATTERN "bootstrap.sql" EXCLUDE)
|
||||||
ELSE()
|
ELSE()
|
||||||
# Not windows or cross compiling, just install an empty directory
|
# Not windows or cross compiling, just install an empty directory
|
||||||
INSTALL(FILES ${DUMMY_FILE} DESTINATION data/mysql)
|
INSTALL(FILES ${DUMMY_FILE} DESTINATION data/mysql)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -7510,13 +7510,13 @@ String *Item_cache_datetime::val_str(String *str)
|
|||||||
if (cached_field_type == MYSQL_TYPE_TIME)
|
if (cached_field_type == MYSQL_TYPE_TIME)
|
||||||
{
|
{
|
||||||
ulonglong time= int_value;
|
ulonglong time= int_value;
|
||||||
DBUG_ASSERT(time < TIME_MAX_VALUE);
|
DBUG_ASSERT(time <= TIME_MAX_VALUE);
|
||||||
set_zero_time(<ime, MYSQL_TIMESTAMP_TIME);
|
set_zero_time(<ime, MYSQL_TIMESTAMP_TIME);
|
||||||
ltime.second= time % 100;
|
ltime.second= time % 100;
|
||||||
time/= 100;
|
time/= 100;
|
||||||
ltime.minute= time % 100;
|
ltime.minute= time % 100;
|
||||||
time/= 100;
|
time/= 100;
|
||||||
ltime.hour= time % 100;
|
ltime.hour= time;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -4704,7 +4704,7 @@ bool MYSQL_BIN_LOG::write(Log_event *event_info)
|
|||||||
file= cache_mngr->get_binlog_cache_log(is_trans_cache);
|
file= cache_mngr->get_binlog_cache_log(is_trans_cache);
|
||||||
cache_data= cache_mngr->get_binlog_cache_data(is_trans_cache);
|
cache_data= cache_mngr->get_binlog_cache_data(is_trans_cache);
|
||||||
|
|
||||||
if (thd->stmt_accessed_non_trans_temp_table())
|
if (thd->lex->stmt_accessed_non_trans_temp_table())
|
||||||
cache_data->set_changes_to_non_trans_temp_table();
|
cache_data->set_changes_to_non_trans_temp_table();
|
||||||
|
|
||||||
thd->binlog_start_trans_and_stmt();
|
thd->binlog_start_trans_and_stmt();
|
||||||
|
@ -679,7 +679,7 @@ Log_event::Log_event(THD* thd_arg, uint16 flags_arg, bool using_trans)
|
|||||||
server_id= thd->server_id;
|
server_id= thd->server_id;
|
||||||
when= thd->start_time;
|
when= thd->start_time;
|
||||||
cache_type= ((using_trans || stmt_has_updated_trans_table(thd) ||
|
cache_type= ((using_trans || stmt_has_updated_trans_table(thd) ||
|
||||||
(thd->stmt_accessed_temp_table() &&
|
(thd->lex->stmt_accessed_temp_table() &&
|
||||||
trans_has_updated_trans_table(thd)))
|
trans_has_updated_trans_table(thd)))
|
||||||
? Log_event::EVENT_TRANSACTIONAL_CACHE :
|
? Log_event::EVENT_TRANSACTIONAL_CACHE :
|
||||||
Log_event::EVENT_STMT_CACHE);
|
Log_event::EVENT_STMT_CACHE);
|
||||||
@ -2573,7 +2573,7 @@ Query_log_event::Query_log_event(THD* thd_arg, const char* query_arg,
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
cache_type= ((using_trans || stmt_has_updated_trans_table(thd) || trx_cache ||
|
cache_type= ((using_trans || stmt_has_updated_trans_table(thd) || trx_cache ||
|
||||||
(thd->stmt_accessed_temp_table() &&
|
(thd->lex->stmt_accessed_temp_table() &&
|
||||||
trans_has_updated_trans_table(thd)))
|
trans_has_updated_trans_table(thd)))
|
||||||
? Log_event::EVENT_TRANSACTIONAL_CACHE :
|
? Log_event::EVENT_TRANSACTIONAL_CACHE :
|
||||||
Log_event::EVENT_STMT_CACHE);
|
Log_event::EVENT_STMT_CACHE);
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1743,7 +1743,7 @@ sp_head::execute_function(THD *thd, Item **argp, uint argcount,
|
|||||||
Field *return_value_fld)
|
Field *return_value_fld)
|
||||||
{
|
{
|
||||||
ulonglong binlog_save_options;
|
ulonglong binlog_save_options;
|
||||||
bool need_binlog_call;
|
bool need_binlog_call= FALSE;
|
||||||
uint arg_no;
|
uint arg_no;
|
||||||
sp_rcontext *octx = thd->spcont;
|
sp_rcontext *octx = thd->spcont;
|
||||||
sp_rcontext *nctx = NULL;
|
sp_rcontext *nctx = NULL;
|
||||||
@ -1950,6 +1950,14 @@ err_with_cleanup:
|
|||||||
free_root(&call_mem_root, MYF(0));
|
free_root(&call_mem_root, MYF(0));
|
||||||
thd->spcont= octx;
|
thd->spcont= octx;
|
||||||
|
|
||||||
|
/*
|
||||||
|
If not insided a procedure and a function printing warning
|
||||||
|
messsages.
|
||||||
|
*/
|
||||||
|
if (need_binlog_call &&
|
||||||
|
thd->spcont == NULL && !thd->binlog_evt_union.do_union)
|
||||||
|
thd->issue_unsafe_warnings();
|
||||||
|
|
||||||
DBUG_RETURN(err_status);
|
DBUG_RETURN(err_status);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2195,6 +2203,17 @@ sp_head::execute_procedure(THD *thd, List<Item> *args)
|
|||||||
thd->spcont= save_spcont;
|
thd->spcont= save_spcont;
|
||||||
thd->utime_after_lock= utime_before_sp_exec;
|
thd->utime_after_lock= utime_before_sp_exec;
|
||||||
|
|
||||||
|
/*
|
||||||
|
If not insided a procedure and a function printing warning
|
||||||
|
messsages.
|
||||||
|
*/
|
||||||
|
bool need_binlog_call= mysql_bin_log.is_open() &&
|
||||||
|
(thd->variables.option_bits & OPTION_BIN_LOG) &&
|
||||||
|
!thd->is_current_stmt_binlog_format_row();
|
||||||
|
if (need_binlog_call && thd->spcont == NULL &&
|
||||||
|
!thd->binlog_evt_union.do_union)
|
||||||
|
thd->issue_unsafe_warnings();
|
||||||
|
|
||||||
DBUG_RETURN(err_status);
|
DBUG_RETURN(err_status);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
122
sql/sql_class.cc
122
sql/sql_class.cc
@ -492,7 +492,6 @@ THD::THD()
|
|||||||
rli_fake(0),
|
rli_fake(0),
|
||||||
user_time(0), in_sub_stmt(0),
|
user_time(0), in_sub_stmt(0),
|
||||||
binlog_unsafe_warning_flags(0),
|
binlog_unsafe_warning_flags(0),
|
||||||
stmt_accessed_table_flag(0),
|
|
||||||
binlog_table_maps(0),
|
binlog_table_maps(0),
|
||||||
table_map_for_update(0),
|
table_map_for_update(0),
|
||||||
arg_of_last_insert_id_function(FALSE),
|
arg_of_last_insert_id_function(FALSE),
|
||||||
@ -3675,8 +3674,17 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
Innodb and Falcon; Innodb and MyIsam.
|
Innodb and Falcon; Innodb and MyIsam.
|
||||||
*/
|
*/
|
||||||
my_bool multi_access_engine= FALSE;
|
my_bool multi_access_engine= FALSE;
|
||||||
|
/*
|
||||||
|
Identifies if a table is changed.
|
||||||
|
*/
|
||||||
|
my_bool is_write= FALSE;
|
||||||
|
/*
|
||||||
|
A pointer to a previous table that was changed.
|
||||||
|
*/
|
||||||
TABLE* prev_write_table= NULL;
|
TABLE* prev_write_table= NULL;
|
||||||
|
/*
|
||||||
|
A pointer to a previous table that was accessed.
|
||||||
|
*/
|
||||||
TABLE* prev_access_table= NULL;
|
TABLE* prev_access_table= NULL;
|
||||||
|
|
||||||
#ifndef DBUG_OFF
|
#ifndef DBUG_OFF
|
||||||
@ -3700,7 +3708,8 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
if (table->placeholder())
|
if (table->placeholder())
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (table->table->s->table_category == TABLE_CATEGORY_PERFORMANCE)
|
if (table->table->s->table_category == TABLE_CATEGORY_PERFORMANCE ||
|
||||||
|
table->table->s->table_category == TABLE_CATEGORY_LOG)
|
||||||
lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_TABLE);
|
lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_TABLE);
|
||||||
|
|
||||||
handler::Table_flags const flags= table->table->file->ha_table_flags();
|
handler::Table_flags const flags= table->table->file->ha_table_flags();
|
||||||
@ -3716,16 +3725,18 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
my_bool trans= table->table->file->has_transactions();
|
my_bool trans= table->table->file->has_transactions();
|
||||||
|
|
||||||
if (table->table->s->tmp_table)
|
if (table->table->s->tmp_table)
|
||||||
set_stmt_accessed_table(trans ? STMT_WRITES_TEMP_TRANS_TABLE :
|
lex->set_stmt_accessed_table(trans ? LEX::STMT_WRITES_TEMP_TRANS_TABLE :
|
||||||
STMT_WRITES_TEMP_NON_TRANS_TABLE);
|
LEX::STMT_WRITES_TEMP_NON_TRANS_TABLE);
|
||||||
else
|
else
|
||||||
set_stmt_accessed_table(trans ? STMT_WRITES_TRANS_TABLE :
|
lex->set_stmt_accessed_table(trans ? LEX::STMT_WRITES_TRANS_TABLE :
|
||||||
STMT_WRITES_NON_TRANS_TABLE);
|
LEX::STMT_WRITES_NON_TRANS_TABLE);
|
||||||
|
|
||||||
flags_write_all_set &= flags;
|
flags_write_all_set &= flags;
|
||||||
flags_write_some_set |= flags;
|
flags_write_some_set |= flags;
|
||||||
|
is_write= TRUE;
|
||||||
|
|
||||||
prev_write_table= table->table;
|
prev_write_table= table->table;
|
||||||
|
|
||||||
}
|
}
|
||||||
flags_access_some_set |= flags;
|
flags_access_some_set |= flags;
|
||||||
|
|
||||||
@ -3736,11 +3747,11 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
my_bool trans= table->table->file->has_transactions();
|
my_bool trans= table->table->file->has_transactions();
|
||||||
|
|
||||||
if (table->table->s->tmp_table)
|
if (table->table->s->tmp_table)
|
||||||
set_stmt_accessed_table(trans ? STMT_READS_TEMP_TRANS_TABLE :
|
lex->set_stmt_accessed_table(trans ? LEX::STMT_READS_TEMP_TRANS_TABLE :
|
||||||
STMT_READS_TEMP_NON_TRANS_TABLE);
|
LEX::STMT_READS_TEMP_NON_TRANS_TABLE);
|
||||||
else
|
else
|
||||||
set_stmt_accessed_table(trans ? STMT_READS_TRANS_TABLE :
|
lex->set_stmt_accessed_table(trans ? LEX::STMT_READS_TRANS_TABLE :
|
||||||
STMT_READS_NON_TRANS_TABLE);
|
LEX::STMT_READS_NON_TRANS_TABLE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (prev_access_table && prev_access_table->file->ht !=
|
if (prev_access_table && prev_access_table->file->ht !=
|
||||||
@ -3812,24 +3823,24 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
my_bool non_trans_unsafe= FALSE;
|
my_bool non_trans_unsafe= FALSE;
|
||||||
|
|
||||||
/* Case 1. */
|
/* Case 1. */
|
||||||
if (stmt_accessed_table(STMT_WRITES_TRANS_TABLE) &&
|
if (lex->stmt_accessed_table(LEX::STMT_WRITES_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 2. */
|
/* Case 2. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_TEMP_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_TEMP_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 3. */
|
/* Case 3. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 4. */
|
/* Case 4. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_TEMP_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_TEMP_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 5. */
|
/* Case 5. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_TRANS_TABLE) &&
|
lex->stmt_accessed_table(LEX::STMT_READS_TRANS_TABLE) &&
|
||||||
tx_isolation < ISO_REPEATABLE_READ)
|
tx_isolation < ISO_REPEATABLE_READ)
|
||||||
/*
|
/*
|
||||||
By default, InnoDB operates in REPEATABLE READ and with the option
|
By default, InnoDB operates in REPEATABLE READ and with the option
|
||||||
@ -3847,28 +3858,28 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
if (trans_has_updated_trans_table(this))
|
if (trans_has_updated_trans_table(this))
|
||||||
{
|
{
|
||||||
/* Case 6. */
|
/* Case 6. */
|
||||||
if (stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE) &&
|
if (lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 7. */
|
/* Case 7. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_TEMP_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_TEMP_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 8. */
|
/* Case 8. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_TEMP_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_TEMP_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 9. */
|
/* Case 9. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_TEMP_NON_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_TEMP_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 10. */
|
/* Case 10. */
|
||||||
else if (stmt_accessed_table(STMT_WRITES_TEMP_NON_TRANS_TABLE) &&
|
else if (lex->stmt_accessed_table(LEX::STMT_WRITES_TEMP_NON_TRANS_TABLE) &&
|
||||||
stmt_accessed_table(STMT_READS_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_READS_NON_TRANS_TABLE))
|
||||||
mixed_unsafe= TRUE;
|
mixed_unsafe= TRUE;
|
||||||
/* Case 11. */
|
/* Case 11. */
|
||||||
else if (!variables.binlog_direct_non_trans_update &&
|
else if (!variables.binlog_direct_non_trans_update &&
|
||||||
stmt_accessed_table(STMT_WRITES_NON_TRANS_TABLE))
|
lex->stmt_accessed_table(LEX::STMT_WRITES_NON_TRANS_TABLE))
|
||||||
non_trans_unsafe= TRUE;
|
non_trans_unsafe= TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3959,13 +3970,14 @@ int THD::decide_logging_format(TABLE_LIST *tables)
|
|||||||
*/
|
*/
|
||||||
my_error((error= ER_BINLOG_STMT_MODE_AND_ROW_ENGINE), MYF(0), "");
|
my_error((error= ER_BINLOG_STMT_MODE_AND_ROW_ENGINE), MYF(0), "");
|
||||||
}
|
}
|
||||||
else if ((unsafe_flags= lex->get_stmt_unsafe_flags()) != 0)
|
else if (is_write && (unsafe_flags= lex->get_stmt_unsafe_flags()) != 0)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
7. Warning: Unsafe statement logged as statement due to
|
7. Warning: Unsafe statement logged as statement due to
|
||||||
binlog_format = STATEMENT
|
binlog_format = STATEMENT
|
||||||
*/
|
*/
|
||||||
binlog_unsafe_warning_flags|= unsafe_flags;
|
binlog_unsafe_warning_flags|= unsafe_flags;
|
||||||
|
|
||||||
DBUG_PRINT("info", ("Scheduling warning to be issued by "
|
DBUG_PRINT("info", ("Scheduling warning to be issued by "
|
||||||
"binlog_query: '%s'",
|
"binlog_query: '%s'",
|
||||||
ER(ER_BINLOG_UNSAFE_STATEMENT)));
|
ER(ER_BINLOG_UNSAFE_STATEMENT)));
|
||||||
@ -4441,23 +4453,10 @@ void THD::issue_unsafe_warnings()
|
|||||||
Ensure that binlog_unsafe_warning_flags is big enough to hold all
|
Ensure that binlog_unsafe_warning_flags is big enough to hold all
|
||||||
bits. This is actually a constant expression.
|
bits. This is actually a constant expression.
|
||||||
*/
|
*/
|
||||||
DBUG_ASSERT(2 * LEX::BINLOG_STMT_UNSAFE_COUNT <=
|
DBUG_ASSERT(LEX::BINLOG_STMT_UNSAFE_COUNT <=
|
||||||
sizeof(binlog_unsafe_warning_flags) * CHAR_BIT);
|
sizeof(binlog_unsafe_warning_flags) * CHAR_BIT);
|
||||||
|
|
||||||
uint32 unsafe_type_flags= binlog_unsafe_warning_flags;
|
uint32 unsafe_type_flags= binlog_unsafe_warning_flags;
|
||||||
|
|
||||||
/*
|
|
||||||
Clear: (1) bits above BINLOG_STMT_UNSAFE_COUNT; (2) bits for
|
|
||||||
warnings that have been printed already.
|
|
||||||
*/
|
|
||||||
unsafe_type_flags &= (LEX::BINLOG_STMT_UNSAFE_ALL_FLAGS ^
|
|
||||||
(unsafe_type_flags >> LEX::BINLOG_STMT_UNSAFE_COUNT));
|
|
||||||
/* If all warnings have been printed already, return. */
|
|
||||||
if (unsafe_type_flags == 0)
|
|
||||||
DBUG_VOID_RETURN;
|
|
||||||
|
|
||||||
DBUG_PRINT("info", ("unsafe_type_flags: 0x%x", unsafe_type_flags));
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
For each unsafe_type, check if the statement is unsafe in this way
|
For each unsafe_type, check if the statement is unsafe in this way
|
||||||
and issue a warning.
|
and issue a warning.
|
||||||
@ -4481,12 +4480,6 @@ void THD::issue_unsafe_warnings()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
Mark these unsafe types as already printed, to avoid printing
|
|
||||||
warnings for them again.
|
|
||||||
*/
|
|
||||||
binlog_unsafe_warning_flags|=
|
|
||||||
unsafe_type_flags << LEX::BINLOG_STMT_UNSAFE_COUNT;
|
|
||||||
DBUG_VOID_RETURN;
|
DBUG_VOID_RETURN;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4540,19 +4533,32 @@ int THD::binlog_query(THD::enum_binlog_query_type qtype, char const *query_arg,
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
Warnings for unsafe statements logged in statement format are
|
Warnings for unsafe statements logged in statement format are
|
||||||
printed here instead of in decide_logging_format(). This is
|
printed in three places instead of in decide_logging_format().
|
||||||
because the warnings should be printed only if the statement is
|
This is because the warnings should be printed only if the statement
|
||||||
actually logged. When executing decide_logging_format(), we cannot
|
is actually logged. When executing decide_logging_format(), we cannot
|
||||||
know for sure if the statement will be logged.
|
know for sure if the statement will be logged:
|
||||||
|
|
||||||
|
1 - sp_head::execute_procedure which prints out warnings for calls to
|
||||||
|
stored procedures.
|
||||||
|
|
||||||
|
2 - sp_head::execute_function which prints out warnings for calls
|
||||||
|
involving functions.
|
||||||
|
|
||||||
|
3 - THD::binlog_query (here) which prints warning for top level
|
||||||
|
statements not covered by the two cases above: i.e., if not insided a
|
||||||
|
procedure and a function.
|
||||||
|
|
||||||
Besides, we should not try to print these warnings if it is not
|
Besides, we should not try to print these warnings if it is not
|
||||||
possible to write statements to the binary log as it happens when
|
possible to write statements to the binary log as it happens when
|
||||||
the execution is inside a function, or generaly speaking, when
|
the execution is inside a function, or generaly speaking, when
|
||||||
the variables.option_bits & OPTION_BIN_LOG is false.
|
the variables.option_bits & OPTION_BIN_LOG is false.
|
||||||
|
|
||||||
*/
|
*/
|
||||||
if (variables.option_bits & OPTION_BIN_LOG)
|
if ((variables.option_bits & OPTION_BIN_LOG) &&
|
||||||
|
spcont == NULL && !binlog_evt_union.do_union)
|
||||||
issue_unsafe_warnings();
|
issue_unsafe_warnings();
|
||||||
|
|
||||||
|
|
||||||
switch (qtype) {
|
switch (qtype) {
|
||||||
/*
|
/*
|
||||||
ROW_QUERY_TYPE means that the statement may be logged either in
|
ROW_QUERY_TYPE means that the statement may be logged either in
|
||||||
|
147
sql/sql_class.h
147
sql/sql_class.h
@ -1566,125 +1566,6 @@ public:
|
|||||||
return current_stmt_binlog_format == BINLOG_FORMAT_ROW;
|
return current_stmt_binlog_format == BINLOG_FORMAT_ROW;
|
||||||
}
|
}
|
||||||
|
|
||||||
enum enum_stmt_accessed_table
|
|
||||||
{
|
|
||||||
/*
|
|
||||||
If a transactional table is about to be read. Note that
|
|
||||||
a write implies a read.
|
|
||||||
*/
|
|
||||||
STMT_READS_TRANS_TABLE= 0,
|
|
||||||
/*
|
|
||||||
If a transactional table is about to be updated.
|
|
||||||
*/
|
|
||||||
STMT_WRITES_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a non-transactional table is about to be read. Note that
|
|
||||||
a write implies a read.
|
|
||||||
*/
|
|
||||||
STMT_READS_NON_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a non-transactional table is about to be updated.
|
|
||||||
*/
|
|
||||||
STMT_WRITES_NON_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a temporary transactional table is about to be read. Note
|
|
||||||
that a write implies a read.
|
|
||||||
*/
|
|
||||||
STMT_READS_TEMP_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a temporary transactional table is about to be updated.
|
|
||||||
*/
|
|
||||||
STMT_WRITES_TEMP_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a temporary non-transactional table is about to be read. Note
|
|
||||||
that a write implies a read.
|
|
||||||
*/
|
|
||||||
STMT_READS_TEMP_NON_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
If a temporary non-transactional table is about to be updated.
|
|
||||||
*/
|
|
||||||
STMT_WRITES_TEMP_NON_TRANS_TABLE,
|
|
||||||
/*
|
|
||||||
The last element of the enumeration. Please, if necessary add
|
|
||||||
anything before this.
|
|
||||||
*/
|
|
||||||
STMT_ACCESS_TABLE_COUNT
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
Sets the type of table that is about to be accessed while executing a
|
|
||||||
statement.
|
|
||||||
|
|
||||||
@param accessed_table Enumeration type that defines the type of table,
|
|
||||||
e.g. temporary, transactional, non-transactional.
|
|
||||||
*/
|
|
||||||
inline void set_stmt_accessed_table(enum_stmt_accessed_table accessed_table)
|
|
||||||
{
|
|
||||||
DBUG_ENTER("THD::set_stmt_accessed_table");
|
|
||||||
|
|
||||||
DBUG_ASSERT(accessed_table >= 0 && accessed_table < STMT_ACCESS_TABLE_COUNT);
|
|
||||||
stmt_accessed_table_flag |= (1U << accessed_table);
|
|
||||||
|
|
||||||
DBUG_VOID_RETURN;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Checks if a type of table is about to be accessed while executing a
|
|
||||||
statement.
|
|
||||||
|
|
||||||
@param accessed_table Enumeration type that defines the type of table,
|
|
||||||
e.g. temporary, transactional, non-transactional.
|
|
||||||
|
|
||||||
@return
|
|
||||||
@retval TRUE if the type of the table is about to be accessed
|
|
||||||
@retval FALSE otherwise
|
|
||||||
*/
|
|
||||||
inline bool stmt_accessed_table(enum_stmt_accessed_table accessed_table)
|
|
||||||
{
|
|
||||||
DBUG_ENTER("THD::stmt_accessed_table");
|
|
||||||
|
|
||||||
DBUG_ASSERT(accessed_table >= 0 && accessed_table < STMT_ACCESS_TABLE_COUNT);
|
|
||||||
|
|
||||||
DBUG_RETURN((stmt_accessed_table_flag & (1U << accessed_table)) != 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Checks if a temporary table is about to be accessed while executing a
|
|
||||||
statement.
|
|
||||||
|
|
||||||
@return
|
|
||||||
@retval TRUE if a temporary table is about to be accessed
|
|
||||||
@retval FALSE otherwise
|
|
||||||
*/
|
|
||||||
inline bool stmt_accessed_temp_table()
|
|
||||||
{
|
|
||||||
DBUG_ENTER("THD::stmt_accessed_temp_table");
|
|
||||||
|
|
||||||
DBUG_RETURN((stmt_accessed_table_flag &
|
|
||||||
((1U << STMT_READS_TEMP_TRANS_TABLE) |
|
|
||||||
(1U << STMT_WRITES_TEMP_TRANS_TABLE) |
|
|
||||||
(1U << STMT_READS_TEMP_NON_TRANS_TABLE) |
|
|
||||||
(1U << STMT_WRITES_TEMP_NON_TRANS_TABLE))) != 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
Checks if a temporary non-transactional table is about to be accessed
|
|
||||||
while executing a statement.
|
|
||||||
|
|
||||||
@return
|
|
||||||
@retval TRUE if a temporary non-transactional table is about to be
|
|
||||||
accessed
|
|
||||||
@retval FALSE otherwise
|
|
||||||
*/
|
|
||||||
inline bool stmt_accessed_non_trans_temp_table()
|
|
||||||
{
|
|
||||||
DBUG_ENTER("THD::stmt_accessed_non_trans_temp_table");
|
|
||||||
|
|
||||||
DBUG_RETURN((stmt_accessed_table_flag &
|
|
||||||
((1U << STMT_READS_TEMP_NON_TRANS_TABLE) |
|
|
||||||
(1U << STMT_WRITES_TEMP_NON_TRANS_TABLE))) != 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/**
|
/**
|
||||||
Indicates the format in which the current statement will be
|
Indicates the format in which the current statement will be
|
||||||
@ -1695,25 +1576,9 @@ private:
|
|||||||
/**
|
/**
|
||||||
Bit field for the state of binlog warnings.
|
Bit field for the state of binlog warnings.
|
||||||
|
|
||||||
There are two groups of bits:
|
The first Lex::BINLOG_STMT_UNSAFE_COUNT bits list all types of
|
||||||
|
|
||||||
- The first Lex::BINLOG_STMT_UNSAFE_COUNT bits list all types of
|
|
||||||
unsafeness that the current statement has.
|
unsafeness that the current statement has.
|
||||||
|
|
||||||
- The following Lex::BINLOG_STMT_UNSAFE_COUNT bits list all types
|
|
||||||
of unsafeness that the current statement has issued warnings
|
|
||||||
for.
|
|
||||||
|
|
||||||
Hence, this variable must be big enough to hold
|
|
||||||
2*Lex::BINLOG_STMT_UNSAFE_COUNT bits. This is asserted in @c
|
|
||||||
issue_unsafe_warnings().
|
|
||||||
|
|
||||||
The first and second groups of bits are set by @c
|
|
||||||
decide_logging_format() when it detects that a warning should be
|
|
||||||
issued. The third group of bits is set from @c binlog_query()
|
|
||||||
when a warning is issued. All bits are cleared at the end of the
|
|
||||||
top-level statement.
|
|
||||||
|
|
||||||
This must be a member of THD and not of LEX, because warnings are
|
This must be a member of THD and not of LEX, because warnings are
|
||||||
detected and issued in different places (@c
|
detected and issued in different places (@c
|
||||||
decide_logging_format() and @c binlog_query(), respectively).
|
decide_logging_format() and @c binlog_query(), respectively).
|
||||||
@ -1722,20 +1587,14 @@ private:
|
|||||||
*/
|
*/
|
||||||
uint32 binlog_unsafe_warning_flags;
|
uint32 binlog_unsafe_warning_flags;
|
||||||
|
|
||||||
/**
|
|
||||||
Bit field that determines the type of tables that are about to be
|
|
||||||
be accessed while executing a statement.
|
|
||||||
*/
|
|
||||||
uint32 stmt_accessed_table_flag;
|
|
||||||
|
|
||||||
void issue_unsafe_warnings();
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Number of outstanding table maps, i.e., table maps in the
|
Number of outstanding table maps, i.e., table maps in the
|
||||||
transaction cache.
|
transaction cache.
|
||||||
*/
|
*/
|
||||||
uint binlog_table_maps;
|
uint binlog_table_maps;
|
||||||
public:
|
public:
|
||||||
|
void issue_unsafe_warnings();
|
||||||
|
|
||||||
uint get_binlog_table_maps() const {
|
uint get_binlog_table_maps() const {
|
||||||
return binlog_table_maps;
|
return binlog_table_maps;
|
||||||
}
|
}
|
||||||
|
@ -2297,6 +2297,7 @@ void Query_tables_list::reset_query_tables_list(bool init)
|
|||||||
sroutines_list_own_last= sroutines_list.next;
|
sroutines_list_own_last= sroutines_list.next;
|
||||||
sroutines_list_own_elements= 0;
|
sroutines_list_own_elements= 0;
|
||||||
binlog_stmt_flags= 0;
|
binlog_stmt_flags= 0;
|
||||||
|
stmt_accessed_table_flag= 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
125
sql/sql_lex.h
125
sql/sql_lex.h
@ -1276,6 +1276,125 @@ public:
|
|||||||
DBUG_VOID_RETURN;
|
DBUG_VOID_RETURN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
enum enum_stmt_accessed_table
|
||||||
|
{
|
||||||
|
/*
|
||||||
|
If a transactional table is about to be read. Note that
|
||||||
|
a write implies a read.
|
||||||
|
*/
|
||||||
|
STMT_READS_TRANS_TABLE= 0,
|
||||||
|
/*
|
||||||
|
If a transactional table is about to be updated.
|
||||||
|
*/
|
||||||
|
STMT_WRITES_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a non-transactional table is about to be read. Note that
|
||||||
|
a write implies a read.
|
||||||
|
*/
|
||||||
|
STMT_READS_NON_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a non-transactional table is about to be updated.
|
||||||
|
*/
|
||||||
|
STMT_WRITES_NON_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a temporary transactional table is about to be read. Note
|
||||||
|
that a write implies a read.
|
||||||
|
*/
|
||||||
|
STMT_READS_TEMP_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a temporary transactional table is about to be updated.
|
||||||
|
*/
|
||||||
|
STMT_WRITES_TEMP_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a temporary non-transactional table is about to be read. Note
|
||||||
|
that a write implies a read.
|
||||||
|
*/
|
||||||
|
STMT_READS_TEMP_NON_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
If a temporary non-transactional table is about to be updated.
|
||||||
|
*/
|
||||||
|
STMT_WRITES_TEMP_NON_TRANS_TABLE,
|
||||||
|
/*
|
||||||
|
The last element of the enumeration. Please, if necessary add
|
||||||
|
anything before this.
|
||||||
|
*/
|
||||||
|
STMT_ACCESS_TABLE_COUNT
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
Sets the type of table that is about to be accessed while executing a
|
||||||
|
statement.
|
||||||
|
|
||||||
|
@param accessed_table Enumeration type that defines the type of table,
|
||||||
|
e.g. temporary, transactional, non-transactional.
|
||||||
|
*/
|
||||||
|
inline void set_stmt_accessed_table(enum_stmt_accessed_table accessed_table)
|
||||||
|
{
|
||||||
|
DBUG_ENTER("THD::set_stmt_accessed_table");
|
||||||
|
|
||||||
|
DBUG_ASSERT(accessed_table >= 0 && accessed_table < STMT_ACCESS_TABLE_COUNT);
|
||||||
|
stmt_accessed_table_flag |= (1U << accessed_table);
|
||||||
|
|
||||||
|
DBUG_VOID_RETURN;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
Checks if a type of table is about to be accessed while executing a
|
||||||
|
statement.
|
||||||
|
|
||||||
|
@param accessed_table Enumeration type that defines the type of table,
|
||||||
|
e.g. temporary, transactional, non-transactional.
|
||||||
|
|
||||||
|
@return
|
||||||
|
@retval TRUE if the type of the table is about to be accessed
|
||||||
|
@retval FALSE otherwise
|
||||||
|
*/
|
||||||
|
inline bool stmt_accessed_table(enum_stmt_accessed_table accessed_table)
|
||||||
|
{
|
||||||
|
DBUG_ENTER("THD::stmt_accessed_table");
|
||||||
|
|
||||||
|
DBUG_ASSERT(accessed_table >= 0 && accessed_table < STMT_ACCESS_TABLE_COUNT);
|
||||||
|
|
||||||
|
DBUG_RETURN((stmt_accessed_table_flag & (1U << accessed_table)) != 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
Checks if a temporary table is about to be accessed while executing a
|
||||||
|
statement.
|
||||||
|
|
||||||
|
@return
|
||||||
|
@retval TRUE if a temporary table is about to be accessed
|
||||||
|
@retval FALSE otherwise
|
||||||
|
*/
|
||||||
|
inline bool stmt_accessed_temp_table()
|
||||||
|
{
|
||||||
|
DBUG_ENTER("THD::stmt_accessed_temp_table");
|
||||||
|
|
||||||
|
DBUG_RETURN((stmt_accessed_table_flag &
|
||||||
|
((1U << STMT_READS_TEMP_TRANS_TABLE) |
|
||||||
|
(1U << STMT_WRITES_TEMP_TRANS_TABLE) |
|
||||||
|
(1U << STMT_READS_TEMP_NON_TRANS_TABLE) |
|
||||||
|
(1U << STMT_WRITES_TEMP_NON_TRANS_TABLE))) != 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
Checks if a temporary non-transactional table is about to be accessed
|
||||||
|
while executing a statement.
|
||||||
|
|
||||||
|
@return
|
||||||
|
@retval TRUE if a temporary non-transactional table is about to be
|
||||||
|
accessed
|
||||||
|
@retval FALSE otherwise
|
||||||
|
*/
|
||||||
|
inline bool stmt_accessed_non_trans_temp_table()
|
||||||
|
{
|
||||||
|
DBUG_ENTER("THD::stmt_accessed_non_trans_temp_table");
|
||||||
|
|
||||||
|
DBUG_RETURN((stmt_accessed_table_flag &
|
||||||
|
((1U << STMT_READS_TEMP_NON_TRANS_TABLE) |
|
||||||
|
(1U << STMT_WRITES_TEMP_NON_TRANS_TABLE))) != 0);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
true if the parsed tree contains references to stored procedures
|
true if the parsed tree contains references to stored procedures
|
||||||
or functions, false otherwise
|
or functions, false otherwise
|
||||||
@ -1317,6 +1436,12 @@ private:
|
|||||||
stored procedure has its own LEX object (but no own THD object).
|
stored procedure has its own LEX object (but no own THD object).
|
||||||
*/
|
*/
|
||||||
uint32 binlog_stmt_flags;
|
uint32 binlog_stmt_flags;
|
||||||
|
|
||||||
|
/**
|
||||||
|
Bit field that determines the type of tables that are about to be
|
||||||
|
be accessed while executing a statement.
|
||||||
|
*/
|
||||||
|
uint32 stmt_accessed_table_flag;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -5640,7 +5640,6 @@ void THD::reset_for_next_command()
|
|||||||
|
|
||||||
thd->reset_current_stmt_binlog_format_row();
|
thd->reset_current_stmt_binlog_format_row();
|
||||||
thd->binlog_unsafe_warning_flags= 0;
|
thd->binlog_unsafe_warning_flags= 0;
|
||||||
thd->stmt_accessed_table_flag= 0;
|
|
||||||
|
|
||||||
DBUG_PRINT("debug",
|
DBUG_PRINT("debug",
|
||||||
("is_current_stmt_binlog_format_row(): %d",
|
("is_current_stmt_binlog_format_row(): %d",
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
SET(ARCHIVE_SOURCES azio.c ha_archive.cc ha_archive.h)
|
SET(ARCHIVE_SOURCES azio.c ha_archive.cc ha_archive.h)
|
||||||
MYSQL_ADD_PLUGIN(archive ${ARCHIVE_SOURCES} STORAGE_ENGINE LINK_LIBRARIES ${ZLIB_LIBRARY})
|
MYSQL_ADD_PLUGIN(archive ${ARCHIVE_SOURCES} STORAGE_ENGINE LINK_LIBRARIES ${ZLIB_LIBRARY})
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,6 +13,5 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
SET(BLACKHOLE_SOURCES ha_blackhole.cc ha_blackhole.h)
|
SET(BLACKHOLE_SOURCES ha_blackhole.cc ha_blackhole.h)
|
||||||
MYSQL_ADD_PLUGIN(blackhole ${BLACKHOLE_SOURCES} STORAGE_ENGINE)
|
MYSQL_ADD_PLUGIN(blackhole ${BLACKHOLE_SOURCES} STORAGE_ENGINE)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Oracle/Innobase Oy
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -11,7 +11,7 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
# This is the CMakeLists for InnoDB Plugin
|
# This is the CMakeLists for InnoDB Plugin
|
||||||
|
|
||||||
@ -43,7 +43,7 @@ ENDIF()
|
|||||||
# Enable InnoDB's UNIV_DEBUG if MySQL's WITH_DEBUG[_FULL] is defined
|
# Enable InnoDB's UNIV_DEBUG if MySQL's WITH_DEBUG[_FULL] is defined
|
||||||
# enable when this bug is resolved:
|
# enable when this bug is resolved:
|
||||||
# Bug#54861 Additional connections not handled properly in mtr --embedded
|
# Bug#54861 Additional connections not handled properly in mtr --embedded
|
||||||
#IF(WITH_DEBUG OR WITH_DEBUG_FULL)
|
#IF(WITH_DEBUG)
|
||||||
# ADD_DEFINITIONS("-DUNIV_DEBUG")
|
# ADD_DEFINITIONS("-DUNIV_DEBUG")
|
||||||
#ENDIF()
|
#ENDIF()
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1117,7 +1117,6 @@ get_thread_mutex_locker_v1(PSI_mutex_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_mutex= pfs_mutex;
|
pfs_locker->m_target.m_mutex= pfs_mutex;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1163,7 +1162,6 @@ get_thread_rwlock_locker_v1(PSI_rwlock_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_rwlock= pfs_rwlock;
|
pfs_locker->m_target.m_rwlock= pfs_rwlock;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1222,7 +1220,6 @@ get_thread_cond_locker_v1(PSI_cond_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_cond= pfs_cond;
|
pfs_locker->m_target.m_cond= pfs_cond;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1267,7 +1264,6 @@ get_thread_table_locker_v1(PSI_table_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_table= pfs_table;
|
pfs_locker->m_target.m_table= pfs_table;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1320,7 +1316,6 @@ get_thread_file_name_locker_v1(PSI_file_locker_state *state,
|
|||||||
|
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_file= pfs_file;
|
pfs_locker->m_target.m_file= pfs_file;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1372,7 +1367,6 @@ get_thread_file_stream_locker_v1(PSI_file_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_file= pfs_file;
|
pfs_locker->m_target.m_file= pfs_file;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
@ -1441,7 +1435,6 @@ get_thread_file_descriptor_locker_v1(PSI_file_locker_state *state,
|
|||||||
}
|
}
|
||||||
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
PFS_wait_locker *pfs_locker= &pfs_thread->m_wait_locker_stack
|
||||||
[pfs_thread->m_wait_locker_count];
|
[pfs_thread->m_wait_locker_count];
|
||||||
pfs_locker->m_waits_current.m_wait_class= NO_WAIT_CLASS;
|
|
||||||
|
|
||||||
pfs_locker->m_target.m_file= pfs_file;
|
pfs_locker->m_target.m_file= pfs_file;
|
||||||
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
pfs_locker->m_waits_current.m_thread= pfs_thread;
|
||||||
|
@ -80,25 +80,10 @@ void cleanup_events_waits_history_long(void)
|
|||||||
events_waits_history_long_array= NULL;
|
events_waits_history_long_array= NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void copy_events_waits(PFS_events_waits *dest,
|
static inline void copy_events_waits(PFS_events_waits *dest,
|
||||||
const PFS_events_waits *source)
|
const PFS_events_waits *source)
|
||||||
{
|
{
|
||||||
/* m_wait_class must be the first member of PFS_events_waits. */
|
memcpy(dest, source, sizeof(PFS_events_waits));
|
||||||
compile_time_assert(offsetof(PFS_events_waits, m_wait_class) == 0);
|
|
||||||
|
|
||||||
char* dest_body= (reinterpret_cast<char*> (dest)) + sizeof(events_waits_class);
|
|
||||||
const char* source_body= (reinterpret_cast<const char*> (source))
|
|
||||||
+ sizeof(events_waits_class);
|
|
||||||
|
|
||||||
/* See comments in table_events_waits_common::make_row(). */
|
|
||||||
|
|
||||||
/* Signal readers they are about to read garbage ... */
|
|
||||||
dest->m_wait_class= NO_WAIT_CLASS;
|
|
||||||
/* ... that this can generate. */
|
|
||||||
memcpy(dest_body, source_body,
|
|
||||||
sizeof(PFS_events_waits) - sizeof(events_waits_class));
|
|
||||||
/* Signal readers the record is now clean again. */
|
|
||||||
dest->m_wait_class= source->m_wait_class;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -116,9 +101,7 @@ void insert_events_waits_history(PFS_thread *thread, PFS_events_waits *wait)
|
|||||||
causing a potential race condition.
|
causing a potential race condition.
|
||||||
We are not testing for this and insert a possibly empty record,
|
We are not testing for this and insert a possibly empty record,
|
||||||
to make this thread (the writer) faster.
|
to make this thread (the writer) faster.
|
||||||
This is ok, the truncated data will have
|
This is ok, the readers of m_waits_history will filter this out.
|
||||||
wait->m_wait_class == NO_WAIT_CLASS,
|
|
||||||
which readers of m_waits_history will filter out.
|
|
||||||
*/
|
*/
|
||||||
copy_events_waits(&thread->m_waits_history[index], wait);
|
copy_events_waits(&thread->m_waits_history[index], wait);
|
||||||
|
|
||||||
|
@ -97,7 +97,7 @@ struct PFS_events_waits
|
|||||||
- TRUNCATE EVENTS_WAITS_HISTORY
|
- TRUNCATE EVENTS_WAITS_HISTORY
|
||||||
- TRUNCATE EVENTS_WAITS_HISTORY_LONG
|
- TRUNCATE EVENTS_WAITS_HISTORY_LONG
|
||||||
*/
|
*/
|
||||||
volatile events_waits_class m_wait_class;
|
events_waits_class m_wait_class;
|
||||||
/** Executing thread. */
|
/** Executing thread. */
|
||||||
PFS_thread *m_thread;
|
PFS_thread *m_thread;
|
||||||
/** Instrument metadata. */
|
/** Instrument metadata. */
|
||||||
|
@ -217,16 +217,8 @@ void table_events_waits_common::make_row(bool thread_own_wait,
|
|||||||
or 8 atomics per recorded event.
|
or 8 atomics per recorded event.
|
||||||
The problem is that we record a *lot* of events ...
|
The problem is that we record a *lot* of events ...
|
||||||
|
|
||||||
Instead, a *dirty* marking is done using m_wait_class.
|
This code is prepared to accept *dirty* records,
|
||||||
Using m_wait_class alone does not guarantee anything, it just filters
|
and sanitizes all the data before returning a row.
|
||||||
out most of the bad data.
|
|
||||||
This is acceptable because this code is garbage-proof,
|
|
||||||
and won't crash on bad data, only display it,
|
|
||||||
very rarely (which is accepted).
|
|
||||||
|
|
||||||
If a bad record is displayed, it's a very transient failure:
|
|
||||||
the next select * from EVENTS_WAITS_CURRENT/_HISTORY/_HISTORY_LONG will
|
|
||||||
show clean data again.
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
m_row.m_thread_internal_id= safe_thread->m_thread_internal_id;
|
m_row.m_thread_internal_id= safe_thread->m_thread_internal_id;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2007 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/zlib
|
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/zlib
|
||||||
${CMAKE_SOURCE_DIR}/sql
|
${CMAKE_SOURCE_DIR}/sql
|
||||||
${CMAKE_SOURCE_DIR}/regex
|
${CMAKE_SOURCE_DIR}/regex
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2007 MySQL AB, 2009 Sun Microsystems,Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2007 MySQL AB, 2009 Sun Microsystems, Inc
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,6 +13,5 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
|
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
|
||||||
ADD_LIBRARY(mytap tap.c)
|
ADD_LIBRARY(mytap tap.c)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include
|
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include
|
||||||
${SSL_INCLUDE_DIRS})
|
${SSL_INCLUDE_DIRS})
|
||||||
ADD_DEFINITIONS(${SSL_DEFINES})
|
ADD_DEFINITIONS(${SSL_DEFINES})
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Copyright (C) 2006 MySQL AB
|
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -13,7 +13,6 @@
|
|||||||
# 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-1301 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(
|
INCLUDE_DIRECTORIES(
|
||||||
${CMAKE_SOURCE_DIR}/include
|
${CMAKE_SOURCE_DIR}/include
|
||||||
${CMAKE_SOURCE_DIR}/zlib
|
${CMAKE_SOURCE_DIR}/zlib
|
||||||
|
Loading…
x
Reference in New Issue
Block a user