Attachment 'deduplicator-0.3.0-20061218-patch-local-dateformat.patch'

Download

   1 diff -Naur deduplicator-0.3.0-20061218/src/main/java/is/hi/bok/deduplicator/CrawlDataItem.java deduplicator-0.3.0-20061218-patch-local-dateformat/src/main/java/is/hi/bok/deduplicator/CrawlDataItem.java
   2 --- deduplicator-0.3.0-20061218/src/main/java/is/hi/bok/deduplicator/CrawlDataItem.java	2006-12-18 08:38:04.000000000 +0100
   3 +++ deduplicator-0.3.0-20061218-patch-local-dateformat/src/main/java/is/hi/bok/deduplicator/CrawlDataItem.java	2008-05-22 17:05:02.000000000 +0200
   4 @@ -31,13 +31,6 @@
   5   * @author Kristinn Sigurðsson
   6   */
   7  public class CrawlDataItem {
   8 -    
   9 -    /**
  10 -     * The proper formating of {@link #setURL(String)} and {@link #getURL()}
  11 -     */
  12 -    public static final SimpleDateFormat dateFormat = 
  13 -        new SimpleDateFormat("yyyyMMddHHmmssSSS");
  14 -    
  15      protected String URL;
  16      protected String contentDigest;
  17      protected String timestamp;
  18 diff -Naur deduplicator-0.3.0-20061218/src/main/java/is/hi/bok/deduplicator/CrawlLogIterator.java deduplicator-0.3.0-20061218-patch-local-dateformat/src/main/java/is/hi/bok/deduplicator/CrawlLogIterator.java
  19 --- deduplicator-0.3.0-20061218/src/main/java/is/hi/bok/deduplicator/CrawlLogIterator.java	2006-12-18 08:36:02.000000000 +0100
  20 +++ deduplicator-0.3.0-20061218-patch-local-dateformat/src/main/java/is/hi/bok/deduplicator/CrawlLogIterator.java	2008-05-22 17:04:56.000000000 +0200
  21 @@ -40,8 +40,10 @@
  22   */
  23  public class CrawlLogIterator extends CrawlDataIterator {
  24  
  25 -    protected static final SimpleDateFormat crawlDateFormat = 
  26 +    protected final SimpleDateFormat crawlDateFormat = 
  27          new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
  28 +    protected final SimpleDateFormat crawlItemDateFormat =
  29 +	new SimpleDateFormat("yyyyMMddHHmmssSSS");
  30  
  31      /** 
  32       * A reader for the crawl.log file being processed
  33 @@ -53,8 +55,7 @@
  34       * has not been prepared or there are no more elements 
  35       */
  36      protected CrawlDataItem next;
  37 -    
  38 -    
  39 +        
  40      /** 
  41       * Create a new CrawlLogIterator that reads items from a Heritrix crawl.log
  42       *
  43 @@ -146,7 +147,7 @@
  44              try {
  45                  // Convert from crawl.log format to the format specified by
  46                  // CrawlDataItem
  47 -                timestamp = CrawlDataItem.dateFormat.format(
  48 +                timestamp = crawlItemDateFormat.format(
  49                          crawlDateFormat.parse(lineParts[0]));
  50              } catch (ParseException e) {
  51                  System.err.println("Error parsing date for: " + line);

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2008-05-26 11:44:45, 2621.4 KB) [[attachment:deduplicator-0.3.0-20061218-patch-heritrix-1.12.1b.patch]]
  • [get | view] (2008-05-26 11:44:23, 0.7 KB) [[attachment:deduplicator-0.3.0-20061218-patch-index-NPE.patch]]
  • [get | view] (2008-05-26 11:44:30, 2.5 KB) [[attachment:deduplicator-0.3.0-20061218-patch-local-dateformat.patch]]
  • [get | view] (2008-05-27 08:54:28, 235.4 KB) [[attachment:deduplicator-0.3.0-20061218-patch-lucene-OutOfMemory-2.patch]]
  • [get | view] (2008-05-26 11:44:14, 24.0 KB) [[attachment:deduplicator-0.3.0-20061218-patch-lucene-OutOfMemory.patch]]
  • [get | view] (2008-05-26 11:44:38, 2648.3 KB) [[attachment:deduplicator-0.3.0-20061218-patched-20080522-cumulative.patch]]
  • [get | view] (2008-05-26 11:45:11, 0.9 KB) [[attachment:deduplicator-0.3.0-20061218-patched-20080522.patch]]
  • [get | view] (2008-05-27 08:54:35, 2859.6 KB) [[attachment:deduplicator-0.3.0-20061218-patched-20080527-cumulative.patch]]
  • [get | view] (2008-05-27 08:55:25, 0.9 KB) [[attachment:deduplicator-0.3.0-20061218-patched-20080527.patch]]
  • [get | view] (2008-05-26 11:43:51, 1929.8 KB) [[attachment:deduplicator-0.3.0-20061218-src.zip]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.