-
Notifications
You must be signed in to change notification settings - Fork 912
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
Handle namespace not found in replication #3557
Conversation
if e.currentCluster == targetCluster { | ||
shouldProcessTask = true | ||
break FilterLoop | ||
switch err.(type) { |
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 feel like an existing unit test should fail? Otherwise we probably don't have proper test coverage :)
I stamped this PR but please use your judgement here.
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.
Let me add one
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.
To me it looks like embedding the shouldProcessTask
logic in the error handling part makes the code a bit hard to understand.
(FYI, currently the only error returned by GetNamespaceByID is namespace not found, but that may change in the future if we make to make the cache read through. so check error type is 👍 )
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.
Revert to original logic and just handle namespace not found error
Also wait for @yycptt to stamp before merge. |
* Handle ns not found in replication
* Handle ns not found in replication
What changed?
Why?
How did you test it?
Existing tests
Potential risks
Is hotfix candidate?
No