public static void releaseAllLocks(HiveConf conf) throws Exception {
ZooKeeper zkpClient = null;
try {
int sessionTimeout = conf.getIntVar(HiveConf.ConfVars.HIVE_ZOOKEEPER_SESSION_TIMEOUT);
String quorumServers = getQuorumServers(conf);
Watcher dummWatcher = new DummyWatcher();
zkpClient = new ZooKeeper(quorumServers, sessionTimeout, dummWatcher);
String parent = conf.getVar(HiveConf.ConfVars.HIVE_ZOOKEEPER_NAMESPACE);
List<HiveLock> locks = getLocks(conf, zkpClient, null, parent, false, false);
Exception lastExceptionGot = null;
if (locks != null) {