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

feat: allow retry 0 directives #2479

Merged
merged 1 commit into from
Aug 23, 2024
Merged

feat: allow retry 0 directives #2479

merged 1 commit into from
Aug 23, 2024

Conversation

matt2e
Copy link
Collaborator

@matt2e matt2e commented Aug 22, 2024

closes #2284
This allows for:

  • fsm transitions to opt out of the default fsm retry policy
  • having a catch verb without any retries

eg:

//ftl:retry 0
//ftl:retry 0 catch recover
//ftl:retry 0 1s catch recover

Not allowed because it doesn't make sense:

//ftl:retry 0 1s

eg:
//ftl:retry 0
//ftl:retry 0 catch recover
//ftl:retry 0 1s catch recover

Not allowed:
//ftl:retry 0 1s

This allows for:
- fsm transitions to opt out of the default fsm retry policy
- having a catch verb without any retries
@matt2e matt2e requested a review from alecthomas as a code owner August 22, 2024 04:03
@matt2e matt2e requested review from a team and gak and removed request for a team August 22, 2024 04:03
@ftl-robot ftl-robot mentioned this pull request Aug 22, 2024
@matt2e matt2e changed the title feat: allow zero retry directives feat: allow retry 0 directives Aug 22, 2024
@alecthomas
Copy link
Collaborator

alecthomas commented Aug 22, 2024

Perhaps this should be an explicit //ftl:retry disable instead?

Disregard

@matt2e matt2e added this pull request to the merge queue Aug 22, 2024
Merged via the queue into main with commit 637f20a Aug 23, 2024
20 checks passed
@matt2e matt2e deleted the matt2e/zero-retries branch August 23, 2024 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow retry directive that declares no retry
2 participants