public static int getFooterCount(TableDesc table, JobConf job) throws IOException {
    int footerCount;
    try {
      footerCount =
          getHeaderOrFooterCount(table, serdeConstants.FOOTER_COUNT);
      if (footerCount > HiveConf.getIntVar(job, HiveConf.ConfVars.HIVE_FILE_MAX_FOOTER)) {
        throw new IOException("footer number exceeds the limit defined in hive.file.max.footer");
      }
    } catch (NumberFormatException nfe) {

      // Footer line number must be set as an integer.
      throw new IOException(nfe);
    }
    return footerCount;
  }
Get footer line count for a table.

@param table
         Table description for target table.

@param job
         Job configuration for current job.
ql/src/java/org/apache/hadoop/hive/ql/exec/Utilities.java