diff options
author | Anton Samokhvalov <pg83@yandex.ru> | 2022-02-10 16:45:15 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:45:15 +0300 |
commit | 72cb13b4aff9bc9cf22e49251bc8fd143f82538f (patch) | |
tree | da2c34829458c7d4e74bdfbdf85dff449e9e7fb8 /library/cpp/bucket_quoter/bucket_quoter.h | |
parent | 778e51ba091dc39e7b7fcab2b9cf4dbedfb6f2b5 (diff) | |
download | ydb-72cb13b4aff9bc9cf22e49251bc8fd143f82538f.tar.gz |
Restoring authorship annotation for Anton Samokhvalov <pg83@yandex.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/bucket_quoter/bucket_quoter.h')
-rw-r--r-- | library/cpp/bucket_quoter/bucket_quoter.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/library/cpp/bucket_quoter/bucket_quoter.h b/library/cpp/bucket_quoter/bucket_quoter.h index 3d92ef8450..494644c26a 100644 --- a/library/cpp/bucket_quoter/bucket_quoter.h +++ b/library/cpp/bucket_quoter/bucket_quoter.h @@ -52,7 +52,7 @@ struct TInstantTimerMs { struct THPTimerUs { using TTime = NHPTimer::STime; - static constexpr ui64 Resolution = 1000000ull; // microseconds + static constexpr ui64 Resolution = 1000000ull; // microseconds static TTime Now() { NHPTimer::STime ret; NHPTimer::GetTime(&ret); @@ -88,7 +88,7 @@ public: , TokensUsed(tokensUsed) , UsecWaited(usecWaited) , AggregateInflow(aggregateInflow) - , Bucket(fill ? capacity : 0) + , Bucket(fill ? capacity : 0) , LastAdd(Timer::Now()) , InflowTokensPerSecond(&FixedInflow) , BucketTokensCapacity(&FixedCapacity) @@ -107,7 +107,7 @@ public: , TokensUsed(tokensUsed) , UsecWaited(usecWaited) , AggregateInflow(aggregateInflow) - , Bucket(fill ? AtomicGet(*capacity) : 0) + , Bucket(fill ? AtomicGet(*capacity) : 0) , LastAdd(Timer::Now()) , InflowTokensPerSecond(inflow) , BucketTokensCapacity(capacity) @@ -214,7 +214,7 @@ public: } void Sleep() { - while (!IsAvail()) { + while (!IsAvail()) { ui32 delay = GetWaitTime(); if (delay != 0) { usleep(delay); @@ -263,9 +263,9 @@ private: } } - StatCounter* MsgPassed; - StatCounter* BucketUnderflows; - StatCounter* TokensUsed; + StatCounter* MsgPassed; + StatCounter* BucketUnderflows; + StatCounter* TokensUsed; StatCounter* UsecWaited; StatCounter* AggregateInflow; @@ -274,8 +274,8 @@ private: Lock BucketMutex; ui64 Seqno = 0; - TAtomic* InflowTokensPerSecond; - TAtomic* BucketTokensCapacity; + TAtomic* InflowTokensPerSecond; + TAtomic* BucketTokensCapacity; TAtomic FixedInflow; TAtomic FixedCapacity; }; |