private void trackWatchForAttempt(WatchedPathInfo watchedPathInfo, WatchKey watchKey) {
    assert watchedPathInfo.pathIdentifier != null;
    // TODO May be possible to do finer-grained locks.
    synchronized (watchesPerAttempt) {
      List<WatchKey> list = watchesPerAttempt.get(watchedPathInfo.pathIdentifier);
      if (list == null) {
        list = new LinkedList<>();
        watchesPerAttempt.put(watchedPathInfo.pathIdentifier, list);
      }
      list.add(watchKey);
    }
  }
Invoke when a pathIdentifier has been found, or is no longer of interest
@param pathIdentifier
llap-server/src/java/org/apache/hadoop/hive/llap/shufflehandler/DirWatcher.java