summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dist/stat_data.py2
-rw-r--r--src/conn/conn_log.c1
-rw-r--r--src/include/stat.h2
-rw-r--r--src/include/wiredtiger.in108
-rw-r--r--src/log/log.c1
-rw-r--r--src/support/stat.c6
6 files changed, 68 insertions, 52 deletions
diff --git a/dist/stat_data.py b/dist/stat_data.py
index 5a42f2ff318..3b866be3a41 100644
--- a/dist/stat_data.py
+++ b/dist/stat_data.py
@@ -221,11 +221,13 @@ connection_stats = [
LogStat('log_prealloc_max', 'number of pre-allocated log files to create'),
LogStat('log_prealloc_used', 'pre-allocated log files used'),
LogStat('log_reads', 'log read operations'),
+ LogStat('log_release_write_lsn', 'log release advances write LSN'),
LogStat('log_scan_records', 'records processed by log scan'),
LogStat('log_scan_rereads', 'log scan records requiring two reads'),
LogStat('log_scans', 'log scan operations'),
LogStat('log_sync', 'log sync operations'),
LogStat('log_writes', 'log write operations'),
+ LogStat('log_write_lsn', 'log server thread advances write LSN'),
LogStat('log_slot_consolidated', 'logging bytes consolidated'),
LogStat('log_slot_closes', 'consolidated slot closures'),
diff --git a/src/conn/conn_log.c b/src/conn/conn_log.c
index 2af0d6fa373..d272cf0db7d 100644
--- a/src/conn/conn_log.c
+++ b/src/conn/conn_log.c
@@ -395,6 +395,7 @@ __log_wrlsn_server(void *arg)
*/
log->write_lsn = slot->slot_end_lsn;
WT_ERR(__wt_cond_signal(session, log->log_write_cond));
+ WT_STAT_FAST_CONN_INCR(session, log_write_lsn);
/*
* Signal the close thread if needed.
*/
diff --git a/src/include/stat.h b/src/include/stat.h
index 3f684478358..b2b23ec803d 100644
--- a/src/include/stat.h
+++ b/src/include/stat.h
@@ -215,6 +215,7 @@ struct __wt_connection_stats {
WT_STATS log_prealloc_max;
WT_STATS log_prealloc_used;
WT_STATS log_reads;
+ WT_STATS log_release_write_lsn;
WT_STATS log_scan_records;
WT_STATS log_scan_rereads;
WT_STATS log_scans;
@@ -227,6 +228,7 @@ struct __wt_connection_stats {
WT_STATS log_slot_toosmall;
WT_STATS log_slot_transitions;
WT_STATS log_sync;
+ WT_STATS log_write_lsn;
WT_STATS log_writes;
WT_STATS lsm_checkpoint_throttle;
WT_STATS lsm_merge_throttle;
diff --git a/src/include/wiredtiger.in b/src/include/wiredtiger.in
index d0d0f9eec77..f446403520f 100644
--- a/src/include/wiredtiger.in
+++ b/src/include/wiredtiger.in
@@ -3336,110 +3336,114 @@ extern int wiredtiger_extension_terminate(WT_CONNECTION *connection);
#define WT_STAT_CONN_LOG_PREALLOC_USED 1081
/*! log: log read operations */
#define WT_STAT_CONN_LOG_READS 1082
+/*! log: log release advances write LSN */
+#define WT_STAT_CONN_LOG_RELEASE_WRITE_LSN 1083
/*! log: records processed by log scan */
-#define WT_STAT_CONN_LOG_SCAN_RECORDS 1083
+#define WT_STAT_CONN_LOG_SCAN_RECORDS 1084
/*! log: log scan records requiring two reads */
-#define WT_STAT_CONN_LOG_SCAN_REREADS 1084
+#define WT_STAT_CONN_LOG_SCAN_REREADS 1085
/*! log: log scan operations */
-#define WT_STAT_CONN_LOG_SCANS 1085
+#define WT_STAT_CONN_LOG_SCANS 1086
/*! log: consolidated slot closures */
-#define WT_STAT_CONN_LOG_SLOT_CLOSES 1086
+#define WT_STAT_CONN_LOG_SLOT_CLOSES 1087
/*! log: logging bytes consolidated */
-#define WT_STAT_CONN_LOG_SLOT_CONSOLIDATED 1087
+#define WT_STAT_CONN_LOG_SLOT_CONSOLIDATED 1088
/*! log: consolidated slot joins */
-#define WT_STAT_CONN_LOG_SLOT_JOINS 1088
+#define WT_STAT_CONN_LOG_SLOT_JOINS 1089
/*! log: consolidated slot join races */
-#define WT_STAT_CONN_LOG_SLOT_RACES 1089
+#define WT_STAT_CONN_LOG_SLOT_RACES 1090
/*! log: slots selected for switching that were unavailable */
-#define WT_STAT_CONN_LOG_SLOT_SWITCH_FAILS 1090
+#define WT_STAT_CONN_LOG_SLOT_SWITCH_FAILS 1091
/*! log: record size exceeded maximum */
-#define WT_STAT_CONN_LOG_SLOT_TOOBIG 1091
+#define WT_STAT_CONN_LOG_SLOT_TOOBIG 1092
/*! log: failed to find a slot large enough for record */
-#define WT_STAT_CONN_LOG_SLOT_TOOSMALL 1092
+#define WT_STAT_CONN_LOG_SLOT_TOOSMALL 1093
/*! log: consolidated slot join transitions */
-#define WT_STAT_CONN_LOG_SLOT_TRANSITIONS 1093
+#define WT_STAT_CONN_LOG_SLOT_TRANSITIONS 1094
/*! log: log sync operations */
-#define WT_STAT_CONN_LOG_SYNC 1094
+#define WT_STAT_CONN_LOG_SYNC 1095
+/*! log: log server thread advances write LSN */
+#define WT_STAT_CONN_LOG_WRITE_LSN 1096
/*! log: log write operations */
-#define WT_STAT_CONN_LOG_WRITES 1095
+#define WT_STAT_CONN_LOG_WRITES 1097
/*! LSM: sleep for LSM checkpoint throttle */
-#define WT_STAT_CONN_LSM_CHECKPOINT_THROTTLE 1096
+#define WT_STAT_CONN_LSM_CHECKPOINT_THROTTLE 1098
/*! LSM: sleep for LSM merge throttle */
-#define WT_STAT_CONN_LSM_MERGE_THROTTLE 1097
+#define WT_STAT_CONN_LSM_MERGE_THROTTLE 1099
/*! LSM: rows merged in an LSM tree */
-#define WT_STAT_CONN_LSM_ROWS_MERGED 1098
+#define WT_STAT_CONN_LSM_ROWS_MERGED 1100
/*! LSM: application work units currently queued */
-#define WT_STAT_CONN_LSM_WORK_QUEUE_APP 1099
+#define WT_STAT_CONN_LSM_WORK_QUEUE_APP 1101
/*! LSM: merge work units currently queued */
-#define WT_STAT_CONN_LSM_WORK_QUEUE_MANAGER 1100
+#define WT_STAT_CONN_LSM_WORK_QUEUE_MANAGER 1102
/*! LSM: tree queue hit maximum */
-#define WT_STAT_CONN_LSM_WORK_QUEUE_MAX 1101
+#define WT_STAT_CONN_LSM_WORK_QUEUE_MAX 1103
/*! LSM: switch work units currently queued */
-#define WT_STAT_CONN_LSM_WORK_QUEUE_SWITCH 1102
+#define WT_STAT_CONN_LSM_WORK_QUEUE_SWITCH 1104
/*! LSM: tree maintenance operations scheduled */
-#define WT_STAT_CONN_LSM_WORK_UNITS_CREATED 1103
+#define WT_STAT_CONN_LSM_WORK_UNITS_CREATED 1105
/*! LSM: tree maintenance operations discarded */
-#define WT_STAT_CONN_LSM_WORK_UNITS_DISCARDED 1104
+#define WT_STAT_CONN_LSM_WORK_UNITS_DISCARDED 1106
/*! LSM: tree maintenance operations executed */
-#define WT_STAT_CONN_LSM_WORK_UNITS_DONE 1105
+#define WT_STAT_CONN_LSM_WORK_UNITS_DONE 1107
/*! connection: memory allocations */
-#define WT_STAT_CONN_MEMORY_ALLOCATION 1106
+#define WT_STAT_CONN_MEMORY_ALLOCATION 1108
/*! connection: memory frees */
-#define WT_STAT_CONN_MEMORY_FREE 1107
+#define WT_STAT_CONN_MEMORY_FREE 1109
/*! connection: memory re-allocations */
-#define WT_STAT_CONN_MEMORY_GROW 1108
+#define WT_STAT_CONN_MEMORY_GROW 1110
/*! thread-yield: page acquire busy blocked */
-#define WT_STAT_CONN_PAGE_BUSY_BLOCKED 1109
+#define WT_STAT_CONN_PAGE_BUSY_BLOCKED 1111
/*! thread-yield: page acquire eviction blocked */
-#define WT_STAT_CONN_PAGE_FORCIBLE_EVICT_BLOCKED 1110
+#define WT_STAT_CONN_PAGE_FORCIBLE_EVICT_BLOCKED 1112
/*! thread-yield: page acquire locked blocked */
-#define WT_STAT_CONN_PAGE_LOCKED_BLOCKED 1111
+#define WT_STAT_CONN_PAGE_LOCKED_BLOCKED 1113
/*! thread-yield: page acquire read blocked */
-#define WT_STAT_CONN_PAGE_READ_BLOCKED 1112
+#define WT_STAT_CONN_PAGE_READ_BLOCKED 1114
/*! thread-yield: page acquire time sleeping (usecs) */
-#define WT_STAT_CONN_PAGE_SLEEP 1113
+#define WT_STAT_CONN_PAGE_SLEEP 1115
/*! connection: total read I/Os */
-#define WT_STAT_CONN_READ_IO 1114
+#define WT_STAT_CONN_READ_IO 1116
/*! reconciliation: page reconciliation calls */
-#define WT_STAT_CONN_REC_PAGES 1115
+#define WT_STAT_CONN_REC_PAGES 1117
/*! reconciliation: page reconciliation calls for eviction */
-#define WT_STAT_CONN_REC_PAGES_EVICTION 1116
+#define WT_STAT_CONN_REC_PAGES_EVICTION 1118
/*! reconciliation: split bytes currently awaiting free */
-#define WT_STAT_CONN_REC_SPLIT_STASHED_BYTES 1117
+#define WT_STAT_CONN_REC_SPLIT_STASHED_BYTES 1119
/*! reconciliation: split objects currently awaiting free */
-#define WT_STAT_CONN_REC_SPLIT_STASHED_OBJECTS 1118
+#define WT_STAT_CONN_REC_SPLIT_STASHED_OBJECTS 1120
/*! connection: pthread mutex shared lock read-lock calls */
-#define WT_STAT_CONN_RWLOCK_READ 1119
+#define WT_STAT_CONN_RWLOCK_READ 1121
/*! connection: pthread mutex shared lock write-lock calls */
-#define WT_STAT_CONN_RWLOCK_WRITE 1120
+#define WT_STAT_CONN_RWLOCK_WRITE 1122
/*! session: open cursor count */
-#define WT_STAT_CONN_SESSION_CURSOR_OPEN 1121
+#define WT_STAT_CONN_SESSION_CURSOR_OPEN 1123
/*! session: open session count */
-#define WT_STAT_CONN_SESSION_OPEN 1122
+#define WT_STAT_CONN_SESSION_OPEN 1124
/*! transaction: transaction begins */
-#define WT_STAT_CONN_TXN_BEGIN 1123
+#define WT_STAT_CONN_TXN_BEGIN 1125
/*! transaction: transaction checkpoints */
-#define WT_STAT_CONN_TXN_CHECKPOINT 1124
+#define WT_STAT_CONN_TXN_CHECKPOINT 1126
/*! transaction: transaction checkpoint currently running */
-#define WT_STAT_CONN_TXN_CHECKPOINT_RUNNING 1125
+#define WT_STAT_CONN_TXN_CHECKPOINT_RUNNING 1127
/*! transaction: transaction checkpoint max time (msecs) */
-#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_MAX 1126
+#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_MAX 1128
/*! transaction: transaction checkpoint min time (msecs) */
-#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_MIN 1127
+#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_MIN 1129
/*! transaction: transaction checkpoint most recent time (msecs) */
-#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_RECENT 1128
+#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_RECENT 1130
/*! transaction: transaction checkpoint total time (msecs) */
-#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_TOTAL 1129
+#define WT_STAT_CONN_TXN_CHECKPOINT_TIME_TOTAL 1131
/*! transaction: transactions committed */
-#define WT_STAT_CONN_TXN_COMMIT 1130
+#define WT_STAT_CONN_TXN_COMMIT 1132
/*! transaction: transaction failures due to cache overflow */
-#define WT_STAT_CONN_TXN_FAIL_CACHE 1131
+#define WT_STAT_CONN_TXN_FAIL_CACHE 1133
/*! transaction: transaction range of IDs currently pinned */
-#define WT_STAT_CONN_TXN_PINNED_RANGE 1132
+#define WT_STAT_CONN_TXN_PINNED_RANGE 1134
/*! transaction: transactions rolled back */
-#define WT_STAT_CONN_TXN_ROLLBACK 1133
+#define WT_STAT_CONN_TXN_ROLLBACK 1135
/*! connection: total write I/Os */
-#define WT_STAT_CONN_WRITE_IO 1134
+#define WT_STAT_CONN_WRITE_IO 1136
/*!
* @}
diff --git a/src/log/log.c b/src/log/log.c
index 33aea0f9cb3..5f51efe6ef1 100644
--- a/src/log/log.c
+++ b/src/log/log.c
@@ -944,6 +944,7 @@ __log_release(WT_SESSION_IMPL *session, WT_LOGSLOT *slot, int *freep)
* Wait for earlier groups to finish, otherwise there could
* be holes in the log file.
*/
+ WT_STAT_FAST_CONN_INCR(session, log_release_write_lsn);
while (LOG_CMP(&log->write_lsn, &slot->slot_release_lsn) != 0) {
if (++yield_count < 1000)
__wt_yield();
diff --git a/src/support/stat.c b/src/support/stat.c
index 0926636a532..b24998f503f 100644
--- a/src/support/stat.c
+++ b/src/support/stat.c
@@ -447,9 +447,13 @@ __wt_stat_init_connection_stats(WT_CONNECTION_STATS *stats)
"log: log records not compressed";
stats->log_compress_small.desc =
"log: log records too small to compress";
+ stats->log_release_write_lsn.desc =
+ "log: log release advances write LSN";
stats->log_scans.desc = "log: log scan operations";
stats->log_scan_rereads.desc =
"log: log scan records requiring two reads";
+ stats->log_write_lsn.desc =
+ "log: log server thread advances write LSN";
stats->log_sync.desc = "log: log sync operations";
stats->log_writes.desc = "log: log write operations";
stats->log_slot_consolidated.desc = "log: logging bytes consolidated";
@@ -613,8 +617,10 @@ __wt_stat_refresh_connection_stats(void *stats_arg)
stats->log_compress_writes.v = 0;
stats->log_compress_write_fails.v = 0;
stats->log_compress_small.v = 0;
+ stats->log_release_write_lsn.v = 0;
stats->log_scans.v = 0;
stats->log_scan_rereads.v = 0;
+ stats->log_write_lsn.v = 0;
stats->log_sync.v = 0;
stats->log_writes.v = 0;
stats->log_slot_consolidated.v = 0;