-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
HBASE-28567 Race condition causes MetaRegionLocationCache to never se… #5874
Conversation
I think we should change the logic in MetaRegionLocationCache instead of in ZKWatcher? |
Sure but right now the problem is
So seems like we might need to change |
I agree, we will need to change ZKWatcher one way or another, and currently this is the only caller |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
It is just a bit strange that in ZKUtil we eat the NoNodeException while at the upper layer we create a new NoNodeException and throw it... Better just return null in ZKWatcher, and in MetaRegionLocationCache, we do not break the loop if the return value is null. WDYT? Thanks. |
We need to retry in the case of race condition, that's the main difference from |
Oh, I see you are talking about breaking this loop:
Yeah that might also work. |
I think the original author of But happy to change |
Btw just in case if we end up updating |
I am in favor of keeping patch like this, so that we don't have to keep calling listChildren until |
I need to figure out that what we have fixed here is that we should keep calling listChildren util |
hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java
Show resolved
Hide resolved
Let me attempt to summarize the cases:
|
…t watcher to populate meta location
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.
+1
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
…t watcher to populate meta location (apache#5874) Signed-off-by: Duo Zhang <zhangduo@apache.org> Signed-off-by: Viraj Jasani <vjasani@apache.org>
…t watcher to populate meta location