Application::Log(LogWarning, "checker", latwarn.str());
}
- stringstream msgbuf;
- msgbuf << "ResultTimerHandler: " << results << " results (" << failed << " failed); latency: avg=" << avg_latency / (results ? results : 1) << ", min=" << min_latency << ", max: " << max_latency;
- Application::Log(LogInformation, "checker", msgbuf.str());
+ {
+ stringstream msgbuf;
+ msgbuf << "ResultTimerHandler: " << results << " results (" << failed << " failed); latency: avg=" << avg_latency / (results ? results : 1) << ", min=" << min_latency << ", max: " << max_latency;
+ Application::Log(LogInformation, "checker", msgbuf.str());
+ }
+
+ {
+ stringstream msgbuf;
+ msgbuf << "Pending services: " << m_PendingServices.size() << "; idle services: " << m_Services.size();
+ Application::Log(LogInformation, "checker", msgbuf.str());
+ }
}
void CheckerComponent::AssignServiceRequestHandler(const Endpoint::Ptr& sender, const RequestMessage& request)
for (it = GetEndpointManager()->Begin(); it != GetEndpointManager()->End(); it++) {
Endpoint::Ptr endpoint = it->second;
+ /* ignore disconnected endpoints */
+ if (!endpoint->IsConnected())
+ continue;
+
+ /* ignore endpoints that aren't running the checker component */
if (!endpoint->HasSubscription("checker::AssignService"))
continue;
AssignService(endpoint, *sit);
}
+
+ map<Endpoint::Ptr, int>::iterator hit;
+ for (hit = histogram.begin(); hit != histogram.end(); hit++) {
+ stringstream msgbuf;
+ msgbuf << "histogram: " << hit->first->GetIdentity() << " - " << hit->second;
+ Application::Log(LogInformation, "delegation", msgbuf.str());
+ }
}
stringstream msgbuf;