@@ -1022,7 +1022,7 @@ class TDomainLocal : public TActorBootstrapped<TDomainLocal> {
1022
1022
TRegistrationInfo Info;
1023
1023
TVector<TActorId> Locals;
1024
1024
TActorId Subscriber;
1025
- TVector <TTabletId> HiveIds;
1025
+ std::set <TTabletId> HiveIds;
1026
1026
THashMap<TString, TString> Attributes;
1027
1027
TSubDomainKey DomainKey;
1028
1028
};
@@ -1144,7 +1144,7 @@ class TDomainLocal : public TActorBootstrapped<TDomainLocal> {
1144
1144
1145
1145
void RegisterAsSubDomain (const NKikimrScheme::TEvDescribeSchemeResult &rec,
1146
1146
const TResolveTask &task,
1147
- const TVector <TTabletId> hiveIds,
1147
+ const std::set <TTabletId> hiveIds,
1148
1148
const TActorContext &ctx)
1149
1149
{
1150
1150
const auto &domainDesc = rec.GetPathDescription ().GetDomainDescription ();
@@ -1265,14 +1265,14 @@ class TDomainLocal : public TActorBootstrapped<TDomainLocal> {
1265
1265
const auto &domainDesc = rec.GetPathDescription ().GetDomainDescription ();
1266
1266
Y_ABORT_UNLESS (domainDesc.GetDomainKey ().GetSchemeShard () == SchemeRoot);
1267
1267
1268
- TVector <TTabletId> hiveIds (HiveIds);
1268
+ std::set <TTabletId> hiveIds (HiveIds. begin (), HiveIds. end () );
1269
1269
TTabletId hiveId = domainDesc.GetProcessingParams ().GetHive ();
1270
1270
if (hiveId) {
1271
- hiveIds.emplace_back (hiveId);
1271
+ hiveIds.emplace (hiveId);
1272
1272
}
1273
1273
TTabletId sharedHiveId = domainDesc.GetSharedHive ();
1274
1274
if (sharedHiveId) {
1275
- hiveIds.emplace_back (sharedHiveId);
1275
+ hiveIds.emplace (sharedHiveId);
1276
1276
}
1277
1277
RegisterAsSubDomain (rec, task, hiveIds, ctx);
1278
1278
@@ -1303,7 +1303,7 @@ class TDomainLocal : public TActorBootstrapped<TDomainLocal> {
1303
1303
TTenantInfo& tenant = itTenant->second ;
1304
1304
TTabletId hiveId = ev->Get ()->DescribeSchemeResult .GetPathDescription ().GetDomainDescription ().GetProcessingParams ().GetHive ();
1305
1305
if (hiveId) {
1306
- auto itHiveId = Find ( tenant.HiveIds , hiveId);
1306
+ auto itHiveId = tenant.HiveIds . find ( hiveId);
1307
1307
if (itHiveId == tenant.HiveIds .end ()) {
1308
1308
const auto &domainDesc = ev->Get ()->DescribeSchemeResult .GetPathDescription ().GetDomainDescription ();
1309
1309
TVector<TSubDomainKey> servicedDomains = {TSubDomainKey (domainDesc.GetDomainKey ())};
@@ -1313,7 +1313,7 @@ class TDomainLocal : public TActorBootstrapped<TDomainLocal> {
1313
1313
<< " to hive " << hiveId
1314
1314
<< " (allocated resources: " << tenant.Info .ResourceLimit .ShortDebugString () << " )" );
1315
1315
RegisterLocalNode (tenant.Info .TenantName , tenant.Info .ResourceLimit , hiveId, servicedDomains, ctx);
1316
- tenant.HiveIds .emplace_back (hiveId);
1316
+ tenant.HiveIds .emplace (hiveId);
1317
1317
}
1318
1318
}
1319
1319
}
0 commit comments