-
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
Delete global namespace #2867
Delete global namespace #2867
Conversation
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.
The task processing part LGTM. @yux0 Would you mind go over the replication part?
return e.namespaceEntry.ReplicationPolicy() == namespace.ReplicationPolicyMultiCluster | ||
return e.namespaceEntry.ReplicationPolicy() == namespace.ReplicationPolicyMultiCluster && | ||
// Don't replicate workflow executions in deleted namespace. | ||
e.namespaceEntry.State() != enumspb.NAMESPACE_STATE_DELETED |
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.
cc @yux0
} | ||
|
||
if err != nil { | ||
if _, isNotFound := err.(*serviceerror.NamespaceNotFound); isNotFound { |
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.
nit: can we define a util function for this check? maybe in the common
package?
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.
no. I am against this. go codders should suffer from all go features!
a4a3a8c
to
2bb0a49
Compare
What changed?
Add support to delete global namespace.
Why?
Some checks needs to be added to support deletion of global namespace.
How did you test it?
Manually in local "global" cluster.
Potential risks
No risks.
Is hotfix candidate?
No.
Notes on delete global namespace
This will eventually go to the docs.
Namespace deletion is not automatically replicated. This works as extra safety net and global namespaces must be deleted manually in every cluster. Rename is not propagated either because it happens after changing of namespace state.
Namespace should be deleted in active cluster first. Otherwise deletion in stand by cluster might take longer because running workflows will be resurrected from active cluster.
See #2855 for more details on deletion of workflow execution.