Skip to content

docs(ts): stop work in ctx.run when an attempt ends - #418

Open
wthrajat wants to merge 1 commit into
restatedev:mainfrom
wthrajat:docs/ts-attempt-completed-signal
Open

wthrajat wants to merge 1 commit into
restatedev:mainfrom
wthrajat:docs/ts-attempt-completed-signal

Conversation

@wthrajat

@wthrajat wthrajat commented Oct 5, 2026 •

Copy link
Copy Markdown

If the connection drops while a ctx.run is running, Restate retries in a new attempt, but the old attempt keeps running and its side effects still happen.
I measured this with a charge that took 250 ms: the card was charged twice.
ctx.request().attemptCompletedSignal stops the old attempt, but it is not mentioned in the docs yet

This PR adds a short accordion to the TS durable steps page, with a snippet

This branch has not been deployed

No deployments
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.

1 participant