mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Add GetPerfTimerStats (#451)
* Add getperfwarningtimeraverage query for validator-engine-console * Fix for getperfwarningtimeraverage query * getperftimerstats * Add history max size: 1 hour * PerfWarningTimer: move callback instead of copy * PerfWarningTimer: fix move constructor bug * PerfWarningTimer: fix bug: lifetime of the callback was greater than lifetime of the local variable 'manager' captured by reference * Fix validate-query.cpp: 'manager' used after it was moved * PerfWarningTimer: remove logs * getperftimerstats: write to json file * getperftimerstatsjson Co-authored-by: legaii <jgates.ardux@gmail.com> Co-authored-by: Ivan Siomash <106972486+legaii@users.noreply.github.com>
This commit is contained in:
parent
8376c289d7
commit
8329a58994
25 changed files with 244 additions and 27 deletions
|
@ -59,12 +59,15 @@ ValidateQuery::ValidateQuery(ShardIdFull shard, UnixTime min_ts, BlockIdExt min_
|
|||
, prev_blocks(std::move(prev))
|
||||
, block_candidate(std::move(candidate))
|
||||
, validator_set_(std::move(validator_set))
|
||||
, manager(std::move(manager))
|
||||
, manager(manager)
|
||||
, timeout(timeout)
|
||||
, main_promise(std::move(promise))
|
||||
, is_fake_(is_fake)
|
||||
, shard_pfx_(shard_.shard)
|
||||
, shard_pfx_len_(ton::shard_prefix_length(shard_)) {
|
||||
, shard_pfx_len_(ton::shard_prefix_length(shard_))
|
||||
, perf_timer_("validateblock", 0.1, [manager](double duration) {
|
||||
send_closure(manager, &ValidatorManager::add_perf_timer_stat, "validateblock", duration);
|
||||
}) {
|
||||
proc_hash_.zero();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue