mirror of
https://github.com/Icinga/icinga2.git
synced 2025-04-08 17:05:25 +02:00
Merge pull request #9421 from Icinga/IcingaDB-soft_state-2.13
Icinga DB: icinga:*:state: rename state to soft_state
This commit is contained in:
commit
3f86f236e5
@ -2553,14 +2553,14 @@ Dictionary::Ptr IcingaDB::SerializeState(const Checkable::Ptr& checkable)
|
||||
if (service) {
|
||||
attrs->Set("service_id", id);
|
||||
auto state = service->HasBeenChecked() ? service->GetState() : 99;
|
||||
attrs->Set("state", state);
|
||||
attrs->Set("soft_state", state);
|
||||
attrs->Set("hard_state", service->HasBeenChecked() ? service->GetLastHardState() : 99);
|
||||
attrs->Set("severity", service->GetSeverity());
|
||||
attrs->Set("host_id", GetObjectIdentifier(host));
|
||||
} else {
|
||||
attrs->Set("host_id", id);
|
||||
auto state = host->HasBeenChecked() ? host->GetState() : 99;
|
||||
attrs->Set("state", state);
|
||||
attrs->Set("soft_state", state);
|
||||
attrs->Set("hard_state", host->HasBeenChecked() ? host->GetLastHardState() : 99);
|
||||
attrs->Set("severity", host->GetSeverity());
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user