Commit Graph

10 Commits

Author SHA1 Message Date
flow
81fedbf03c
refactor(Tasks): remove 'm_total_size' from ConcurrentTask
We can use the queues directly instead.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-12-17 13:10:19 -03:00
flow
b0c866bfaa
feat(Tasks): allow adding subtasks while running in ConcurrentTask
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-12-15 13:48:53 -03:00
flow
dd578354c4
feat(Tasks): add ConcurrentTask::clear to allow re-using tasks
This way old runs won't pile up in the internal DSs

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-12-15 13:45:50 -03:00
flow
7cf2c3be0f
fix: start at least one task in ConcurrentTask
This allows us to emit all the necessary stuff when we're finished in
the case of starting a task with no subtasks. In particular, this caused
the mod updater to not work properly :)

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-09-07 12:11:42 -03:00
flow
bdf464e792
fix: abort logic running subsequent tasks anyways some times
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-28 16:29:01 -03:00
flow
c410bb4ecb
fix: 'succeeded while not running' spam in ConcurrentTask
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-28 16:29:01 -03:00
flow
a720bcc637
fix: bogus progress update when the total step progress was zero
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-28 16:29:01 -03:00
flow
369a8cdc74
fix: only try to start tasks that are really there
This fixes an annoying issue where concurrent tasks would try to start
multiple tasks even when there was not that many tasks to run in the
first place, causing some amount of log spam.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-28 16:29:00 -03:00
flow
a9e8ed5087
fix: pump events and do a queued start for concurrent tasks
Heavy workloads can consume a ton of time doing their stuff, and starve
the event loop out of events. This adds an event processing call after
every concurrent task has been completed, to decrease the event loop
stravation on such loads.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-24 17:46:54 -03:00
flow
8e80b4bfc1
feat: add ConcurrentTask
This tasks (or rather, meta-task) has the ability to run several other
sub tasks concurrently.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-01 08:34:10 -03:00