HBASE-9157: ZKUtil.blockUntilAvailable loops forever with non-recoverable errors

This commit is contained in:
Jeffrey Zhong 2014-10-15 11:46:30 -07:00
parent c68c17ffec
commit e6248bd45d
1 changed files with 5 additions and 0 deletions

View File

@ -1857,6 +1857,11 @@ public class ZKUtil {
try {
data = ZKUtil.getData(zkw, znode);
} catch(KeeperException e) {
if (e instanceof KeeperException.SessionExpiredException
|| e instanceof KeeperException.AuthFailedException) {
// non-recoverable errors so stop here
throw new InterruptedException("interrupted due to " + e);
}
LOG.warn("Unexpected exception handling blockUntilAvailable", e);
}