summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChenhao Qu <chenhao.qu@mongodb.com>2021-06-16 05:46:29 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-06-16 06:08:30 +0000
commit3252585306a8f91f6c9673e011cb78658e2e0e7c (patch)
treed61f6604dcbd214a5b9ceb27f51f39b3f2ebfe6d
parent5571671c307bcb4e0c42781e578aea850d24003f (diff)
downloadmongo-3252585306a8f91f6c9673e011cb78658e2e0e7c.tar.gz
Import wiredtiger: 15a5f48c534e7f61e9eb81c9509f5d2d31c72d63 from branch mongodb-5.0
ref: 5db6a488f5..15a5f48c53 for: 5.0.0-rc2 WT-7685 Fix invalid values and units for latencies in workgen
-rw-r--r--src/third_party/wiredtiger/bench/workgen/workgen.cxx34
-rw-r--r--src/third_party/wiredtiger/import.data2
2 files changed, 21 insertions, 15 deletions
diff --git a/src/third_party/wiredtiger/bench/workgen/workgen.cxx b/src/third_party/wiredtiger/bench/workgen/workgen.cxx
index cc2c93d3f6b..9d853136c1b 100644
--- a/src/third_party/wiredtiger/bench/workgen/workgen.cxx
+++ b/src/third_party/wiredtiger/bench/workgen/workgen.cxx
@@ -165,7 +165,10 @@ int WorkloadRunner::check_timing(const char *name, uint64_t last_interval) {
} else {
str = "WARNING";
}
- std::cerr << str << ": Cycling idle table failed because " << name << " took " << last_interval << " seconds which is longer than configured acceptable maximum of " << options->max_idle_table_cycle << std::endl;
+ std::cerr << str << ": Cycling idle table failed because " << name << " took "
+ << last_interval << " s which is longer than configured acceptable maximum of "
+ << options->max_idle_table_cycle << " s. Diff is "
+ << (last_interval - options->max_idle_table_cycle) << " s." << std::endl;
}
return (msg_err);
}
@@ -415,7 +418,7 @@ int Monitor::run() {
char time_buf[64], version[100];
Stats prev_totals;
WorkloadOptions *options = &_wrunner._workload->options;
- uint64_t latency_max = (uint64_t)options->max_latency;
+ uint64_t latency_max = (uint64_t)options->max_latency * THOUSAND;
size_t buf_size;
bool first;
@@ -548,18 +551,21 @@ int Monitor::run() {
}
uint64_t read_max = interval.read.max_latency;
- uint64_t insert_max = interval.read.max_latency;
- uint64_t update_max = interval.read.max_latency;
-
- if (latency_max != 0 &&
- (read_max > latency_max || insert_max > latency_max ||
- update_max > latency_max)) {
- std::cerr << "WARNING: max latency exceeded:"
- << " threshold " << latency_max
- << " read max " << read_max
- << " insert max " << insert_max
- << " update max " << update_max << std::endl;
- }
+ uint64_t insert_max = interval.insert.max_latency;
+ uint64_t update_max = interval.update.max_latency;
+
+ if (read_max > latency_max)
+ std::cerr << "WARNING: max latency exceeded for read operation. Threshold "
+ << latency_max << " us, recorded " << read_max << " us, diff "
+ << (read_max - latency_max) << " us." << std::endl;
+ if (insert_max > latency_max)
+ std::cerr << "WARNING: max latency exceeded for insert operation. Threshold "
+ << latency_max << " us, recorded " << insert_max << " us, diff "
+ << (insert_max - latency_max) << " us." << std::endl;
+ if (update_max > latency_max)
+ std::cerr << "WARNING: max latency exceeded for update operation. Threshold "
+ << latency_max << " us, recorded " << insert_max << " us, diff "
+ << (update_max - latency_max) << " us." << std::endl;
prev_interval.assign(interval);
prev_totals.assign(new_totals);
diff --git a/src/third_party/wiredtiger/import.data b/src/third_party/wiredtiger/import.data
index 577b9757f2a..045246f2a36 100644
--- a/src/third_party/wiredtiger/import.data
+++ b/src/third_party/wiredtiger/import.data
@@ -2,5 +2,5 @@
"vendor": "wiredtiger",
"github": "wiredtiger/wiredtiger.git",
"branch": "mongodb-5.0",
- "commit": "5db6a488f50a3c91688ca35cfebbf377dd657a7e"
+ "commit": "15a5f48c534e7f61e9eb81c9509f5d2d31c72d63"
}