mirror of
https://github.com/MariaDB/server.git
synced 2025-01-18 13:02:28 +01:00
refs #5464 merge fix from 6.5.0 for printing partitioned counters from within the handlerton
git-svn-id: file:///svn/mysql/tokudb-engine/tokudb-engine@48126 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
32b66973c9
commit
00aaa7a715
1 changed files with 14 additions and 0 deletions
|
@ -11,6 +11,7 @@
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include "toku_os.h"
|
#include "toku_os.h"
|
||||||
#include "toku_time.h"
|
#include "toku_time.h"
|
||||||
|
#include "partitioned_counter.h"
|
||||||
|
|
||||||
/* We define DTRACE after mysql_priv.h in case it disabled dtrace in the main server */
|
/* We define DTRACE after mysql_priv.h in case it disabled dtrace in the main server */
|
||||||
#ifdef HAVE_DTRACE
|
#ifdef HAVE_DTRACE
|
||||||
|
@ -1371,6 +1372,19 @@ static bool tokudb_show_engine_status(THD * thd, stat_print_fn * stat_print) {
|
||||||
snprintf(buf, bufsiz, "%.6f\n", t);
|
snprintf(buf, bufsiz, "%.6f\n", t);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case PARCOUNT:
|
||||||
|
{
|
||||||
|
uint64_t v = read_partitioned_counter(mystat[row].value.parcount);
|
||||||
|
snprintf(buf, bufsiz, "%" PRIu64 "\n", v);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
#if 0
|
||||||
|
case MAXCOUNT:
|
||||||
|
{
|
||||||
|
uint64_t v = read_max_partitioned_counter(mystat[row].value.maxcount);
|
||||||
|
n += snprintf(buff + n, bufsiz - n, "%" PRIu64 "\n", v);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
default:
|
default:
|
||||||
snprintf(buf, bufsiz, "UNKNOWN STATUS TYPE: %d\n", mystat[row].type);
|
snprintf(buf, bufsiz, "UNKNOWN STATUS TYPE: %d\n", mystat[row].type);
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue