-
Notifications
You must be signed in to change notification settings - Fork 758
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
Replicate workflow state #2852
Replicate workflow state #2852
Conversation
common/persistence/dataInterfaces.go
Outdated
CreateWorkflowModeUpdateCurrent | ||
// CreateWorkflowModeZombie do not update current record since workflow is in zombie state | ||
// applicable for CreateWorkflowExecution, UpdateWorkflowExecution | ||
CreateWorkflowModeZombie | ||
CreateWorkflowModeBypassCurrent |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
update comments
if workflowState == enumsspb.WORKFLOW_EXECUTION_STATE_CREATED || | ||
workflowState == enumsspb.WORKFLOW_EXECUTION_STATE_RUNNING || | ||
workflowState == enumsspb.WORKFLOW_EXECUTION_STATE_COMPLETED { | ||
workflowState == enumsspb.WORKFLOW_EXECUTION_STATE_RUNNING { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think WORKFLOW_EXECUTION_STATE_COMPLETED is still possible, isn't?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the current workflow vector clock is newer than the incoming closed workflow, then we can still create the closed workflow and not update the current record.
* Replicate workflow state
What changed?
Allow replicate workflow state.
Why?
Allow replicate workflow state for namespace migration optimization.
How did you test it?
TODO: unit tests
Potential risks
Is hotfix candidate?