private static Properties getHiveSiteOverrides(Configuration hiveSite, Configuration jobConf) {
    // return (hiveSite - jobConf);
    Properties difference = new Properties();
    for (Map.Entry<String,String> keyValue : hiveSite) {
      String key = keyValue.getKey();
      String hiveSiteValue = keyValue.getValue();
      String jobConfValue = jobConf.getRaw(key);

      if (jobConfValue == null) {
        difference.put(key, hiveSiteValue);
      } else if (hiveConfCodeDefaults.containsKey(key)) {
        // Necessary to compare against HiveConf defaults as hive-site.xml is not available on task nodes (like AM).
        if (! jobConfValue.equals(hiveConfCodeDefaults.get(key))) {
          difference.put(key, jobConfValue);
        }
      }
    }

    LOG.info("Configuration differences=" + difference);

    return difference;
  }
Returns the hive-site.xml config settings which do not appear in <code>jobConf<code> or
the hive-site.xml config settings which appear in <code>jobConf<code>, but have a
different value than HiveConf code defaults.
@param hiveSite the config settings as found in the hive-site.xml only.
@param jobConf the config settings used to launch the job.
@return the set difference between hiveSite and jobConf.
hcatalog/core/src/main/java/org/apache/hive/hcatalog/common/HCatUtil.java