Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scheduledtask.go spews a lot of lease conflict debug logs #1678

Closed
matt2e opened this issue Jun 6, 2024 · 2 comments · Fixed by #1844
Closed

scheduledtask.go spews a lot of lease conflict debug logs #1678

matt2e opened this issue Jun 6, 2024 · 2 comments · Fixed by #1844
Assignees
Labels
good first issue Good for newcomers

Comments

@matt2e
Copy link
Collaborator

matt2e commented Jun 6, 2024

Not sure why this is happening (probably incorrect errors being generated), it should all work fine:

  • scheduler is checking if the error is a conflict and only logging at trace level

Instead when I run ftl with --log-level=DEBUG --controllers=5 i get this output:

debug:func12: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict
debug:func10: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict
debug:func12: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict
debug:func11: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict
debug:func11: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict
debug:func10: Failed to acquire lease: duplicate key value violates unique constraint "leases_key_key": conflict

@github-actions github-actions bot added the triage Issue needs triaging label Jun 6, 2024
@ftl-robot ftl-robot mentioned this issue Jun 6, 2024
@alecthomas
Copy link
Collaborator

You sure this didn't happen after a laptop suspend/resume cycle?

@alecthomas
Copy link
Collaborator

This is behind a if errors.Is(err, leases.ErrConflict) { but is executing the else case for some reason, even though we see : conflict in the message. We should fix this.

@alecthomas alecthomas added good first issue Good for newcomers and removed triage Issue needs triaging labels Jun 6, 2024
@matt2e matt2e self-assigned this Jun 21, 2024
@matt2e matt2e closed this as completed in b5bdbf5 Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants