diff --git a/contrib/ydb/core/cms/console/configs_dispatcher.cpp b/contrib/ydb/core/cms/console/configs_dispatcher.cpp index f94f351dbd2..5a3b44ed728 100644 --- a/contrib/ydb/core/cms/console/configs_dispatcher.cpp +++ b/contrib/ydb/core/cms/console/configs_dispatcher.cpp @@ -771,7 +771,7 @@ void TConfigsDispatcher::Handle(TEvConsole::TEvConfigSubscriptionNotification::T if (subscription->Yaml && YamlConfigEnabled) { ReplaceConfigItems(YamlProtoConfig, trunc, FilterKinds(subscription->Kinds), BaseConfig); } else { - Y_FOR_EACH_BIT(kind, kinds) { + Y_FOR_EACH_BIT(kind, FilterKinds(kinds)) { if (affectedKinds.contains(kind)) { hasAffectedKinds = true; } @@ -785,15 +785,15 @@ void TConfigsDispatcher::Handle(TEvConsole::TEvConfigSubscriptionNotification::T ReplaceConfigItems(ev->Get()->Record.GetConfig(), trunc, FilterKinds(kinds), BaseConfig); } - if (hasAffectedKinds || !CompareConfigs(subscription->CurrentConfig.Config, trunc) || CurrentStateFunc() == &TThis::StateInit) { + if (hasAffectedKinds || !CompareConfigs(subscription->CurrentConfig.Config, trunc, FilterKinds(kinds)) || CurrentStateFunc() == &TThis::StateInit) { subscription->UpdateInProcess = MakeHolder(); subscription->UpdateInProcess->Record.MutableConfig()->CopyFrom(trunc); subscription->UpdateInProcess->Record.SetLocal(true); - Y_FOR_EACH_BIT(kind, kinds) { + Y_FOR_EACH_BIT(kind, FilterKinds(kinds)) { subscription->UpdateInProcess->Record.AddItemKinds(kind); } subscription->UpdateInProcessCookie = ++NextRequestCookie; - subscription->UpdateInProcessConfigVersion = FilterVersion(ev->Get()->Record.GetConfig().GetVersion(), kinds); + subscription->UpdateInProcessConfigVersion = FilterVersion(ev->Get()->Record.GetConfig().GetVersion(), FilterKinds(kinds)); if (YamlConfigEnabled) { UpdateYamlVersion(subscription); @@ -890,6 +890,12 @@ void TConfigsDispatcher::Handle(TEvConfigsDispatcher::TEvSetConfigSubscriptionRe "SetConfigSubscriptionRequest handler"); Y_UNUSED(nonYamlKinds); auto kinds = KindsToBitMap(ev->Get()->ConfigItemKinds); + + auto truncKinds = FilterKinds(kinds); + if (truncKinds.Empty() && !kinds.Empty()) { + return; + } + auto subscriberActor = ev->Get()->Subscriber ? ev->Get()->Subscriber : ev->Sender; auto subscription = FindSubscription(kinds);