-
Notifications
You must be signed in to change notification settings - Fork 225
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
Use OriginalRunID instead of RunID to generate child workflow IDs #1803
base: master
Are you sure you want to change the base?
Conversation
Questions here:
|
Java seems to be generating UUIDs when an ID is not provided in ChildWorkflow options. Additionally when I replayed an existing
Absolutely yes. Java seems to be already doing this (at least in my testing). Looks like it changes the seed at reset-point?
Yes. So far all server versions have prevented resetting of workflows when the reset point falls in between child Init & Completed events (i.e within the lifespan of child). So no potential user impact or backward compatibility issues there.
Yes it is possible to have these two values different at child creation time. When the reset-point is outside the child's lifespan (Init - Completed) then the server has always allowed resets. So in cases when the reset-point is before the child-init, the parent will try to create a child again and this time |
@gow - thanks for this info! So reading all of that I am seeing two things:
For 1, I will start an internal discussion and invite you. Regardless, I am not sure the desired outcome is what is in this PR. |
The desired outcome of this PR is for Go-SDK to be able to replay |
Putting this on hold. Will discuss internally and work on a better fix. |
What was changed
We now use
workflowInfo.OriginalRunID
in parent when it is generating a child workflow ID.Why?
We need this change to enable resetting of workflows that have pending children. What this means is Go SDK should be able to successfully replay
StartChildWorkflowExecutionInitiated
event in a parent that was reset.Without this change Go SDK will run into non-determinism error since the child ID it generates (based on new run ID) doesn't match with the ID available in the
StartChildWorkflowExecutionInitiated
event. SinceOriginalRunID
stays the same across resets, with this change the SDK can successfully replayStartChildWorkflowExecutionInitiated
events.Checklist
Closes
N/A
How was this tested:
Manually tested it (unit tests coming)
Any docs updates needed?
N/A