From 6551911f361e05eae28f40e82dcd316ad9d0e1d6 Mon Sep 17 00:00:00 2001 From: Alexander Rutkovsky Date: Fri, 10 Jan 2025 19:56:40 +0300 Subject: [PATCH] Fix group resolver bug (#13282) --- .../blobstorage/nodewarden/node_warden_group_resolver.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ydb/core/blobstorage/nodewarden/node_warden_group_resolver.cpp b/ydb/core/blobstorage/nodewarden/node_warden_group_resolver.cpp index 8eff8ea0836c..950241c76445 100644 --- a/ydb/core/blobstorage/nodewarden/node_warden_group_resolver.cpp +++ b/ydb/core/blobstorage/nodewarden/node_warden_group_resolver.cpp @@ -336,9 +336,12 @@ namespace NKikimr::NStorage { if (const auto it = Groups.find(r.GetGroupId()); it != Groups.end() && it->second.Group) { record.MutableGroup()->CopyFrom(*it->second.Group); } + THashSet groupsAdded; for (const auto& [key, value] : LocalVDisks) { if (const auto& r = value.RuntimeData; r && !r->DonorMode) { - record.AddStartedGroupIds(r->GroupInfo->GroupID.GetRawId()); + if (const auto& groupId = r->GroupInfo->GroupID; groupsAdded.insert(groupId).second) { + record.AddStartedGroupIds(groupId.GetRawId()); + } } } Send(ev->Sender, res.release(), 0, ev->Cookie);