code: public void removeDir(StorageDir dir) {
      // TODO(feng): Add a command for manually removing directory
      try (LockResource r = new LockResource(mMetadataWriteLock)) {
        String tierAlias = dir.getParentTier().getTierAlias();
        dir.getParentTier().removeStorageDir(dir);
        synchronized (mBlockStoreEventListeners) {
          for (BlockStoreEventListener listener : mBlockStoreEventListeners) {
            dir.getBlockIds().forEach(listener::onBlockLost);
            listener.onStorageLost(tierAlias, dir.getDirPath());
          }
        }
      }
    }
docs: Removes a storage directory.
  
  @param dir storage directory to be removed