public int getContentLength() {
      String lengthStr = fields.get("Content-Length");
      if (lengthStr == null) {
        throw new IllegalStateException("Missing Content-Length header");
      }
      try {
        return Integer.parseInt(lengthStr);
      } catch (NumberFormatException e) {
        throw new IllegalStateException("Malformed Content-Length header: " + lengthStr);
      }
    }
The number of bytes in the body of the record, similar to RFC2616.
@return The record's `Content-Length` header field, parsed into an int.
hbase-it/src/test/java/org/apache/hadoop/hbase/test/util/warc/WARCRecord.java