#196 better thread cache hit rate with pools-of-threads
This commit is contained in:
parent
8f33b55fea
commit
7554f10e52
1 changed files with 27 additions and 23 deletions
|
@ -2732,29 +2732,33 @@ sub mysql_stats {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Thread cache
|
# Thread cache
|
||||||
#if ( $myvar{'thread_cache_size'} eq 0 ) {
|
if ( $myvar{'thread_cache_size'} eq 0 ) {
|
||||||
# badprint "Thread cache is disabled";
|
badprint "Thread cache is disabled";
|
||||||
# push( @generalrec, "Set thread_cache_size to 4 as a starting value" );
|
push( @generalrec, "Set thread_cache_size to 4 as a starting value" );
|
||||||
# push( @adjvars, "thread_cache_size (start at 4)" );
|
push( @adjvars, "thread_cache_size (start at 4)" );
|
||||||
#} else {
|
} else {
|
||||||
# if ( $mycalc{'thread_cache_hit_rate'} <= 50 ) {
|
if ( defined($myvar{'thread_cache_size'}) and $myvar{'thread_cache_size'} == 'pools-of-threads') {
|
||||||
# badprint
|
infoprint "Thread cache hit rate: not used with pool-of-threads";
|
||||||
# "Thread cache hit rate: $mycalc{'thread_cache_hit_rate'}% ("
|
} else {
|
||||||
# . hr_num( $mystat{'Threads_created'} )
|
if ( $mycalc{'thread_cache_hit_rate'} <= 50 ) {
|
||||||
# . " created / "
|
badprint
|
||||||
# . hr_num( $mystat{'Connections'} )
|
"Thread cache hit rate: $mycalc{'thread_cache_hit_rate'}% ("
|
||||||
# . " connections)";
|
. hr_num( $mystat{'Threads_created'} )
|
||||||
# push( @adjvars,
|
. " created / "
|
||||||
# "thread_cache_size (> $myvar{'thread_cache_size'})" );
|
. hr_num( $mystat{'Connections'} )
|
||||||
# } else {
|
. " connections)";
|
||||||
# goodprint
|
push( @adjvars,
|
||||||
# "Thread cache hit rate: $mycalc{'thread_cache_hit_rate'}% ("
|
"thread_cache_size (> $myvar{'thread_cache_size'})" );
|
||||||
# . hr_num( $mystat{'Threads_created'} )
|
} else {
|
||||||
# . " created / "
|
goodprint
|
||||||
# . hr_num( $mystat{'Connections'} )
|
"Thread cache hit rate: $mycalc{'thread_cache_hit_rate'}% ("
|
||||||
# . " connections)";
|
. hr_num( $mystat{'Threads_created'} )
|
||||||
# }
|
. " created / "
|
||||||
#}
|
. hr_num( $mystat{'Connections'} )
|
||||||
|
. " connections)";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Table cache
|
# Table cache
|
||||||
my $table_cache_var = "";
|
my $table_cache_var = "";
|
||||||
|
|
Loading…
Reference in a new issue