Skip to content

armgit / nutch

Public Imported from GitHub
0

Apache Nutch is an extensible and scalable web crawler

Also set file.content.limit.

YossiTamari968fc7ec01f8
diff --git a/src/java/org/apache/nutch/util/SitemapProcessor.java b/src/java/org/apache/nutch/util/SitemapProcessor.java
index 0fa797d0e..f558c469d 100644
--- a/src/java/org/apache/nutch/util/SitemapProcessor.java
+++ b/src/java/org/apache/nutch/util/SitemapProcessor.java
@@ -108,7 +108,9 @@ public class SitemapProcessor extends Configured implements Tool {
public void setup(Context context) {
Configuration conf = context.getConfiguration();
- conf.setInt("http.content.limit", conf.getInt(SITEMAP_SIZE_MAX, SiteMapParser.MAX_BYTES_ALLOWED));
+ int maxSize = conf.getInt(SITEMAP_SIZE_MAX, SiteMapParser.MAX_BYTES_ALLOWED);
+ conf.setInt("http.content.limit", maxSize);
+ conf.setInt("file.content.limit", maxSize);
this.protocolFactory = new ProtocolFactory(conf);
this.filter = conf.getBoolean(SITEMAP_URL_FILTERING, true);
this.normalize = conf.getBoolean(SITEMAP_URL_NORMALIZING, true);