Closed wdbaruni closed 1 month ago
[!IMPORTANT]
Review Skipped
Auto reviews are disabled on this repository.
Please check the settings in the CodeRabbit UI or the
.coderabbit.yaml
file in this repository. To trigger a single review, invoke the@coderabbitai review
command.You can disable this status message by setting the
reviews.review_status
tofalse
in the CodeRabbit configuration file.
In many places we update the state of jobs or executions, create an evaluation, and then enqueue the evaluation to the broker. The creation and enqueue of evaluations is not atomic. This can result in a lot of edge cases and potentially dangling or stale jobs and executions due to failure to trigger their re-evaluation.
This PR fixes this by implementing a data store watcher the listens for created evaluations and auto-enqueue those evaluations to the broker.
What is left is backfill of non-terminal evaluations at startup which will be tracked by https://github.com/bacalhau-project/bacalhau/issues/3999
Closes #3972