Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
96041f8e
Commit
96041f8e
authored
Dec 20, 2011
by
Vladislav Vaintroub
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make sys_vars suite pass
parent
df48c9bf
Changes
13
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
361 additions
and
18 deletions
+361
-18
mysql-test/include/mysqld--help.inc
mysql-test/include/mysqld--help.inc
+2
-2
mysql-test/r/mysqld--help-notwin.result
mysql-test/r/mysqld--help-notwin.result
+2
-6
mysql-test/suite/sys_vars/r/thread_pool_idle_timeout_basic.result
...st/suite/sys_vars/r/thread_pool_idle_timeout_basic.result
+47
-0
mysql-test/suite/sys_vars/r/thread_pool_max_threads_basic.result
...est/suite/sys_vars/r/thread_pool_max_threads_basic.result
+47
-0
mysql-test/suite/sys_vars/r/thread_pool_size_basic.result
mysql-test/suite/sys_vars/r/thread_pool_size_basic.result
+41
-0
mysql-test/suite/sys_vars/r/thread_pool_stall_limit_basic.result
...est/suite/sys_vars/r/thread_pool_stall_limit_basic.result
+47
-0
mysql-test/suite/sys_vars/t/slow_launch_time_func.test
mysql-test/suite/sys_vars/t/slow_launch_time_func.test
+1
-4
mysql-test/suite/sys_vars/t/thread_cache_size_func.test
mysql-test/suite/sys_vars/t/thread_cache_size_func.test
+1
-2
mysql-test/suite/sys_vars/t/thread_pool_idle_timeout_basic.test
...test/suite/sys_vars/t/thread_pool_idle_timeout_basic.test
+42
-0
mysql-test/suite/sys_vars/t/thread_pool_max_threads_basic.test
...-test/suite/sys_vars/t/thread_pool_max_threads_basic.test
+42
-0
mysql-test/suite/sys_vars/t/thread_pool_size_basic.test
mysql-test/suite/sys_vars/t/thread_pool_size_basic.test
+46
-0
mysql-test/suite/sys_vars/t/thread_pool_stall_limit_basic.test
...-test/suite/sys_vars/t/thread_pool_stall_limit_basic.test
+42
-0
sql/threadpool_unix.cc
sql/threadpool_unix.cc
+1
-4
No files found.
mysql-test/include/mysqld--help.inc
View file @
96041f8e
...
@@ -18,11 +18,11 @@ perl;
...
@@ -18,11 +18,11 @@ perl;
# their paths may vary:
# their paths may vary:
@
skipvars
=
qw
/
basedir
open
-
files
-
limit
general
-
log
-
file
log
plugin
-
dir
@
skipvars
=
qw
/
basedir
open
-
files
-
limit
general
-
log
-
file
log
plugin
-
dir
log
-
slow
-
queries
pid
-
file
slow
-
query
-
log
-
file
log
-
basename
log
-
slow
-
queries
pid
-
file
slow
-
query
-
log
-
file
log
-
basename
datadir
slave
-
load
-
tmpdir
tmpdir
socket
/
;
datadir
slave
-
load
-
tmpdir
tmpdir
socket
/
;
# Plugins which may or may not be there:
# Plugins which may or may not be there:
@
plugins
=
qw
/
innodb
ndb
archive
blackhole
federated
partition
ndbcluster
feedback
debug
temp
-
pool
ssl
des
-
key
-
file
@
plugins
=
qw
/
innodb
ndb
archive
blackhole
federated
partition
ndbcluster
feedback
debug
temp
-
pool
ssl
des
-
key
-
file
xtradb
thread
-
concurrency
super
-
large
-
pages
mutex
-
deadlock
-
detector
null
-
audit
maria
aria
pbxt
oqgraph
sphinx
/
;
xtradb
thread
-
concurrency
super
-
large
-
pages
mutex
-
deadlock
-
detector
null
-
audit
maria
aria
pbxt
oqgraph
sphinx
thread
-
handling
thread
-
pool
/
;
# And substitute the content some environment variables with their
# And substitute the content some environment variables with their
# names:
# names:
...
...
mysql-test/r/mysqld--help-notwin.result
View file @
96041f8e
...
@@ -813,9 +813,6 @@ The following options may be given as the first argument:
...
@@ -813,9 +813,6 @@ The following options may be given as the first argument:
(Defaults to on; use --skip-thread-alarm to disable.)
(Defaults to on; use --skip-thread-alarm to disable.)
--thread-cache-size=#
--thread-cache-size=#
How many threads we should keep in a cache for reuse
How many threads we should keep in a cache for reuse
--thread-handling=name
Define threads usage for handling queries, one of
one-thread-per-connection, no-threads
--thread-stack=# The stack size for each thread
--thread-stack=# The stack size for each thread
--time-format=name The TIME format (ignored)
--time-format=name The TIME format (ignored)
--timed-mutexes Specify whether to time mutexes (only InnoDB mutexes are
--timed-mutexes Specify whether to time mutexes (only InnoDB mutexes are
...
@@ -956,7 +953,7 @@ lower-case-table-names 1
...
@@ -956,7 +953,7 @@ lower-case-table-names 1
master-info-file master.info
master-info-file master.info
master-retry-count 86400
master-retry-count 86400
master-verify-checksum FALSE
master-verify-checksum FALSE
max-allowed-packet
1048576
max-allowed-packet
8388608
max-binlog-cache-size 18446744073709547520
max-binlog-cache-size 18446744073709547520
max-binlog-dump-events 0
max-binlog-dump-events 0
max-binlog-size 1073741824
max-binlog-size 1073741824
...
@@ -968,7 +965,7 @@ max-error-count 64
...
@@ -968,7 +965,7 @@ max-error-count 64
max-heap-table-size 16777216
max-heap-table-size 16777216
max-join-size 18446744073709551615
max-join-size 18446744073709551615
max-length-for-sort-data 1024
max-length-for-sort-data 1024
max-long-data-size
1048576
max-long-data-size
8388608
max-prepared-stmt-count 16382
max-prepared-stmt-count 16382
max-relay-log-size 0
max-relay-log-size 0
max-seeks-for-key 18446744073709551615
max-seeks-for-key 18446744073709551615
...
@@ -1087,7 +1084,6 @@ table-open-cache 400
...
@@ -1087,7 +1084,6 @@ table-open-cache 400
tc-heuristic-recover COMMIT
tc-heuristic-recover COMMIT
thread-alarm TRUE
thread-alarm TRUE
thread-cache-size 0
thread-cache-size 0
thread-handling one-thread-per-connection
thread-stack 294912
thread-stack 294912
time-format %H:%i:%s
time-format %H:%i:%s
timed-mutexes FALSE
timed-mutexes FALSE
...
...
mysql-test/suite/sys_vars/r/thread_pool_idle_timeout_basic.result
0 → 100644
View file @
96041f8e
SET @start_global_value = @@global.thread_pool_idle_timeout;
select @@global.thread_pool_idle_timeout;
@@global.thread_pool_idle_timeout
60
select @@session.thread_pool_idle_timeout;
ERROR HY000: Variable 'thread_pool_idle_timeout' is a GLOBAL variable
show global variables like 'thread_pool_idle_timeout';
Variable_name Value
thread_pool_idle_timeout 60
show session variables like 'thread_pool_idle_timeout';
Variable_name Value
thread_pool_idle_timeout 60
select * from information_schema.global_variables where variable_name='thread_pool_idle_timeout';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_IDLE_TIMEOUT 60
select * from information_schema.session_variables where variable_name='thread_pool_idle_timeout';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_IDLE_TIMEOUT 60
set global thread_pool_idle_timeout=60;
select @@global.thread_pool_idle_timeout;
@@global.thread_pool_idle_timeout
60
set global thread_pool_idle_timeout=4294967295;
select @@global.thread_pool_idle_timeout;
@@global.thread_pool_idle_timeout
4294967295
set session thread_pool_idle_timeout=1;
ERROR HY000: Variable 'thread_pool_idle_timeout' is a GLOBAL variable and should be set with SET GLOBAL
set global thread_pool_idle_timeout=1.1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_idle_timeout'
set global thread_pool_idle_timeout=1e1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_idle_timeout'
set global thread_pool_idle_timeout="foo";
ERROR 42000: Incorrect argument type to variable 'thread_pool_idle_timeout'
set global thread_pool_idle_timeout=-1;
Warnings:
Warning 1292 Truncated incorrect thread_pool_idle_timeout value: '-1'
select @@global.thread_pool_idle_timeout;
@@global.thread_pool_idle_timeout
1
set global thread_pool_idle_timeout=10000000000;
Warnings:
Warning 1292 Truncated incorrect thread_pool_idle_timeout value: '10000000000'
select @@global.thread_pool_idle_timeout;
@@global.thread_pool_idle_timeout
4294967295
SET @@global.thread_pool_idle_timeout = @start_global_value;
mysql-test/suite/sys_vars/r/thread_pool_max_threads_basic.result
0 → 100644
View file @
96041f8e
SET @start_global_value = @@global.thread_pool_max_threads;
select @@global.thread_pool_max_threads;
@@global.thread_pool_max_threads
500
select @@session.thread_pool_max_threads;
ERROR HY000: Variable 'thread_pool_max_threads' is a GLOBAL variable
show global variables like 'thread_pool_max_threads';
Variable_name Value
thread_pool_max_threads 500
show session variables like 'thread_pool_max_threads';
Variable_name Value
thread_pool_max_threads 500
select * from information_schema.global_variables where variable_name='thread_pool_max_threads';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_MAX_THREADS 500
select * from information_schema.session_variables where variable_name='thread_pool_max_threads';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_MAX_THREADS 500
set global thread_pool_max_threads=1;
select @@global.thread_pool_max_threads;
@@global.thread_pool_max_threads
1
set global thread_pool_max_threads=4294967295;
select @@global.thread_pool_max_threads;
@@global.thread_pool_max_threads
4294967295
set session thread_pool_max_threads=1;
ERROR HY000: Variable 'thread_pool_max_threads' is a GLOBAL variable and should be set with SET GLOBAL
set global thread_pool_max_threads=1.1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_max_threads'
set global thread_pool_max_threads=1e1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_max_threads'
set global thread_pool_max_threads="foo";
ERROR 42000: Incorrect argument type to variable 'thread_pool_max_threads'
set global thread_pool_max_threads=0;
Warnings:
Warning 1292 Truncated incorrect thread_pool_max_threads value: '0'
select @@global.thread_pool_max_threads;
@@global.thread_pool_max_threads
1
set global thread_pool_max_threads=10000000000;
Warnings:
Warning 1292 Truncated incorrect thread_pool_max_threads value: '10000000000'
select @@global.thread_pool_max_threads;
@@global.thread_pool_max_threads
4294967295
SET @@global.thread_pool_max_threads = @start_global_value;
mysql-test/suite/sys_vars/r/thread_pool_size_basic.result
0 → 100644
View file @
96041f8e
SET @start_global_value = @@global.thread_pool_size;
select @@global.thread_pool_size;
@@global.thread_pool_size
1
select @@session.thread_pool_size;
ERROR HY000: Variable 'thread_pool_size' is a GLOBAL variable
show global variables like 'thread_pool_size';
Variable_name Value
thread_pool_size #
show session variables like 'thread_pool_size';
Variable_name Value
thread_pool_size #
select * from information_schema.global_variables where variable_name='thread_pool_size';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_SIZE #
select * from information_schema.session_variables where variable_name='thread_pool_size';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_SIZE #
set global thread_pool_size=1;
select @@global.thread_pool_size;
@@global.thread_pool_size
1
set global thread_pool_size=128;
select @@global.thread_pool_size;
@@global.thread_pool_size
128
set session thread_pool_size=1;
ERROR HY000: Variable 'thread_pool_size' is a GLOBAL variable and should be set with SET GLOBAL
set global thread_pool_size=1.1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_size'
set global thread_pool_size=1e1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_size'
set global thread_pool_size="foo";
ERROR 42000: Incorrect argument type to variable 'thread_pool_size'
set global thread_pool_size=-1;
Warnings:
Warning 1292 Truncated incorrect thread_pool_size value: '-1'
set global thread_pool_size=100000;
Warnings:
Warning 1292 Truncated incorrect thread_pool_size value: '100000'
SET @@global.thread_pool_size = @start_global_value;
mysql-test/suite/sys_vars/r/thread_pool_stall_limit_basic.result
0 → 100644
View file @
96041f8e
SET @start_global_value = @@global.thread_pool_stall_limit;
select @@global.thread_pool_stall_limit;
@@global.thread_pool_stall_limit
500
select @@session.thread_pool_stall_limit;
ERROR HY000: Variable 'thread_pool_stall_limit' is a GLOBAL variable
show global variables like 'thread_pool_stall_limit';
Variable_name Value
thread_pool_stall_limit 500
show session variables like 'thread_pool_stall_limit';
Variable_name Value
thread_pool_stall_limit 500
select * from information_schema.global_variables where variable_name='thread_pool_stall_limit';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_STALL_LIMIT 500
select * from information_schema.session_variables where variable_name='thread_pool_stall_limit';
VARIABLE_NAME VARIABLE_VALUE
THREAD_POOL_STALL_LIMIT 500
set global thread_pool_stall_limit=60;
select @@global.thread_pool_stall_limit;
@@global.thread_pool_stall_limit
60
set global thread_pool_stall_limit=4294967295;
select @@global.thread_pool_stall_limit;
@@global.thread_pool_stall_limit
4294967295
set session thread_pool_stall_limit=1;
ERROR HY000: Variable 'thread_pool_stall_limit' is a GLOBAL variable and should be set with SET GLOBAL
set global thread_pool_stall_limit=1.1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_stall_limit'
set global thread_pool_stall_limit=1e1;
ERROR 42000: Incorrect argument type to variable 'thread_pool_stall_limit'
set global thread_pool_stall_limit="foo";
ERROR 42000: Incorrect argument type to variable 'thread_pool_stall_limit'
set global thread_pool_stall_limit=-1;
Warnings:
Warning 1292 Truncated incorrect thread_pool_stall_limit value: '-1'
select @@global.thread_pool_stall_limit;
@@global.thread_pool_stall_limit
60
set global thread_pool_stall_limit=10000000000;
Warnings:
Warning 1292 Truncated incorrect thread_pool_stall_limit value: '10000000000'
select @@global.thread_pool_stall_limit;
@@global.thread_pool_stall_limit
4294967295
set @@global.thread_pool_stall_limit = @start_global_value;
mysql-test/suite/sys_vars/t/slow_launch_time_func.test
View file @
96041f8e
...
@@ -29,10 +29,7 @@
...
@@ -29,10 +29,7 @@
#
#
# Setup
# Setup
#
#
--
source
include
/
not_threadpool
.
inc
--
source
include
/
one_thread_per_connection
.
inc
--
source
include
/
not_embedded
.
inc
--
source
include
/
not_threadpool
.
inc
SET
@
global_slow_launch_time
=
@@
GLOBAL
.
slow_launch_time
;
SET
@
global_slow_launch_time
=
@@
GLOBAL
.
slow_launch_time
;
--
echo
**
Connection
default
**
--
echo
**
Connection
default
**
...
...
mysql-test/suite/sys_vars/t/thread_cache_size_func.test
View file @
96041f8e
...
@@ -27,9 +27,8 @@
...
@@ -27,9 +27,8 @@
# Setup
# Setup
#
#
--
source
include
/
not_embedded
.
inc
--
source
include
/
not_threadpool
.
inc
--
source
include
/
one_thread_per_connection
.
inc
SET
@
global_thread_cache_size
=
@@
GLOBAL
.
thread_cache_size
;
SET
@
global_thread_cache_size
=
@@
GLOBAL
.
thread_cache_size
;
FLUSH
STATUS
;
FLUSH
STATUS
;
...
...
mysql-test/suite/sys_vars/t/thread_pool_idle_timeout_basic.test
0 → 100644
View file @
96041f8e
# uint global
SET
@
start_global_value
=
@@
global
.
thread_pool_idle_timeout
;
#
# exists as global only
#
select
@@
global
.
thread_pool_idle_timeout
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
select
@@
session
.
thread_pool_idle_timeout
;
show
global
variables
like
'thread_pool_idle_timeout'
;
show
session
variables
like
'thread_pool_idle_timeout'
;
select
*
from
information_schema
.
global_variables
where
variable_name
=
'thread_pool_idle_timeout'
;
select
*
from
information_schema
.
session_variables
where
variable_name
=
'thread_pool_idle_timeout'
;
#
# show that it's writable
#
set
global
thread_pool_idle_timeout
=
60
;
select
@@
global
.
thread_pool_idle_timeout
;
set
global
thread_pool_idle_timeout
=
4294967295
;
select
@@
global
.
thread_pool_idle_timeout
;
--
error
ER_GLOBAL_VARIABLE
set
session
thread_pool_idle_timeout
=
1
;
#
# incorrect types
#
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_idle_timeout
=
1.1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_idle_timeout
=
1
e1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_idle_timeout
=
"foo"
;
set
global
thread_pool_idle_timeout
=-
1
;
select
@@
global
.
thread_pool_idle_timeout
;
set
global
thread_pool_idle_timeout
=
10000000000
;
select
@@
global
.
thread_pool_idle_timeout
;
SET
@@
global
.
thread_pool_idle_timeout
=
@
start_global_value
;
mysql-test/suite/sys_vars/t/thread_pool_max_threads_basic.test
0 → 100644
View file @
96041f8e
# uint global
SET
@
start_global_value
=
@@
global
.
thread_pool_max_threads
;
#
# exists as global only
#
select
@@
global
.
thread_pool_max_threads
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
select
@@
session
.
thread_pool_max_threads
;
show
global
variables
like
'thread_pool_max_threads'
;
show
session
variables
like
'thread_pool_max_threads'
;
select
*
from
information_schema
.
global_variables
where
variable_name
=
'thread_pool_max_threads'
;
select
*
from
information_schema
.
session_variables
where
variable_name
=
'thread_pool_max_threads'
;
#
# show that it's writable
#
set
global
thread_pool_max_threads
=
1
;
select
@@
global
.
thread_pool_max_threads
;
set
global
thread_pool_max_threads
=
4294967295
;
select
@@
global
.
thread_pool_max_threads
;
--
error
ER_GLOBAL_VARIABLE
set
session
thread_pool_max_threads
=
1
;
#
# incorrect types
#
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_max_threads
=
1.1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_max_threads
=
1
e1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_max_threads
=
"foo"
;
set
global
thread_pool_max_threads
=
0
;
select
@@
global
.
thread_pool_max_threads
;
set
global
thread_pool_max_threads
=
10000000000
;
select
@@
global
.
thread_pool_max_threads
;
SET
@@
global
.
thread_pool_max_threads
=
@
start_global_value
;
mysql-test/suite/sys_vars/t/thread_pool_size_basic.test
0 → 100644
View file @
96041f8e
# uint global
SET
@
start_global_value
=
@@
global
.
thread_pool_size
;
#
# exists as global only
#
--
replace_column
2
#
select
@@
global
.
thread_pool_size
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
select
@@
session
.
thread_pool_size
;
--
replace_column
2
#
show
global
variables
like
'thread_pool_size'
;
--
replace_column
2
#
show
session
variables
like
'thread_pool_size'
;
--
replace_column
2
#
select
*
from
information_schema
.
global_variables
where
variable_name
=
'thread_pool_size'
;
--
replace_column
2
#
select
*
from
information_schema
.
session_variables
where
variable_name
=
'thread_pool_size'
;
--
replace_column
2
#
#
# show that it's writable
#
set
global
thread_pool_size
=
1
;
select
@@
global
.
thread_pool_size
;
set
global
thread_pool_size
=
128
;
select
@@
global
.
thread_pool_size
;
--
error
ER_GLOBAL_VARIABLE
set
session
thread_pool_size
=
1
;
#
# incorrect types
#
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_size
=
1.1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_size
=
1
e1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_size
=
"foo"
;
set
global
thread_pool_size
=-
1
;
set
global
thread_pool_size
=
100000
;
SET
@@
global
.
thread_pool_size
=
@
start_global_value
;
mysql-test/suite/sys_vars/t/thread_pool_stall_limit_basic.test
0 → 100644
View file @
96041f8e
# uint global
SET
@
start_global_value
=
@@
global
.
thread_pool_stall_limit
;
#
# exists as global only
#
select
@@
global
.
thread_pool_stall_limit
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
select
@@
session
.
thread_pool_stall_limit
;
show
global
variables
like
'thread_pool_stall_limit'
;
show
session
variables
like
'thread_pool_stall_limit'
;
select
*
from
information_schema
.
global_variables
where
variable_name
=
'thread_pool_stall_limit'
;
select
*
from
information_schema
.
session_variables
where
variable_name
=
'thread_pool_stall_limit'
;
#
# show that it's writable
#
set
global
thread_pool_stall_limit
=
60
;
select
@@
global
.
thread_pool_stall_limit
;
set
global
thread_pool_stall_limit
=
4294967295
;
select
@@
global
.
thread_pool_stall_limit
;
--
error
ER_GLOBAL_VARIABLE
set
session
thread_pool_stall_limit
=
1
;
#
# incorrect types
#
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_stall_limit
=
1.1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_stall_limit
=
1
e1
;
--
error
ER_WRONG_TYPE_FOR_VAR
set
global
thread_pool_stall_limit
=
"foo"
;
set
global
thread_pool_stall_limit
=-
1
;
select
@@
global
.
thread_pool_stall_limit
;
set
global
thread_pool_stall_limit
=
10000000000
;
select
@@
global
.
thread_pool_stall_limit
;
set
@@
global
.
thread_pool_stall_limit
=
@
start_global_value
;
sql/threadpool_unix.cc
View file @
96041f8e
...
@@ -1136,18 +1136,15 @@ static int change_group(connection_t *c,
...
@@ -1136,18 +1136,15 @@ static int change_group(connection_t *c,
if
(
c
->
logged_in
)
if
(
c
->
logged_in
)
io_poll_disassociate_fd
(
old_group
->
pollfd
,
fd
);
io_poll_disassociate_fd
(
old_group
->
pollfd
,
fd
);
c
->
thread_group
->
connection_count
--
;
c
->
thread_group
->
connection_count
--
;
mysql_mutex_lock
(
&
old_group
->
mutex
);
mysql_mutex_
un
lock
(
&
old_group
->
mutex
);
/* Add connection to the new group. */
/* Add connection to the new group. */
mysql_mutex_lock
(
&
new_group
->
mutex
);
mysql_mutex_lock
(
&
new_group
->
mutex
);
c
->
thread_group
=
new_group
;
c
->
thread_group
=
new_group
;
new_group
->
connection_count
++
;
new_group
->
connection_count
++
;
/* Ensure that there is a listener in the new group. */
/* Ensure that there is a listener in the new group. */
if
(
!
new_group
->
thread_count
&&
!
new_group
->
pending_thread_start_count
)
if
(
!
new_group
->
thread_count
&&
!
new_group
->
pending_thread_start_count
)
ret
=
create_worker
(
new_group
);
ret
=
create_worker
(
new_group
);
mysql_mutex_unlock
(
&
new_group
->
mutex
);
mysql_mutex_unlock
(
&
new_group
->
mutex
);
return
ret
;
return
ret
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment