RedisWriter: use __name as object key

This commit is contained in:
Alexander A. Klimov 2018-06-07 12:53:05 +02:00 committed by Michael Friedrich
parent 3ea3b2ba27
commit a5aef627f8
1 changed files with 6 additions and 6 deletions

View File

@ -149,8 +149,8 @@ void RedisWriter::SendConfigUpdate(const ConfigObject::Ptr& object, bool useTran
Type::Ptr type = object->GetReflectionType();
String typeName = type->GetName().ToLower();
String objectKey = CalculateCheckSumString(object->GetName());
//String objectKey = object->GetName();
//String objectKey = CalculateCheckSumString(object->GetName());
String objectKey = object->GetName();
std::set<String> propertiesBlacklist ({"name", "__name", "package", "source_location", "templates"});
@ -229,8 +229,8 @@ void RedisWriter::SendConfigDelete(const ConfigObject::Ptr& object)
return;
String typeName = object->GetReflectionType()->GetName().ToLower();
String objectKey = CalculateCheckSumString(object->GetName());
//String objectKey = object->GetName();
//String objectKey = CalculateCheckSumString(object->GetName());
String objectKey = object->GetName();
ExecuteQueries({
{ "DEL", "icinga:config:" + typeName + ":" + objectKey },
@ -342,8 +342,8 @@ void RedisWriter::UpdateObjectAttrs(const String& keyPrefix, const ConfigObject:
String objectName = object->GetName();
/* Use the name checksum as unique key. */
String objectKey = CalculateCheckSumString(object->GetName());
//String objectKey = object->GetName();
//String objectKey = CalculateCheckSumString(object->GetName());
String objectKey = object->GetName();
std::vector<std::vector<String> > queries;