public static void deleteIfExists(FileSystem fs, Path path) {
    try {
      fs.delete(path, true);
    } catch (IOException e) {
      LOG.debug("Unable to delete {}", path, e);
    }
  }
Attempts to delete a file if it exists.
@param fs FileSystem
@param path Path to be deleted.
common/src/java/org/apache/hadoop/hive/common/FileUtils.java