From d4a91ec50dbac50eb621ab3788414b3d1b1bfa20 Mon Sep 17 00:00:00 2001 From: "Alexander A. Klimov" Date: Wed, 17 Feb 2021 12:41:45 +0100 Subject: [PATCH] Icinga DB: don't write all types --- lib/icingadb/icingadb-objects.cpp | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/lib/icingadb/icingadb-objects.cpp b/lib/icingadb/icingadb-objects.cpp index 8ff1ae554..e18a08a26 100644 --- a/lib/icingadb/icingadb-objects.cpp +++ b/lib/icingadb/icingadb-objects.cpp @@ -127,7 +127,23 @@ void IcingaDB::UpdateAllConfigObjects() typedef std::pair TypePair; std::vector types; - for (const Type::Ptr& type : Type::GetAllTypes()) { + for (const Type::Ptr& type : { + CheckCommand::TypeInstance, + Comment::TypeInstance, + Downtime::TypeInstance, + Endpoint::TypeInstance, + EventCommand::TypeInstance, + Host::TypeInstance, + HostGroup::TypeInstance, + Notification::TypeInstance, + NotificationCommand::TypeInstance, + Service::TypeInstance, + ServiceGroup::TypeInstance, + TimePeriod::TypeInstance, + User::TypeInstance, + UserGroup::TypeInstance, + Zone::TypeInstance + }) { ConfigType *ctype = dynamic_cast(type.get()); if (!ctype) continue;