Type::Ptr type = object->GetReflectionType();
for (const RedisWriter::Ptr& rw : ConfigType::GetObjectsByType<RedisWriter>()) {
- rw->SendStatusUpdate(object, type->GetName());
+ rw->m_WorkQueue.Enqueue(boost::bind(&RedisWriter::SendStatusUpdate, rw.get(), object, type->GetName()));
}
}
Type::Ptr type = object->GetReflectionType();
for (const RedisWriter::Ptr& rw : ConfigType::GetObjectsByType<RedisWriter>()) {
- rw->SendConfigUpdate(object, type->GetName());
+ rw->m_WorkQueue.Enqueue(boost::bind(&RedisWriter::SendConfigUpdate, rw.get(), object, type->GetName()));
}
}
Type::Ptr type = object->GetReflectionType();
for (const RedisWriter::Ptr& rw : ConfigType::GetObjectsByType<RedisWriter>()) {
- rw->SendConfigUpdate(object, type->GetName());
+ rw->m_WorkQueue.Enqueue(boost::bind(&RedisWriter::SendConfigUpdate, rw.get(), object, type->GetName()));
}
}
if (reply->type == REDIS_REPLY_STATUS || reply->type == REDIS_REPLY_ERROR) {
Log(LogInformation, "RedisWriter")
<< "SCAN " << cursor << " MATCH icinga:subscription:* COUNT 1000: " << reply->str;
+
+ return;
}
VERIFY(reply->type == REDIS_REPLY_ARRAY);
if (vreply->type == REDIS_REPLY_STATUS || vreply->type == REDIS_REPLY_ERROR) {
Log(LogInformation, "RedisWriter")
<< "GET " << keyReply->str << ": " << vreply->str;
+
+ continue;
}
subscriptions[keyReply->str] = vreply->str;
if (reply->type == REDIS_REPLY_STATUS || reply->type == REDIS_REPLY_ERROR) {
Log(LogInformation, "RedisWriter")
<< "LPUSH icinga:event:" << kv.first << " " << body << ": " << reply->str;
+
+ continue;
}
if (reply->type == REDIS_REPLY_ERROR) {