1
SET @global_thread_cache_size = @@GLOBAL.thread_cache_size;
4
SET @@GLOBAL.thread_cache_size=3;
5
SHOW STATUS LIKE 'Threads_cached';
9
** Connecting conn1 using username 'root' **
10
** Connecting conn2 using username 'root' **
11
** Connecting conn3 using username 'root' **
12
** Connecting conn4 using username 'root' **
13
** Connection default **
14
SHOW STATUS LIKE 'Threads_cached';
18
** Disconnecting conn1,conn2,conn3,conn4 **
19
SHOW STATUS LIKE 'Threads_cached';
23
SET @@GLOBAL.thread_cache_size= 1;
24
** Connecting conn1 using username 'root' **
25
** Connecting conn2 using username 'root' **
27
** Disconnecting conn1,conn2 **
28
SHOW STATUS LIKE 'Threads_cached';
32
SET @@GLOBAL.thread_cache_size = @global_thread_cache_size;