Skip to content
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 replication-cluster list change for peer-cluster when zk-watch… #3426

Merged
merged 1 commit into from
Mar 8, 2019

Conversation

rdhabalia
Copy link
Contributor

Motivation

Addressing: #3425

Issue

There could be possible data-loss when user is using peer-cluster feature and changes replication cluster from peer1-cluster to peer2-cluster.

  • Sometimes, broker never receives a zk-watch for namespace policies change so, if replication cluster list has been changed then there is a possibility that broker which is owning bundle of that namespace, might not see the change and still serving the namespace bundle.
  • if the replication cluster has been changed from peer-cluster1 to peer-cluster2 then peer-cluster1 will continue to serve namespace and will not redirect lookup-request to peer-cluster2. in that case there will be ownership discrepancy and peer-cluster2 might not receive the traffic which will cause in data-loss.

Fix

  • this issue happens when one of broker doesn't receive the zk-watch.
  • To fix the issue, whichever broker receives the watch, that unloads the namespace if it's already owned by local cluster and broker invalidates namespace-policy cache before owning the namespace bundle to avoid any discrepancy.

@rdhabalia rdhabalia added this to the 2.3.0 milestone Jan 24, 2019
@rdhabalia rdhabalia self-assigned this Jan 24, 2019
Copy link
Contributor

@merlimat merlimat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@rdhabalia
Copy link
Contributor Author

retest this please

@merlimat merlimat modified the milestones: 2.3.0, 2.4.0 Feb 14, 2019
@rdhabalia rdhabalia force-pushed the repl_milti branch 3 times, most recently from a74054a to 5632e81 Compare February 28, 2019 19:58
@rdhabalia
Copy link
Contributor Author

rerun java8 tests
rerun integration tests

@rdhabalia
Copy link
Contributor Author

rerun java8 tests

3 similar comments
@rdhabalia
Copy link
Contributor Author

rerun java8 tests

@rdhabalia
Copy link
Contributor Author

rerun java8 tests

@rdhabalia
Copy link
Contributor Author

rerun java8 tests

@rdhabalia rdhabalia merged commit 32a244d into apache:master Mar 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants