cleanup(now);
f->open_object_section("OpHistory slow ops");
f->dump_int("num to keep", history_slow_op_size.load());
- f->dump_int("threshold to keep", history_slow_op_threshold.load());
+ f->dump_float("threshold to keep", history_slow_op_threshold.load());
{
f->open_array_section("Ops");
for (set<pair<utime_t, TrackedOpRef> >::const_iterator i =
std::atomic_size_t history_size{0};
std::atomic_uint32_t history_duration{0};
std::atomic_size_t history_slow_op_size{0};
- std::atomic_uint32_t history_slow_op_threshold{0};
+ std::atomic<float> history_slow_op_threshold{0};
std::atomic_bool shutdown{false};
OpHistoryServiceThread opsvc;
friend class OpHistoryServiceThread;
history_size = new_size;
history_duration = new_duration;
}
- void set_slow_op_size_and_threshold(size_t new_size, uint32_t new_threshold) {
+ void set_slow_op_size_and_threshold(size_t new_size, float new_threshold) {
history_slow_op_size = new_size;
history_slow_op_threshold = new_threshold;
}
void set_history_size_and_duration(uint32_t new_size, uint32_t new_duration) {
history.set_size_and_duration(new_size, new_duration);
}
- void set_history_slow_op_size_and_threshold(uint32_t new_size, uint32_t new_threshold) {
+ void set_history_slow_op_size_and_threshold(uint32_t new_size, float new_threshold) {
history.set_slow_op_size_and_threshold(new_size, new_threshold);
}
bool is_tracking() const {