Skip to content
This repository was archived by the owner on Jun 18, 2025. It is now read-only.

Scheduled jobs in the Pulse system are being incorrectly resumed after restart when their lockedAt field is set to null. #79

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

akolodkin
Copy link

The original query condition: lockedAt: { $exists: true }
matches documents where the lockedAt field exists, including those where lockedAt is null. This leads to unintended resume of jobs that are not actually locked but have a lockedAt: null field due to schema defaults or prior processing.

… values instead of existence.

Prevents accidental resumption or resetting of jobs that are not actively locked but happen to have a lockedAt field set to null.
@b0dea b0dea requested a review from code-xhyun June 18, 2025 12:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant