-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Deletes are now idempotent #7266
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
Conversation
|
||
newResp, err := s.FrontendClient().DescribeWorkerDeployment(ctx, &workflowservice.DescribeWorkerDeploymentRequest{ | ||
Namespace: s.Namespace().String(), | ||
DeploymentName: tv.DeploymentSeries(), | ||
}) | ||
a.NoError(err) | ||
|
||
var versionSummaryNames []string | ||
for _, versionSummary := range newResp.GetWorkerDeploymentInfo().GetVersionSummaries() { | ||
versionSummaryNames = append(versionSummaryNames, versionSummary.GetVersion()) | ||
} | ||
a.Contains(versionSummaryNames, tv.DeploymentVersionString()) | ||
|
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.
this was done because just verifying a version workflow was not enough - we want a strong guarantee in that the deployment workflow should be created + the version should be registered in the deployment workflow's local list
a test was flaking and this fixed it
special thanks to @carlydf for the pair programming session on this one!
## What changed? <!-- Describe what has changed in this PR --> - make deletes idempotent ## Why? <!-- Tell your future self why have you made these changes --> ## How did you test it? <!-- How have you verified this change? Tested locally? Added a unit test? Checked in staging env? --> - added functional tests - also changes to functional test to make them have a stricter consistency check ## Potential risks <!-- Assuming the worst case, what can be broken when deploying this change to production? --> ## Documentation <!-- Have you made sure this change doesn't falsify anything currently stated in `docs/`? If significant new behavior is added, have you described that in `docs/`? --> ## Is hotfix candidate? <!-- Is this PR a hotfix candidate or does it require a notification to be sent to the broader community? (Yes/No) -->
## What changed? <!-- Describe what has changed in this PR --> - make deletes idempotent ## Why? <!-- Tell your future self why have you made these changes --> ## How did you test it? <!-- How have you verified this change? Tested locally? Added a unit test? Checked in staging env? --> - added functional tests - also changes to functional test to make them have a stricter consistency check ## Potential risks <!-- Assuming the worst case, what can be broken when deploying this change to production? --> ## Documentation <!-- Have you made sure this change doesn't falsify anything currently stated in `docs/`? If significant new behavior is added, have you described that in `docs/`? --> ## Is hotfix candidate? <!-- Is this PR a hotfix candidate or does it require a notification to be sent to the broader community? (Yes/No) -->
## What changed? <!-- Describe what has changed in this PR --> - make deletes idempotent ## Why? <!-- Tell your future self why have you made these changes --> ## How did you test it? <!-- How have you verified this change? Tested locally? Added a unit test? Checked in staging env? --> - added functional tests - also changes to functional test to make them have a stricter consistency check ## Potential risks <!-- Assuming the worst case, what can be broken when deploying this change to production? --> ## Documentation <!-- Have you made sure this change doesn't falsify anything currently stated in `docs/`? If significant new behavior is added, have you described that in `docs/`? --> ## Is hotfix candidate? <!-- Is this PR a hotfix candidate or does it require a notification to be sent to the broader community? (Yes/No) -->
What changed?
Why?
How did you test it?
Potential risks
Documentation
Is hotfix candidate?