public static Map<TableState, Set<String>> getDisabledOrDisablingTables(ZooKeeperWatcher zkw)
throws KeeperException {
Map<TableState, Set<String>> disabledTables = new HashMap<TableState, Set<String>>();
List<String> children = ZKUtil.listChildrenNoWatch(zkw, zkw.clientTableZNode);
for (String child : children) {
TableState state = getTableState(zkw, child);
if (state == TableState.DISABLED) {
Set<String> tables = disabledTables.get(state);
if (tables == null) {
tables = new HashSet<String>();
disabledTables.put(TableState.DISABLED, tables);