Uploaded image for project: 'NetarchiveSuite'
  1. NetarchiveSuite
  2. NAS-1720 Enable WARC file writing and handling in the NetarchiveSuite
  3. NAS-1963

Extend Bitarchive code, so WARC-records can be retrieved from archive

    XMLWordPrintable

Details

    • Rough

    Description

      The class dk.netarkivet.common.distribute.arcrepository.BitarchiveRecord only supports ARCRecords. Maybe just add another BitarchiveRecord constructer to support WARCRecords:

      public BitarchiveRecord(WARCRecord record) {
              ArgumentNotValid.checkNotNull(record, "WARCRecord record");
              //fileName = record.getMetaData().getArcFile().getName();
              offset = record.getHeader().getOffset();
              length = record.getHeader().getLength();
              fileName = (String) record.getHeader().getHeaderValue(WARCRecord.HEADER_KEY_FILENAME);
              ....
          }
      

      The same class also uses method ARCUtils.readARCRecord(ARCRecord ar), and we may also need such a method for reading WarcRecords?

      public static byte[] readWARCRecord(WARCRecord in) throws IOException {..}
      

      The method dk.netarkivet.archive.bitarchive.Bitarchive.get(String arcfile, long index) needs to work for WARC-files as well as ARC-files.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              mss Mikis Seth Sørensen (Inactive)
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 49h
                  49h
                  Remaining:
                  Remaining Estimate - 49h
                  49h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified