Skip to content

Commit

Permalink
fix(events_executor): Register Waitable timers at TimersManager
Browse files Browse the repository at this point in the history
This should fix a bug, were the internal expire timer of
the action server was not triggered.

Signed-off-by: Janosch Machowinski <J.Machowinski@cellumation.com>
  • Loading branch information
Janosch Machowinski authored and Janosch Machowinski committed Dec 6, 2024
1 parent ea614c7 commit 335fbe4
Showing 1 changed file with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -408,8 +408,18 @@ EventsExecutor::refresh_current_collection(
[this](auto waitable) {
waitable->set_on_ready_callback(
this->create_waitable_callback(waitable.get()));
for (const auto &t : waitable->get_timers())
{
timers_manager_->add_timer(t);
}
},
[](auto waitable) {waitable->clear_on_ready_callback();});
[this](auto waitable) {
waitable->clear_on_ready_callback();
for (const auto &t : waitable->get_timers())
{
timers_manager_->remove_timer(t);
}
});
}

std::function<void(size_t)>
Expand Down

0 comments on commit 335fbe4

Please sign in to comment.