Skip to content
Merged
Show file tree
Hide file tree
Changes from 39 commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
ef93f94
IcingaDB: Start keeping track of Host/Service to Dependency relationship
oxzi Oct 21, 2024
d6b289e
Checkable: Introduce `GetAllChildrenCount()` method
yhabteab Dec 2, 2024
297b62d
IcingaDB: Add `affected_children` to `Host/Service` Redis updates
yhabteab Dec 2, 2024
6321606
IcingaDB: Sync `affects_children` as part of runtime state updates
yhabteab Dec 2, 2024
c64ae1a
Dependency: Don't allow to change `redundancy_group` at runtime
yhabteab Dec 5, 2024
772420a
Checkable: Don't always trigger reachablity changed signal
yhabteab Feb 6, 2025
c02b9d7
IcingaDB: Send reachablity state updates for all children
yhabteab Jan 15, 2025
e0ce0cc
Activate `Dependency` objects before their parent objects
yhabteab Jan 10, 2025
c465f45
Rewrite `Checkable::GetAllChildrenInternal()` method
yhabteab Jan 31, 2025
67664ad
Checkable::GetAllChildrenInternal: remove redundant emplace call
julianbrost Feb 6, 2025
93d9fad
Checkable: Drop unused `failedDependency` argument from `IsReachable()`
yhabteab Dec 12, 2024
d7c9e66
Introduce `DependencyGroup` helper class
yhabteab Dec 5, 2024
1820955
Add `DependencyGroup::GetState()` helper method
yhabteab Dec 5, 2024
ff0dabe
Checkable: Store dependencies grouped by their redundancy group
yhabteab Dec 4, 2024
27f11a0
Checkable: Introduce `HasAnyDependencies()` method
yhabteab Feb 7, 2025
d094581
Checkable: Use redundancy groups state in `IsReachable`
yhabteab Dec 16, 2024
2616c99
tests: Add unittests for the redundancy groups registry
yhabteab Dec 16, 2024
4bfaefa
IcingaDB: Bump expected redis version to `6`
yhabteab Dec 16, 2024
c6466ee
IcingaDB: Dump checkables dependencies config to redis correctly
yhabteab Dec 4, 2024
f502993
IcingaDB: Sync dependencies states to Redis
yhabteab Dec 4, 2024
db3f8de
IcingaDB: Sync dependencies initial states on config dump
yhabteab Dec 5, 2024
aed1bb6
IcingaDB: Introduce `ExecuteRedisTransaction()` helper method
yhabteab Feb 24, 2025
26f46fe
Simplify dependency group registration
julianbrost Feb 7, 2025
67a4889
Checkable: Delay dependency group global registration on startup
yhabteab Feb 7, 2025
6a0ec70
Fix & adjust dependencies unittests
yhabteab Jan 28, 2025
b462028
Add basic unittests for bulk group registration
yhabteab Jan 28, 2025
806fff9
Checkable: Emit boost signals when changing dependency groups at runtime
yhabteab Feb 7, 2025
8640a3f
Checkable: Extract parents directly from dependency groups
yhabteab Feb 10, 2025
915ea64
Use `GetParents()` in `FireSppressedNotifications()`
yhabteab Feb 10, 2025
0ab50fd
IcingaDB: Process dependencies runtime updates
yhabteab Feb 10, 2025
ce1ed85
Simplify DependencyGroup::GetState() implementation
julianbrost Feb 12, 2025
7fbb8f7
Evaluate dependency group state only for a specific child
yhabteab Feb 14, 2025
a9bb11b
(Un)register dependencies from parent prior to child Checkable
yhabteab Feb 14, 2025
21cd5e0
Dependency: Don't allow to update `{period,states,ignore_soft_states}…
yhabteab Feb 17, 2025
da637c3
IcingaDB: Always send dependencies state HSET updates to Redis
yhabteab Feb 17, 2025
945a79e
IcingaDB: Don't send useless dependencies state updates
yhabteab Feb 28, 2025
693d094
DependencyGroup: don't change the keys of m_Members after construction
julianbrost Mar 13, 2025
864e2aa
Drop superfluous mutex lock & don't manually unpack `std::tuple`
yhabteab Mar 13, 2025
065118b
Make DependencyGroup::State an enum
julianbrost Mar 13, 2025
bc2c750
IcingaDB: Don't stream runtime state updates to Redis
yhabteab Mar 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/icinga/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ set(icinga_SOURCES
comment.cpp comment.hpp comment-ti.hpp
compatutility.cpp compatutility.hpp
customvarobject.cpp customvarobject.hpp customvarobject-ti.hpp
dependency.cpp dependency.hpp dependency-ti.hpp dependency-apply.cpp
dependency.cpp dependency-group.cpp dependency.hpp dependency-ti.hpp dependency-apply.cpp
downtime.cpp downtime.hpp downtime-ti.hpp
envresolver.cpp envresolver.hpp
eventcommand.cpp eventcommand.hpp eventcommand-ti.hpp
Expand Down
6 changes: 5 additions & 1 deletion lib/icinga/checkable-check.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,10 @@ Checkable::ProcessingResult Checkable::ProcessCheckResult(const CheckResult::Ptr
bool reachable = IsReachable();
bool notification_reachable = IsReachable(DependencyNotification);

// Cache whether the previous state of this Checkable affects its children before overwriting the last check result.
// This will be used to determine whether the on reachability changed event should be triggered.
bool affectsPreviousStateChildren(reachable && AffectsChildren());

ObjectLock olock(this);

CheckResult::Ptr old_cr = GetLastCheckResult();
Expand Down Expand Up @@ -533,7 +537,7 @@ Checkable::ProcessingResult Checkable::ProcessCheckResult(const CheckResult::Ptr
}

/* update reachability for child objects */
if ((stateChange || hardChange) && !children.empty())
if ((stateChange || hardChange) && !children.empty() && (affectsPreviousStateChildren || AffectsChildren()))
OnReachabilityChanged(this, cr, children, origin);

return Result::Ok;
Expand Down
Loading
Loading