mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Improve validator session stats (#1117)
* Improve validator session stats * Collator stats: block limits, number of processed external messages * Collator and validator work time * Last key block seqno * Approvers and signers * End validator session stats
This commit is contained in:
parent
5bdcb5e2ce
commit
9c3dc22b78
21 changed files with 373 additions and 27 deletions
|
@ -62,4 +62,22 @@ class PerfWarningTimer {
|
|||
std::function<void(double)> callback_;
|
||||
};
|
||||
|
||||
class ThreadCpuTimer {
|
||||
public:
|
||||
ThreadCpuTimer() : ThreadCpuTimer(false) {
|
||||
}
|
||||
explicit ThreadCpuTimer(bool is_paused);
|
||||
ThreadCpuTimer(const ThreadCpuTimer &other) = default;
|
||||
ThreadCpuTimer &operator=(const ThreadCpuTimer &other) = default;
|
||||
|
||||
double elapsed() const;
|
||||
void pause();
|
||||
void resume();
|
||||
|
||||
private:
|
||||
double elapsed_{0};
|
||||
double start_time_;
|
||||
bool is_paused_{false};
|
||||
};
|
||||
|
||||
} // namespace td
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue