mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-25 06:34:42 +02:00
cluster: More delegation bugfixes.
This commit is contained in:
parent
7bc99d3860
commit
6698d09a72
@ -1133,7 +1133,7 @@ void ClusterComponent::CheckAuthorityHandler(const DynamicObject::Ptr& object, c
|
|||||||
BOOST_FOREACH(const Endpoint::Ptr& endpoint, DynamicType::GetObjects<Endpoint>()) {
|
BOOST_FOREACH(const Endpoint::Ptr& endpoint, DynamicType::GetObjects<Endpoint>()) {
|
||||||
bool match = false;
|
bool match = false;
|
||||||
|
|
||||||
if (!endpoint->IsConnected() || !endpoint->HasFeature(type))
|
if ((!endpoint->IsConnected() && endpoint->GetName() != GetIdentity()) || !endpoint->HasFeature(type))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (authorities) {
|
if (authorities) {
|
||||||
@ -1153,8 +1153,11 @@ void ClusterComponent::CheckAuthorityHandler(const DynamicObject::Ptr& object, c
|
|||||||
endpoints.push_back(endpoint->GetName());
|
endpoints.push_back(endpoint->GetName());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (endpoints.empty())
|
if (endpoints.empty()) {
|
||||||
|
result = false;
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
std::sort(endpoints.begin(), endpoints.end());
|
std::sort(endpoints.begin(), endpoints.end());
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user