private static void tryToLogClassPath(String prefix, ClassLoader loader, Logger logger) {
    if(loader instanceof URLClassLoader) {
      logger.debug("{} class path = {}", prefix, Arrays.asList(((URLClassLoader) loader).getURLs()).toString());
    } else {
      logger.debug("{} class path = unavailable for {}", prefix,
          loader == null ? "null" : loader.getClass().getSimpleName());
    }
  }
Logs the class paths of the job class loader and the thread context class loader to the passed logger.
Checks both loaders if getURLs method is available; if not, prints a message about this (instead of the class path)

Note: all messages will always be logged with DEBUG log level.
ql/src/java/org/apache/hadoop/hive/ql/exec/Utilities.java