code: synchronized void replaceLease(Lease newLease) {
      leases.put(newLease.getHolder(), newLease);
      sortedLeases.remove(newLease);
      sortedLeases.add(newLease);
  
      for (String path : newLease.paths) {
        sortedLeasesByPath.put(
          path, new LeaseOpenTime(newLease, System.currentTimeMillis()));
      }
    }
docs: for testing only