Skip to content

Cancel Multiple Instance Activity, and a cancelled fork strand ends i… - #137

Merged
noha merged 1 commit into
mainfrom
cancel-iterations
Sep 10, 2026
Merged

noha merged 1 commit into
mainfrom
cancel-iterations

Conversation

@noha

@noha noha commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

…ts loop

FBFlowInstance>>cancelIterationsOf: cancels every iteration of a running parallel node that is still running or waiting - their scopes fall, sub flow frames included - and lets no further one start. The loop then completes with what arrived, nil in the slots taken back, and the flow goes on behind it (WCP-26: control passes on). A node that is not looping answers empty and leaves no trace.

Cancelling the fork's own strand is the other thing (WCP-19 on the loop): the loop starts no further iteration and nothing goes on behind its join. Until now it took the iterations and then started the next one. For that, cancelStrand: marks the named token itself when its activation is still standing - a fork whose loop is open, a sub flow node whose child runs - and records an FBNodeActivationCancelled for it; a token of an activation already done stays as it is.

…ts loop

FBFlowInstance>>cancelIterationsOf: cancels every iteration of a
running parallel node that is still running or waiting - their scopes
fall, sub flow frames included - and lets no further one start. The
loop then completes with what arrived, nil in the slots taken back,
and the flow goes on behind it (WCP-26: control passes on). A node
that is not looping answers empty and leaves no trace.

Cancelling the fork's own strand is the other thing (WCP-19 on the
loop): the loop starts no further iteration and nothing goes on behind
its join. Until now it took the iterations and then started the next
one. For that, cancelStrand: marks the named token itself when its
activation is still standing - a fork whose loop is open, a sub flow
node whose child runs - and records an FBNodeActivationCancelled for
it; a token of an activation already done stays as it is.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@noha
noha merged commit 953815d into main Sep 10, 2026
4 checks passed
@noha
noha deleted the cancel-iterations branch September 10, 2026 12:01
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