LUMIERA.clone/tests
Ichthyostega b497980522 Scheduler-test: guard memory allocations by grooming-token
Turns out that we need to implemented fine grained and explicit handling logic
to ensure that Activity planning only ever happens protected by the Grooming-Token.
This is in accordance to the original design, which dictates that all management tasks
must be done in »management mode«, which can only be entered by a single thread at a time.
The underlying assumption is that the effort for management work is dwarfed in comparison
to any media calculation work.

However, in
5c6354882d
...I discovered an insidious border condition, an in an attempt to fix it,
I broke that fundamental assumpton. The problem arises from the fact that we
do want to expose a *public API* of the Scheduler. Even while this is only used
to ''seed'' a calculation stream, because any further planning- and management work
will be performed by the workers themselves (this is a design decision, we do not
employ a "scheduler thread")
Anyway, since the Scheduler API ''is'' public, ''someone from the outside'' could
invoke those functions, and — unaware of any Scheduler internals — will
automatically acquire the Grooming-Token, yet never release it,
leading to deadlock.

So we need a dedicated solution, which is hereby implemented as a
scoped guard: in the standard case, the caller is a management-job and
thus already holds the token (and nothing must be done). But in the
rare case of an »outsider«, this guard now ''transparently'' acquires
the token (possibly with a blocking wait) and ''drops it when leaving scope''
2023-12-19 23:38:57 +01:00
..
basics Chain-Load: draft usage for Scheduler testing 2023-12-04 00:34:06 +01:00
core Chain-Load: draft usage for Scheduler testing 2023-12-04 00:34:06 +01:00
include
library Chain-Load: combine all exit-hashes into a single global hash 2023-12-09 02:36:14 +01:00
operation
plugin
stage Library/Application: consolidate Monitor API and usage 2023-10-15 20:42:55 +02:00
tool
vault Scheduler-test: guard memory allocations by grooming-token 2023-12-19 23:38:57 +01:00
00helloworld.tests
00support.tests Activity-Lang: support negative assertions for tests 2023-08-14 19:25:56 +02:00
00test.tests
10errorhandling.tests
10exception.tests Library: discontinue setting error flag from Exceptions (see #1341) 2023-10-01 20:11:45 +02:00
11concurrency.tests LibraryApplication: tie DispatcherLoop to thread lifecycle 2023-10-12 20:23:59 +02:00
11list.tests
11locking.tests Library/Application: complete technology switch (closes #1279) 2023-10-16 01:44:04 +02:00
11luid.tests
11safeclib.tests
11time.tests
11vault-memory.tests Block-Flow: completed implementation of low-level cyclic extent storage 2023-07-12 21:55:50 +02:00
12metaprogramming.tests Library: test coverage for self-managed thread 2023-10-11 21:06:56 +02:00
15library.tests Chain-Load: safety problems with rule initialisation 2023-12-03 04:59:18 +01:00
20config_lowlevel.tests
20threads.tests
22config_highlevel.tests
25fundamental.tests Library: prepare switch of Thread-wrapper to C++17 2023-09-21 23:23:55 +02:00
30backend-file.tests
30interfaces.tests
31plugin.tests
32scheduler.tests Scheduler-test: Integration-test now running smoothly 2023-12-18 23:34:10 +01:00
40core.tests
41asset.tests
42query.tests
43session.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
44controller.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
45builder.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
46fixture.tests Dispatcher-Pipeline: create hook for self-validation 2023-06-12 01:18:59 +02:00
46node.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
47engine.tests bye bye Monad (closes #1276) 2023-06-22 20:23:55 +02:00
48playout.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
49core-integration.tests Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment 2023-06-07 04:03:00 +02:00
51-gui-model.tests Segmentation: structure analysis for splitSplice operation 2023-05-02 04:29:34 +02:00
52-gui-control.tests
80-regression.tests
DIR_INFO
SConscript
test.conf Testsuite: increase virtual memory limit 2023-10-04 22:42:37 +02:00
test.sh
testrunner.cpp