aboutsummaryrefslogtreecommitdiffstats
path: root/yt/cpp/mapreduce/interface/job_counters.cpp
diff options
context:
space:
mode:
authorAlexander Smirnov <alex@ydb.tech>2025-03-12 10:37:13 +0000
committerAlexander Smirnov <alex@ydb.tech>2025-03-12 10:37:13 +0000
commitb27c447af8bffc727382c0dc75272e261cbb4ac4 (patch)
treee0f6199fec84ae26bb5ea26566fa1daa12693e3b /yt/cpp/mapreduce/interface/job_counters.cpp
parentcb56e1cde2824ff3b64be1de4794bff3cab0db61 (diff)
parentd06e9749bd6f0a561ee4fe296cdb3e03a24d1f82 (diff)
downloadydb-b27c447af8bffc727382c0dc75272e261cbb4ac4.tar.gz
Merge pull request #15611 from ydb-platform/merge-libs-250312-0708
Diffstat (limited to 'yt/cpp/mapreduce/interface/job_counters.cpp')
-rw-r--r--yt/cpp/mapreduce/interface/job_counters.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/yt/cpp/mapreduce/interface/job_counters.cpp b/yt/cpp/mapreduce/interface/job_counters.cpp
index 2d0284e2b1..6468e0e6d0 100644
--- a/yt/cpp/mapreduce/interface/job_counters.cpp
+++ b/yt/cpp/mapreduce/interface/job_counters.cpp
@@ -5,20 +5,20 @@ namespace NYT {
////////////////////////////////////////////////////////////////////////////////
namespace {
- ui64 CountTotal(const TNode& data)
+ i64 CountTotal(const TNode& data)
{
if (data.IsMap()) {
if (auto totalPtr = data.AsMap().FindPtr("total")) {
- return data["total"].IntCast<ui64>();
+ return data["total"].IntCast<i64>();
} else {
- ui64 total = 0;
+ i64 total = 0;
for (const auto& keyVal: data.AsMap()) {
total += CountTotal(keyVal.second);
}
return total;
}
} else {
- return data.IntCast<ui64>();
+ return data.IntCast<i64>();
}
}
@@ -41,16 +41,16 @@ TJobCounter::TJobCounter(TNode data)
}
}
-TJobCounter::TJobCounter(ui64 total)
+TJobCounter::TJobCounter(i64 total)
: Total_(total)
{ }
-ui64 TJobCounter::GetTotal() const
+i64 TJobCounter::GetTotal() const
{
return Total_;
}
-ui64 TJobCounter::GetValue(const TStringBuf key) const
+i64 TJobCounter::GetValue(const TStringBuf key) const
{
if (Data_.HasValue()) {
return CountTotal(Data_[key]);
@@ -154,7 +154,7 @@ const TJobCounter& TJobCounters::GetBlocked() const
return Blocked_;
}
-ui64 TJobCounters::GetTotal() const
+i64 TJobCounters::GetTotal() const
{
return Total_;
}