mirror of
https://github.com/MariaDB/server.git
synced 2025-02-02 03:51:50 +01:00
[t:3034] Update engine status for new functionality.
git-svn-id: file:///svn/toku/tokudb@26444 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
63d1c05f30
commit
37f0a697b3
13 changed files with 179 additions and 26 deletions
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -479,7 +479,8 @@ int main (int argc __attribute__((__unused__)), char *const argv[] __attribute__
|
|||
printf(" u_int64_t txn_commit; /* txn commit operations */ \n");
|
||||
printf(" u_int64_t txn_abort; /* txn abort operations */ \n");
|
||||
printf(" u_int64_t txn_close; /* txn completions (should equal commit+abort) */ \n");
|
||||
printf(" u_int64_t txn_oldest_live; /* oldest extant txn */ \n");
|
||||
printf(" u_int64_t txn_oldest_live; /* oldest extant txn txnid */ \n");
|
||||
printf(" char txn_oldest_live_begin; /* oldest extant txn start time */ \n");
|
||||
printf(" u_int64_t next_lsn; /* lsn that will be assigned to next log entry */ \n");
|
||||
printf(" u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */ \n");
|
||||
printf(" u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */ \n");
|
||||
|
@ -513,6 +514,10 @@ int main (int argc __attribute__((__unused__)), char *const argv[] __attribute__
|
|||
printf(" u_int64_t range_write_locks; /* total range write locks taken */ \n");
|
||||
printf(" u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */ \n");
|
||||
printf(" u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */ \n");
|
||||
printf(" u_int64_t directory_read_locks; /* total directory read locks taken */ \n");
|
||||
printf(" u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */ \n");
|
||||
printf(" u_int64_t directory_write_locks; /* total directory write locks taken */ \n");
|
||||
printf(" u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */ \n");
|
||||
printf(" u_int64_t inserts; /* ydb row insert operations */ \n");
|
||||
printf(" u_int64_t inserts_fail; /* ydb row insert operations that failed */ \n");
|
||||
printf(" u_int64_t deletes; /* ydb row delete operations */ \n");
|
||||
|
@ -527,6 +532,10 @@ int main (int argc __attribute__((__unused__)), char *const argv[] __attribute__
|
|||
printf(" u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */ \n");
|
||||
printf(" u_int64_t point_queries; /* ydb point queries */ \n");
|
||||
printf(" u_int64_t sequential_queries; /* ydb sequential queries */ \n");
|
||||
printf(" u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */ \n");
|
||||
printf(" u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */ \n");
|
||||
printf(" u_int64_t le_max_memsize; /* max memsize of any packed le */ \n");
|
||||
printf(" u_int64_t le_expanded; /* number of times ule used expanded memory */ \n");
|
||||
printf(" u_int64_t fsync_count; /* number of times fsync performed */ \n");
|
||||
printf(" u_int64_t fsync_time; /* total time required to fsync */ \n");
|
||||
printf(" u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */ \n");
|
||||
|
@ -539,7 +548,8 @@ int main (int argc __attribute__((__unused__)), char *const argv[] __attribute__
|
|||
printf(" u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */ \n");
|
||||
printf(" u_int64_t loader_create; /* number of loaders created */ \n");
|
||||
printf(" u_int64_t loader_create_fail; /* number of failed loader creations */ \n");
|
||||
printf(" u_int64_t loader_put; /* number of loader puts */ \n");
|
||||
printf(" u_int64_t loader_put; /* number of loader puts (success) */ \n");
|
||||
printf(" u_int64_t loader_put_fail; /* number of loader puts that failed */ \n");
|
||||
printf(" u_int64_t loader_close; /* number of loaders closed (succeed or fail) */ \n");
|
||||
printf(" u_int64_t loader_close_fail; /* number of loaders closed with error return */ \n");
|
||||
printf(" u_int64_t loader_abort; /* number of loaders aborted */ \n");
|
||||
|
|
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
14
include/db.h
14
include/db.h
|
@ -93,7 +93,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t txn_commit; /* txn commit operations */
|
||||
u_int64_t txn_abort; /* txn abort operations */
|
||||
u_int64_t txn_close; /* txn completions (should equal commit+abort) */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn */
|
||||
u_int64_t txn_oldest_live; /* oldest extant txn txnid */
|
||||
char txn_oldest_live_begin; /* oldest extant txn start time */
|
||||
u_int64_t next_lsn; /* lsn that will be assigned to next log entry */
|
||||
u_int64_t cachetable_lock_taken; /* how many times has cachetable lock been taken */
|
||||
u_int64_t cachetable_lock_released;/* how many times has cachetable lock been released */
|
||||
|
@ -127,6 +128,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t range_write_locks; /* total range write locks taken */
|
||||
u_int64_t range_write_locks_fail; /* total range write locks unable to be taken */
|
||||
u_int64_t range_out_of_write_locks; /* total times range write locks exhausted */
|
||||
u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
u_int64_t inserts; /* ydb row insert operations */
|
||||
u_int64_t inserts_fail; /* ydb row insert operations that failed */
|
||||
u_int64_t deletes; /* ydb row delete operations */
|
||||
|
@ -141,6 +146,10 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t multi_updates_fail; /* ydb row update operations that failed, dictionary count */
|
||||
u_int64_t point_queries; /* ydb point queries */
|
||||
u_int64_t sequential_queries; /* ydb sequential queries */
|
||||
u_int64_t le_max_committed_xr; /* max committed transaction records in any packed le */
|
||||
u_int64_t le_max_provisional_xr; /* max provisional transaction records in any packed le */
|
||||
u_int64_t le_max_memsize; /* max memsize of any packed le */
|
||||
u_int64_t le_expanded; /* number of times ule used expanded memory */
|
||||
u_int64_t fsync_count; /* number of times fsync performed */
|
||||
u_int64_t fsync_time; /* total time required to fsync */
|
||||
u_int64_t logger_ilock_ctr; /* how many times has logger input lock been taken or released */
|
||||
|
@ -153,7 +162,8 @@ typedef struct __toku_engine_status {
|
|||
u_int64_t enospc_state; /* state of ydb-level ENOSPC prevention (0 = green, 1 = yellow, 2 = red) */
|
||||
u_int64_t loader_create; /* number of loaders created */
|
||||
u_int64_t loader_create_fail; /* number of failed loader creations */
|
||||
u_int64_t loader_put; /* number of loader puts */
|
||||
u_int64_t loader_put; /* number of loader puts (success) */
|
||||
u_int64_t loader_put_fail; /* number of loader puts that failed */
|
||||
u_int64_t loader_close; /* number of loaders closed (succeed or fail) */
|
||||
u_int64_t loader_close_fail; /* number of loaders closed with error return */
|
||||
u_int64_t loader_abort; /* number of loaders aborted */
|
||||
|
|
|
@ -374,6 +374,17 @@ typedef struct brt_upgrade_status {
|
|||
|
||||
void toku_brt_get_upgrade_status(BRT_UPGRADE_STATUS);
|
||||
|
||||
|
||||
typedef struct le_status {
|
||||
u_int64_t max_committed_xr;
|
||||
u_int64_t max_provisional_xr;
|
||||
u_int64_t expanded;
|
||||
u_int64_t max_memsize;
|
||||
} LE_STATUS_S, *LE_STATUS;
|
||||
|
||||
void toku_le_get_status(LE_STATUS);
|
||||
|
||||
|
||||
C_END
|
||||
|
||||
#endif
|
||||
|
|
24
newbrt/ule.c
24
newbrt/ule.c
|
@ -34,6 +34,8 @@
|
|||
|
||||
#define ULE_DEBUG 0
|
||||
|
||||
static LE_STATUS_S status;
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// Accessor functions used by outside world (e.g. indexer)
|
||||
|
@ -51,8 +53,10 @@ void toku_ule_free(ULEHANDLE ule_p) {
|
|||
toku_free(ule_p);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void
|
||||
toku_le_get_status(LE_STATUS s) {
|
||||
*s = status;
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -589,6 +593,18 @@ uxr_unpack_data(UXR uxr, uint8_t *p) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
// executed too often to be worth making threadsafe
|
||||
static inline void
|
||||
update_le_status(ULE ule, size_t memsize, LE_STATUS s) {
|
||||
if (ule->num_cuxrs > s->max_committed_xr)
|
||||
s->max_committed_xr = ule->num_cuxrs;
|
||||
if (ule->num_puxrs > s->max_provisional_xr)
|
||||
s->max_provisional_xr = ule->num_puxrs;
|
||||
if (ule->num_cuxrs > MAX_TRANSACTION_RECORDS)
|
||||
s->expanded++;
|
||||
if (memsize > s->max_memsize)
|
||||
s->max_memsize = memsize;
|
||||
}
|
||||
|
||||
// Purpose is to return a newly allocated leaf entry in packed format, or
|
||||
// return null if leaf entry should be destroyed (if no transaction records
|
||||
|
@ -607,6 +623,7 @@ le_pack(ULE ule, // data to be packed into new leafen
|
|||
invariant(ule->num_cuxrs > 0);
|
||||
invariant(ule->uxrs[0].xid == TXNID_NONE);
|
||||
int rval;
|
||||
size_t memsize = 0;
|
||||
{
|
||||
// The unpacked leafentry may contain no inserts anywhere on its stack.
|
||||
// If so, then there IS no leafentry to pack, we should return NULL
|
||||
|
@ -624,7 +641,7 @@ le_pack(ULE ule, // data to be packed into new leafen
|
|||
goto cleanup;
|
||||
}
|
||||
found_insert:;
|
||||
size_t memsize = le_memsize_from_ule(ule);
|
||||
memsize = le_memsize_from_ule(ule);
|
||||
LEAFENTRY new_leafentry = le_malloc(omt, mp, memsize, maybe_free);
|
||||
if (new_leafentry==NULL) {
|
||||
rval = ENOMEM;
|
||||
|
@ -754,6 +771,7 @@ found_insert:;
|
|||
*new_leafentry_disksize = memsize;
|
||||
rval = 0;
|
||||
cleanup:
|
||||
update_le_status(ule, memsize, &status);
|
||||
return rval;
|
||||
}
|
||||
|
||||
|
|
14
src/loader.c
14
src/loader.c
|
@ -280,8 +280,6 @@ int toku_loader_set_error_callback(DB_LOADER *loader,
|
|||
|
||||
int toku_loader_put(DB_LOADER *loader, DBT *key, DBT *val)
|
||||
{
|
||||
status.put++; // not worth the extra cycles to keep threadsafe
|
||||
|
||||
int r = 0;
|
||||
int i = 0;
|
||||
// err_i is unused now( always 0). How would we know which dictionary
|
||||
|
@ -290,7 +288,8 @@ int toku_loader_put(DB_LOADER *loader, DBT *key, DBT *val)
|
|||
|
||||
// skip put if error already found
|
||||
if ( loader->i->err_errno != 0 ) {
|
||||
return -1;
|
||||
r = -1;
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
if ( loader->i->loader_flags & LOADER_USE_PUTS ) {
|
||||
|
@ -326,9 +325,14 @@ int toku_loader_put(DB_LOADER *loader, DBT *key, DBT *val)
|
|||
|
||||
// deliberately return content free value
|
||||
// - must call error_callback to get error info
|
||||
return -1;
|
||||
r = -1;
|
||||
}
|
||||
return 0;
|
||||
cleanup:
|
||||
if (r==0)
|
||||
status.put++; // executed too often to be worth making threadsafe
|
||||
else
|
||||
status.put_fail++;
|
||||
return r;
|
||||
}
|
||||
|
||||
int toku_loader_close(DB_LOADER *loader)
|
||||
|
|
|
@ -111,7 +111,8 @@ int toku_loader_cleanup_temp_files(DB_ENV *env);
|
|||
typedef struct loader_status {
|
||||
uint64_t create; // number of loaders succefully created
|
||||
uint64_t create_fail; // number of calls to toku_loader_create_loader() that failed
|
||||
uint64_t put; // number of calls to toku_loader_put()
|
||||
uint64_t put; // number of calls to toku_loader_put() that succeeded
|
||||
uint64_t put_fail; // number of calls to toku_loader_put() that failed
|
||||
uint64_t close; // number of calls to toku_loader_close()
|
||||
uint64_t close_fail; // number of calls to toku_loader_close() that failed
|
||||
uint64_t abort; // number of calls to toku_loader_abort()
|
||||
|
|
41
src/ydb.c
41
src/ydb.c
|
@ -62,6 +62,12 @@ static u_int64_t num_multi_updates;
|
|||
static u_int64_t num_multi_updates_fail;
|
||||
static u_int64_t num_point_queries;
|
||||
static u_int64_t num_sequential_queries;
|
||||
|
||||
static u_int64_t directory_read_locks; /* total directory read locks taken */
|
||||
static u_int64_t directory_read_locks_fail; /* total directory read locks unable to be taken */
|
||||
static u_int64_t directory_write_locks; /* total directory write locks taken */
|
||||
static u_int64_t directory_write_locks_fail; /* total directory write locks unable to be taken */
|
||||
|
||||
static u_int64_t logsuppress; // number of times logs are suppressed for empty table (2440)
|
||||
static u_int64_t logsuppressfail; // number of times unable to suppress logs for empty table (2440)
|
||||
static time_t startuptime; // timestamp of system startup
|
||||
|
@ -85,6 +91,10 @@ init_status_info(void) {
|
|||
num_multi_updates_fail = 0;
|
||||
num_point_queries = 0;
|
||||
num_sequential_queries = 0;
|
||||
directory_read_locks = 0;
|
||||
directory_read_locks_fail = 0;
|
||||
directory_write_locks = 0;
|
||||
directory_write_locks_fail = 0;
|
||||
logsuppress = 0;
|
||||
logsuppressfail = 0;
|
||||
startuptime = time(NULL);
|
||||
|
@ -1754,7 +1764,14 @@ env_get_engine_status(DB_ENV * env, ENGINE_STATUS * engstat, char * env_panic_st
|
|||
engstat->total_time_ydb_lock_held = schedstat.total_time_ydb_lock_held;/* total time client threads held the ydb lock */
|
||||
engstat->max_time_ydb_lock_held = schedstat.max_time_ydb_lock_held; /* max time client threads held the ydb lock */
|
||||
}
|
||||
|
||||
{
|
||||
LE_STATUS_S lestat; // Rice's vampire
|
||||
toku_le_get_status(&lestat);
|
||||
engstat->le_max_committed_xr = lestat.max_committed_xr;
|
||||
engstat->le_max_provisional_xr = lestat.max_provisional_xr;
|
||||
engstat->le_expanded = lestat.expanded;
|
||||
engstat->le_max_memsize = lestat.max_memsize;
|
||||
}
|
||||
engstat->checkpoint_period = toku_get_checkpoint_period_unlocked(env->i->cachetable); // do not take any locks (not even minicron lock)
|
||||
{
|
||||
CHECKPOINT_STATUS_S cpstat;
|
||||
|
@ -1846,6 +1863,10 @@ env_get_engine_status(DB_ENV * env, ENGINE_STATUS * engstat, char * env_panic_st
|
|||
engstat->multi_updates_fail = num_multi_updates_fail;
|
||||
engstat->point_queries = num_point_queries;
|
||||
engstat->sequential_queries = num_sequential_queries;
|
||||
engstat->directory_read_locks = directory_read_locks;
|
||||
engstat->directory_read_locks_fail = directory_read_locks_fail;
|
||||
engstat->directory_write_locks = directory_write_locks;
|
||||
engstat->directory_write_locks_fail = directory_write_locks_fail;
|
||||
}
|
||||
{
|
||||
u_int64_t fsync_count, fsync_time;
|
||||
|
@ -1881,6 +1902,7 @@ env_get_engine_status(DB_ENV * env, ENGINE_STATUS * engstat, char * env_panic_st
|
|||
engstat->loader_create = loader_stat.create;
|
||||
engstat->loader_create_fail = loader_stat.create_fail;
|
||||
engstat->loader_put = loader_stat.put;
|
||||
engstat->loader_put_fail = loader_stat.put_fail;
|
||||
engstat->loader_close = loader_stat.close;
|
||||
engstat->loader_close_fail = loader_stat.close_fail;
|
||||
engstat->loader_abort = loader_stat.abort;
|
||||
|
@ -1974,6 +1996,10 @@ env_get_engine_status_text(DB_ENV * env, char * buff, int bufsiz) {
|
|||
n += snprintf(buff + n, bufsiz - n, "time_ydb_lock_held_unavailable %"PRIu64"\n", engstat.time_ydb_lock_held_unavailable);
|
||||
n += snprintf(buff + n, bufsiz - n, "max_time_ydb_lock_held %"PRIu64"\n", engstat.max_time_ydb_lock_held);
|
||||
n += snprintf(buff + n, bufsiz - n, "total_time_ydb_lock_held %"PRIu64"\n", engstat.total_time_ydb_lock_held);
|
||||
n += snprintf(buff + n, bufsiz - n, "le_max_committed_xr %"PRIu64"\n", engstat.le_max_committed_xr);
|
||||
n += snprintf(buff + n, bufsiz - n, "le_max_provisional_xr %"PRIu64"\n", engstat.le_max_provisional_xr);
|
||||
n += snprintf(buff + n, bufsiz - n, "le_expanded %"PRIu64"\n", engstat.le_expanded);
|
||||
n += snprintf(buff + n, bufsiz - n, "le_max_memsize %"PRIu64"\n", engstat.le_max_memsize);
|
||||
n += snprintf(buff + n, bufsiz - n, "checkpoint_period %d \n", engstat.checkpoint_period);
|
||||
n += snprintf(buff + n, bufsiz - n, "checkpoint_footprint %d \n", engstat.checkpoint_footprint);
|
||||
n += snprintf(buff + n, bufsiz - n, "checkpoint_time_begin %s \n", engstat.checkpoint_time_begin);
|
||||
|
@ -2033,6 +2059,10 @@ env_get_engine_status_text(DB_ENV * env, char * buff, int bufsiz) {
|
|||
n += snprintf(buff + n, bufsiz - n, "multi_updates_fail %"PRIu64"\n", engstat.multi_updates_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "point_queries %"PRIu64"\n", engstat.point_queries);
|
||||
n += snprintf(buff + n, bufsiz - n, "sequential_queries %"PRIu64"\n", engstat.sequential_queries);
|
||||
n += snprintf(buff + n, bufsiz - n, "directory_read_locks %"PRIu64"\n", engstat.directory_read_locks);
|
||||
n += snprintf(buff + n, bufsiz - n, "directory_read_locks_fail %"PRIu64"\n", engstat.directory_read_locks_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "directory_write_locks %"PRIu64"\n", engstat.directory_write_locks);
|
||||
n += snprintf(buff + n, bufsiz - n, "directory_write_locks_fail %"PRIu64"\n", engstat.directory_write_locks_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "fsync_count %"PRIu64"\n", engstat.fsync_count);
|
||||
n += snprintf(buff + n, bufsiz - n, "fsync_time %"PRIu64"\n", engstat.fsync_time);
|
||||
n += snprintf(buff + n, bufsiz - n, "logger ilock count %"PRIu64"\n", engstat.logger_ilock_ctr);
|
||||
|
@ -2048,6 +2078,7 @@ env_get_engine_status_text(DB_ENV * env, char * buff, int bufsiz) {
|
|||
n += snprintf(buff + n, bufsiz - n, "loader_create %"PRIu64"\n", engstat.loader_create);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_create_fail %"PRIu64"\n", engstat.loader_create_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_put %"PRIu64"\n", engstat.loader_put);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_put_fail %"PRIu64"\n", engstat.loader_put_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_close %"PRIu64"\n", engstat.loader_close);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_close_fail %"PRIu64"\n", engstat.loader_close_fail);
|
||||
n += snprintf(buff + n, bufsiz - n, "loader_abort %"PRIu64"\n", engstat.loader_abort);
|
||||
|
@ -3163,6 +3194,10 @@ toku_grab_read_lock_on_directory (DB* db, DB_TXN * txn) {
|
|||
&key_in_directory
|
||||
);
|
||||
int r = grab_range_lock(&request);
|
||||
if (r == 0)
|
||||
directory_read_locks++;
|
||||
else
|
||||
directory_read_locks_fail++;
|
||||
return r;
|
||||
}
|
||||
|
||||
|
@ -5257,6 +5292,10 @@ static int toku_db_pre_acquire_fileops_lock(DB *db, DB_TXN *txn) {
|
|||
&key_in_directory
|
||||
);
|
||||
int r = grab_range_lock(&request);
|
||||
if (r == 0)
|
||||
directory_write_locks++;
|
||||
else
|
||||
directory_write_locks_fail++;
|
||||
return r;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue