generated from TBD54566975/tbd-project-template
-
Notifications
You must be signed in to change notification settings - Fork 8
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
Async calls get stuck if controller dies #2214
Comments
Open
I think in other use cases for leases we have special logic to handle the necessary knock on effects, but it seems like we didn't do it for async calls, or it's not working |
github-merge-queue bot
pushed a commit
that referenced
this issue
Aug 27, 2024
fixes #2214 Changes: - The controller now calls the verb within the lease context, so a failure to heartbeat the lease cancels the grpc call - A new periodic task that cleans up async calls with a state of executing but without a lease - This happens after the lease has been reaped in a separate job - Cleaning up involves: - Scheduling retries/catches according to the policy - Triggering the origin-specific code (eg: fsm async calls need the next event table to be cleared) Known issues: - If there is a repeating error cleaning up an async call, then it will just repeatedly fail - Java does not currently have a way to stop execution of the call that gets canceled, so it will always continue even when the async call's lease expires --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This was referenced Aug 27, 2024
Open
Open
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Steps to reproduce
time.Sleep(time.Minute); return nil
ftl dev --log-level=DEBUG backend/controller/pubsub/testdata/go/subscriber backend/controller/pubsub/testdata/go/publisher --recreate
publisher.publishOneToTopic2
--recreate
Expected result:
Actual result:
executing
state foreverI think this happens for any case where async call leases expire, like:
It think it might also happen in this case:
executeAsyncCalls()
CompleteAsyncCall
fails for any reason (eg db connection error)Similar to what's outlined above, we now have a released lease and a async call row that will sit in an
executing
state foreverThe text was updated successfully, but these errors were encountered: