public static String tryGetCanonicalPathElseGetAbsolutePath(final File file) {
    try {
      return file.getCanonicalPath();
    } catch (IOException e) {
      return file.getAbsolutePath();
    }
  }
This method attempts to get the canonical path of the specified file otherwise returns it's
absolute path.
<p>

@param file the java.io.File object who's canonical path is attempted to be returned.
@return the canonical path of the specified File or the absolute path if an IOException occurs
        during the File.getCanonicalPath call.
@see java.io.File#getCanonicalPath()
@see java.io.File#getAbsolutePath()
geode-core/src/main/java/org/apache/geode/internal/util/IOUtils.java