feat(tasks): add dummy job executor#995
Open
anpicci wants to merge 5 commits into
Open
Conversation
Replace the logging-only stub with a working pair of tasks: - DummyJobExecutorMonitorTask: periodic task (every 10s) that moves Received jobs to Waiting and schedules a one-shot executor per job. - DummyJobExecutorTask: simulates the execution of a single job by walking it through the state machine's valid path Waiting -> Matched -> Running -> Done via set_job_statuses, holding a per-job mutex lock.
ryuwd
force-pushed
the
issue-964-dummy-job-executor
branch
from
July 17, 2026 11:30
1068562 to
c556409
Compare
ryuwd
marked this pull request as ready for review
July 17, 2026 11:50
chrisburr
reviewed
Jul 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
DummyJobExecutorMonitorTask, a settings-controlled periodic task that:Received, moves them toWaiting, and schedules one executor task per job;DummyJobExecutorTask, a one-shot task that simulates job execution through the valid state sequenceWaiting → Matched → Running → Done, while holding a per-jobMutexLock;jobs:DummyJobExecutorMonitorTaskandjobs:DummyJobExecutorTask;run_local.sh;Motivation
This provides a standalone dummy job-execution pipeline for exercising the DiracX task framework end to end—job discovery, status transitions, task fan-out, and per-job locking—without requiring execution through legacy DIRAC. The monitor remains opt-in so production/default deployments do not schedule it automatically.
Closes #964.
Implementation notes
DummyJobExecutorMonitorTaskusesSize.SMALLand does not define a retry policy, since an enabled monitor runs periodically.DummyJobExecutorTaskusesSize.LARGEandExponentialBackoff(base_delay_seconds=10, max_retries=3).Matched → Running → Donetransitions in oneset_job_statusescall with increasing timestamps, because a direct transition toDonewould be rejected by the state machine.JobDB,JobLoggingDB,TaskQueueDB, andJobParametersDB) andConfigare injected through the task framework.DIRACX_TASKS_DUMMY_JOB_EXECUTOR_ENABLED(default:false);DIRACX_TASKS_DUMMY_JOB_EXECUTOR_INTERVAL_SECONDS(default:10, required to be positive).run_local.shexplicitly enables the monitor at a 10-second interval. The standard demo deployment is handled by the companion charts PR, fix(demo): enable dummy job executor diracx-charts#286.Validation
diracx-taskssuite: 71 passed;--all-files;