Bugfixes.

This commit is contained in:
Gunnar Beutner 2012-06-21 13:08:26 +02:00
parent ddeda8c512
commit bbbaca130e
3 changed files with 6 additions and 15 deletions

View File

@ -176,23 +176,13 @@ void CheckerComponent::AssignServiceRequestHandler(const Endpoint::Ptr& sender,
void CheckerComponent::ClearServicesRequestHandler(const Endpoint::Ptr& sender, const RequestMessage& request) void CheckerComponent::ClearServicesRequestHandler(const Endpoint::Ptr& sender, const RequestMessage& request)
{ {
Application::Log(LogDebug, "checker", "Clearing service delegations."); Application::Log(LogInformation, "checker", "Clearing service delegations.");
/* clear the services lists */ /* clear the services lists */
m_Services = ServiceQueue(); m_Services = ServiceQueue();
m_PendingServices.clear(); m_PendingServices.clear();
/* TODO: clear checks we've already sent to the thread pool */ /* TODO: clear checks we've already sent to the thread pool */
string id;
if (request.GetID(&id)) {
ResponseMessage rm;
rm.SetID(id);
MessagePart result;
rm.SetResult(result);
GetEndpointManager()->SendUnicastMessage(m_CheckerEndpoint, sender, rm);
}
} }
EXPORT_COMPONENT(checker, CheckerComponent); EXPORT_COMPONENT(checker, CheckerComponent);

View File

@ -80,11 +80,13 @@ void DelegationComponent::AssignServiceResponseHandler(Service& service, const E
void DelegationComponent::ClearServices(const Endpoint::Ptr& checker) void DelegationComponent::ClearServices(const Endpoint::Ptr& checker)
{ {
RequestMessage request;
request.SetMethod("checker::ClearServices");
} MessagePart params;
request.SetParams(params);
void DelegationComponent::RevokeServiceResponseHandler(Service& service, const Endpoint::Ptr& sender, bool timedOut) GetEndpointManager()->SendUnicastMessage(m_DelegationEndpoint, checker, request);
{
} }
vector<Endpoint::Ptr> DelegationComponent::GetCheckerCandidates(const Service& service) const vector<Endpoint::Ptr> DelegationComponent::GetCheckerCandidates(const Service& service) const

View File

@ -39,7 +39,6 @@ private:
Timer::Ptr m_DelegationTimer; Timer::Ptr m_DelegationTimer;
void AssignServiceResponseHandler(Service& service, const Endpoint::Ptr& sender, bool timedOut); void AssignServiceResponseHandler(Service& service, const Endpoint::Ptr& sender, bool timedOut);
void RevokeServiceResponseHandler(Service& service, const Endpoint::Ptr& sender, bool timedOut);
void DelegationTimerHandler(void); void DelegationTimerHandler(void);