action executor: execute action only if the associated trigger is registered
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Mon, 12 Apr 2021 19:41:36 +0000 (15:41 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Sun, 18 Apr 2021 23:28:57 +0000 (19:28 -0400)
commitd2a28b277d9a6d5b95a298e400b9f9eab604f6f0
treea7355ef33942ecdb8bb87794b7ad154d12992a69
parent9c374932629a1c25927dad13fce02ba1c4892cf7
action executor: execute action only if the associated trigger is registered

It was decided that a trigger removal should have immediate effect and
not result in a waiting on action queued to be executed.

There was two major way to do this:

1) On unregistrer trigger, lock the action executor queue and remove
all work-item related to the trigger ebing unregistered.

2) Mark the trigger as "unregistered" and validate its state when a work
item is ready for execution. If the trigger is marked as "unregistered",
simply consume and skip the work item.

To isolate the un-registration and the execution of a work item
depending on that trigger, we use the trigger lock to have exclusivity
during the execution for that trigger.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: I9f42a323e0ec0dc51339f39f07536ec8060dc02a
src/bin/lttng-sessiond/action-executor.c
This page took 0.034245 seconds and 4 git commands to generate.