Skip to content

armgit / nutch

Public Imported from GitHub
0

Apache Nutch is an extensible and scalable web crawler

NUTCH-3215 Remove trailing whitespace reported by Yetus blanks on master (#971)

Lewis John McGibbney9257e52c3bbd
diff --git a/.yetus/blanks-eol.txt b/.yetus/blanks-eol.txt
index fed8fe9e3..ef4329d6e 100644
--- a/.yetus/blanks-eol.txt
+++ b/.yetus/blanks-eol.txt
@@ -2,3 +2,10 @@
# See --blanks-eol-ignore-file in the blanks plugin.
^out/
CHANGES.md
+# Bundled third-party license/notice text (same set as .yetus/excludes.txt).
+^licenses-binary/
+^NOTICE-binary$
+# Language-identifier test corpora and other non-source fixtures.
+^src/plugin/language-identifier/src/test/
+^src/plugin/parse-js/sample/
+^conf/naivebayes-train\.txt\.template$
diff --git a/conf/parse-plugins.xml.template b/conf/parse-plugins.xml.template
index cd8105344..f085084d9 100644
--- a/conf/parse-plugins.xml.template
+++ b/conf/parse-plugins.xml.template
@@ -15,19 +15,19 @@
See the License for the specific language governing permissions and
limitations under the License.
- Author : mattmann
- Description: This xml file represents a natural ordering for which parsing
- plugin should get called for a particular mimeType.
+ Author : mattmann
+ Description: This xml file represents a natural ordering for which parsing
+ plugin should get called for a particular mimeType.
-->
<parse-plugins>
- <!-- by default if the mimeType is set to *, or
+ <!-- by default if the mimeType is set to *, or
if it can't be determined, use parse-tika -->
<mimeType name="*">
<plugin id="parse-tika" />
</mimeType>
-
+
<mimeType name="application/rss+xml">
<plugin id="parse-tika" />
<plugin id="feed" />
@@ -78,10 +78,10 @@
<plugin id="parse-ext" />
</mimeType>
- <!-- alias mappings for parse-xxx names to the actual extension implementation
+ <!-- alias mappings for parse-xxx names to the actual extension implementation
ids described in each plugin's plugin.xml file -->
<aliases>
- <alias name="parse-tika"
+ <alias name="parse-tika"
extension-id="org.apache.nutch.parse.tika.TikaParser" />
<alias name="parse-ext" extension-id="ExtParser" />
<alias name="parse-html"
diff --git a/conf/regex-normalize.xml.template b/conf/regex-normalize.xml.template
index ed3f7108a..65f43f62b 100644
--- a/conf/regex-normalize.xml.template
+++ b/conf/regex-normalize.xml.template
@@ -24,7 +24,7 @@
<!-- WATCH OUT: an xml parser reads this file an ampersands must be
expanded to &amp; -->
-<!-- The following rules show how to strip out session IDs, default pages,
+<!-- The following rules show how to strip out session IDs, default pages,
interpage anchors, etc. Order does matter! -->
<regex-normalize>
diff --git a/default.properties b/default.properties
index b1d96aef6..702916d87 100644
--- a/default.properties
+++ b/default.properties
@@ -147,7 +147,7 @@ plugins.scoring=\
org.apache.nutch.scoring.similarity*:\
org.apache.nutch.scoring.urlmeta*\
org.apache.nutch.scoring.metadata*
-
+
#
# Parse Plugins
#
@@ -159,7 +159,7 @@ plugins.parse=\
org.apache.nutch.parse.replace*:\
org.apache.nutch.parse.tika:\
org.apache.nutch.parse.zip
-
+
#
# Parse Filter Plugins
#
@@ -226,4 +226,4 @@ plugins.misc=\
org.apache.nutch.collection*:\
org.apache.nutch.analysis.lang*:\
org.creativecommons.nutch*:\
- org.apache.nutch.microformats.reltag*:
+ org.apache.nutch.microformats.reltag*:
diff --git a/ivy/ivysettings.xml b/ivy/ivysettings.xml
index 91de33c45..3f36c6353 100644
--- a/ivy/ivysettings.xml
+++ b/ivy/ivysettings.xml
@@ -16,8 +16,8 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
- <property name="oss.sonatype.org"
- value="https://oss.sonatype.org/content/repositories/releases/"
+ <property name="oss.sonatype.org"
+ value="https://oss.sonatype.org/content/repositories/releases/"
override="false"/>
<property name="repo.maven.org"
value="https://repo1.maven.org/maven2/"
@@ -47,9 +47,9 @@
/>
<ibiblio name="apache-snapshot"
root="${repository.apache.org}"
- m2compatible="true"
+ m2compatible="true"
changingMatcher="regexp"
- changingPattern=".*SNAPSHOT.*"
+ changingPattern=".*SNAPSHOT.*"
checkmodified="true"
/>
<ibiblio name="sonatype"
diff --git a/ivy/mvn.template b/ivy/mvn.template
index d117c233b..f4653f739 100644
--- a/ivy/mvn.template
+++ b/ivy/mvn.template
@@ -46,10 +46,10 @@
</scm>
<pluginRepositories>
- <pluginRepository>
- <id>maven2</id>
- <url>https://repo.maven.apache.org/maven2/</url>
- </pluginRepository>
+ <pluginRepository>
+ <id>maven2</id>
+ <url>https://repo.maven.apache.org/maven2/</url>
+ </pluginRepository>
</pluginRepositories>
<developers>
@@ -90,7 +90,7 @@
</developer>
<developer>
<id>tejasp</id>
- <name>Tejas Patil</name>
+ <name>Tejas Patil</name>
<email>[email protected]</email>
</developer>
<developer>
diff --git a/src/bin/nutch b/src/bin/nutch
index 00fca5aa4..63dcc2cb5 100755
--- a/src/bin/nutch
+++ b/src/bin/nutch
@@ -14,14 +14,14 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
-#
+#
# The Nutch command script
#
# Environment Variables (local mode only)
#
# NUTCH_JAVA_HOME The java implementation to use. Overrides JAVA_HOME.
#
-# NUTCH_HEAPSIZE The maximum amount of heap to use, in MB.
+# NUTCH_HEAPSIZE The maximum amount of heap to use, in MB.
# Default is 4096.
#
# NUTCH_OPTS Extra Java runtime options.
@@ -139,7 +139,7 @@ if [ "$NUTCH_JAVA_HOME" != "" ]; then
#echo "run java in $NUTCH_JAVA_HOME"
JAVA_HOME="$NUTCH_JAVA_HOME"
fi
-
+
if [ "$JAVA_HOME" = "" ]; then
echo "Error: JAVA_HOME is not set."
exit 1
@@ -195,7 +195,7 @@ if $cygwin; then
fi
# setup 'java.library.path' for native-hadoop code if necessary
-# used only in local mode
+# used only in local mode
JAVA_LIBRARY_PATH=''
if [ -d "${NUTCH_HOME}/lib/native" ]; then
JAVA_PLATFORM=`"${JAVA}" -classpath "$CLASSPATH" org.apache.hadoop.util.PlatformName | sed -e 's/ /_/g' -e 's/\r//g'`
@@ -290,7 +290,7 @@ elif [ "$COMMAND" = "normalizerchecker" ] ; then
CLASS=org.apache.nutch.net.URLNormalizerChecker
elif [ "$COMMAND" = "robotsparser" ] ; then
CLASS=org.apache.nutch.protocol.RobotRulesParser
-elif [ "$COMMAND" = "domainstats" ] ; then
+elif [ "$COMMAND" = "domainstats" ] ; then
CLASS=org.apache.nutch.util.DomainStatistics
elif [ "$COMMAND" = "protocolstats" ] ; then
CLASS=org.apache.nutch.util.ProtocolStatusStatistics
diff --git a/src/java/org/apache/nutch/crawl/AbstractFetchSchedule.java b/src/java/org/apache/nutch/crawl/AbstractFetchSchedule.java
index 2c825d992..f3ad7ffc5 100644
--- a/src/java/org/apache/nutch/crawl/AbstractFetchSchedule.java
+++ b/src/java/org/apache/nutch/crawl/AbstractFetchSchedule.java
@@ -27,7 +27,7 @@ import java.lang.invoke.MethodHandles;
/**
* This class provides common methods for implementations of
* <code>FetchSchedule</code>.
- *
+ *
*/
public abstract class AbstractFetchSchedule extends Configured implements
FetchSchedule {
@@ -61,10 +61,10 @@ public abstract class AbstractFetchSchedule extends Configured implements
* the <code>fetchTime</code> and <code>fetchInterval</code>. The default
* implementation sets the <code>fetchTime</code> to now, using the default
* <code>fetchInterval</code>.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance to be initialized (modified in place).
*/
@@ -94,13 +94,13 @@ public abstract class AbstractFetchSchedule extends Configured implements
* This method specifies how to schedule refetching of pages marked as GONE.
* Default implementation increases fetchInterval by 50% but the value may
* never exceed <code>maxInterval</code>.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance to be adjusted.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
@@ -123,22 +123,22 @@ public abstract class AbstractFetchSchedule extends Configured implements
* This method adjusts the fetch schedule if fetching needs to be re-tried due
* to transient errors. The default implementation sets the next fetch time 1
* day in the future and increases the retry counter.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* page information.
- *
+ *
* @param prevFetchTime
* previous fetch time.
- *
+ *
* @param prevModifiedTime
* previous modified time.
- *
+ *
* @param fetchTime
* current fetch time.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
@@ -154,7 +154,7 @@ public abstract class AbstractFetchSchedule extends Configured implements
/**
* This method return the last fetch time of the CrawlDatum
- *
+ *
* @return the date as a long.
*/
@Override
@@ -175,17 +175,17 @@ public abstract class AbstractFetchSchedule extends Configured implements
* returns false, and true otherwise. It will also check that fetchTime is not
* too remote (more than <code>maxInterval</code>, in which case it lowers the
* interval and returns true.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance.
- *
+ *
* @param curTime
* reference time (usually set to the time when the fetchlist
* generation process was started).
- *
+ *
* @return true, if the page should be considered for inclusion in the current
* fetchlist, otherwise false.
*/
@@ -209,13 +209,13 @@ public abstract class AbstractFetchSchedule extends Configured implements
/**
* This method resets fetchTime, fetchInterval, modifiedTime,
* retriesSinceFetch and page signature, so that it forces refetching.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance.
- *
+ *
* @param asap
* if true, force refetch as soon as possible - this sets the
* fetchTime to now. If false, force refetch whenever the next fetch
diff --git a/src/java/org/apache/nutch/crawl/CrawlDatum.java b/src/java/org/apache/nutch/crawl/CrawlDatum.java
index c8f798ffe..e23accbf6 100644
--- a/src/java/org/apache/nutch/crawl/CrawlDatum.java
+++ b/src/java/org/apache/nutch/crawl/CrawlDatum.java
@@ -204,8 +204,8 @@ public class CrawlDatum implements WritableComparable<CrawlDatum>, Cloneable {
/**
* Get the fetch time.
- * @return long value indicating either the time of the last
- * fetch, or the next fetch time, depending on whether Fetcher
+ * @return long value indicating either the time of the last
+ * fetch, or the next fetch time, depending on whether Fetcher
* or CrawlDbReducer set the time.
*/
public long getFetchTime() {
@@ -274,7 +274,7 @@ public class CrawlDatum implements WritableComparable<CrawlDatum>, Cloneable {
/**
* Add all metadata from other CrawlDatum to this CrawlDatum.
- *
+ *
* @param other
* CrawlDatum
*/
@@ -569,12 +569,12 @@ public class CrawlDatum implements WritableComparable<CrawlDatum>, Cloneable {
throw new RuntimeException(e);
}
}
-
+
public boolean execute(JexlScript expr, String url) {
if (expr != null && url != null) {
// Create a context and add data
JexlContext jcontext = new MapContext();
-
+
// https://issues.apache.org/jira/browse/NUTCH-2229
jcontext.set("url", url);
jcontext.set("status", getStatusName(getStatus()));
@@ -584,34 +584,34 @@ public class CrawlDatum implements WritableComparable<CrawlDatum>, Cloneable {
jcontext.set("interval", Integer.valueOf(getFetchInterval()));
jcontext.set("score", getScore());
jcontext.set("signature", StringUtil.toHexString(getSignature()));
-
+
// Set metadata variables
for (Map.Entry<Writable, Writable> entry : getMetaData().entrySet()) {
Object value = entry.getValue();
Text tkey = (Text)entry.getKey();
-
+
if (value instanceof FloatWritable) {
FloatWritable fvalue = (FloatWritable)value;
jcontext.set(tkey.toString(), fvalue.get());
}
-
+
if (value instanceof IntWritable) {
IntWritable ivalue = (IntWritable)value;
jcontext.set(tkey.toString(), ivalue.get());
}
-
+
if (value instanceof Text) {
Text tvalue = (Text)value;
jcontext.set(tkey.toString().replace("-", "_"), tvalue.toString());
}
-
+
if (value instanceof ProtocolStatus) {
ProtocolStatus pvalue = (ProtocolStatus)value;
jcontext.set(tkey.toString().replace("-", "_"), pvalue.toString());
}
}
-
+
try {
if (Boolean.TRUE.equals(expr.execute(jcontext))) {
return true;
diff --git a/src/java/org/apache/nutch/crawl/CrawlDb.java b/src/java/org/apache/nutch/crawl/CrawlDb.java
index 386a1b5c9..e27fba673 100644
--- a/src/java/org/apache/nutch/crawl/CrawlDb.java
+++ b/src/java/org/apache/nutch/crawl/CrawlDb.java
@@ -299,13 +299,13 @@ public class CrawlDb extends NutchTool implements Tool {
if (args.containsKey("normalize")) {
normalize = true;
- }
+ }
if (args.containsKey("filter")) {
filter = true;
- }
+ }
if (args.containsKey("force")) {
force = true;
- }
+ }
if (args.containsKey("noAdditions")) {
additionsAllowed = false;
}
@@ -347,7 +347,7 @@ public class CrawlDb extends NutchTool implements Tool {
else if(segments instanceof Path){
segmentList.add(segments.toString());
}
-
+
for(String segment: segmentList) {
dirs.add(new Path(segment));
}
@@ -355,7 +355,7 @@ public class CrawlDb extends NutchTool implements Tool {
else {
String segmentDir = crawlId+"/segments";
File dir = new File(segmentDir);
- File[] segmentsList = dir.listFiles();
+ File[] segmentsList = dir.listFiles();
Arrays.sort(segmentsList, (f1, f2) -> {
if(f1.lastModified()>f2.lastModified())
return -1;
diff --git a/src/java/org/apache/nutch/crawl/CrawlDbFilter.java b/src/java/org/apache/nutch/crawl/CrawlDbFilter.java
index 666fcbdf6..d9361207a 100644
--- a/src/java/org/apache/nutch/crawl/CrawlDbFilter.java
+++ b/src/java/org/apache/nutch/crawl/CrawlDbFilter.java
@@ -35,7 +35,7 @@ import org.apache.nutch.net.URLNormalizers;
/**
* This class provides a way to separate the URL normalization and filtering
* steps from the rest of CrawlDb manipulation code.
- *
+ *
*/
public class CrawlDbFilter extends
Mapper<Text, CrawlDatum, Text, CrawlDatum> {
@@ -78,7 +78,7 @@ public class CrawlDbFilter extends
scope = conf.get(URL_NORMALIZING_SCOPE, URLNormalizers.SCOPE_CRAWLDB);
normalizers = new URLNormalizers(conf, scope);
}
-
+
// Initialize cached counter references
initCounters(context);
diff --git a/src/java/org/apache/nutch/crawl/CrawlDbMerger.java b/src/java/org/apache/nutch/crawl/CrawlDbMerger.java
index 555a2ceaa..3db5033c6 100644
--- a/src/java/org/apache/nutch/crawl/CrawlDbMerger.java
+++ b/src/java/org/apache/nutch/crawl/CrawlDbMerger.java
@@ -48,7 +48,7 @@ import org.apache.nutch.util.NutchJob;
/**
* This tool merges several CrawlDb-s into one, optionally filtering URLs
* through the current URLFilters, to skip prohibited pages.
- *
+ *
* <p>
* It's possible to use this tool just for filtering - in that case only one
* CrawlDb should be specified in arguments.
@@ -59,7 +59,7 @@ import org.apache.nutch.util.NutchJob;
* {@link org.apache.nutch.crawl.CrawlDatum#getFetchTime()}. However, all
* metadata information from all versions is accumulated, with newer values
* taking precedence over older values.
- *
+ *
*/
public class CrawlDbMerger extends Configured implements Tool {
private static final Logger LOG = LoggerFactory
@@ -100,11 +100,11 @@ public class CrawlDbMerger extends Configured implements Tool {
context.write(key, res);
}
- // Determine which CrawlDatum is the latest, according to calculateLastFetchTime()
+ // Determine which CrawlDatum is the latest, according to calculateLastFetchTime()
// and getFetchTime() as fallback in case calculateLastFetchTime()s are equal (eg: DB_UNFETCHED)
private boolean isNewer(CrawlDatum cd1, CrawlDatum cd2) {
- return schedule.calculateLastFetchTime(cd2) > schedule.calculateLastFetchTime(cd1)
- || schedule.calculateLastFetchTime(cd2) == schedule.calculateLastFetchTime(cd1)
+ return schedule.calculateLastFetchTime(cd2) > schedule.calculateLastFetchTime(cd1)
+ || schedule.calculateLastFetchTime(cd2) == schedule.calculateLastFetchTime(cd1)
&& cd2.getFetchTime() > cd1.getFetchTime();
}
diff --git a/src/java/org/apache/nutch/crawl/DefaultFetchSchedule.java b/src/java/org/apache/nutch/crawl/DefaultFetchSchedule.java
index 7012cd105..e0e1ac12d 100644
--- a/src/java/org/apache/nutch/crawl/DefaultFetchSchedule.java
+++ b/src/java/org/apache/nutch/crawl/DefaultFetchSchedule.java
@@ -23,7 +23,7 @@ import org.apache.hadoop.io.Text;
* the page was changed or not, the <code>fetchInterval</code> remains
* unchanged, and the updated page fetchTime will always be set to
* <code>fetchTime + fetchInterval * 1000</code>.
- *
+ *
*/
public class DefaultFetchSchedule extends AbstractFetchSchedule {
diff --git a/src/java/org/apache/nutch/crawl/FetchSchedule.java b/src/java/org/apache/nutch/crawl/FetchSchedule.java
index b9708a3a2..44850d463 100644
--- a/src/java/org/apache/nutch/crawl/FetchSchedule.java
+++ b/src/java/org/apache/nutch/crawl/FetchSchedule.java
@@ -22,7 +22,7 @@ import org.apache.hadoop.io.Text;
/**
* This interface defines the contract for implementations that manipulate fetch
* times and re-fetch intervals.
- *
+ *
*/
public interface FetchSchedule extends Configurable {
@@ -40,13 +40,13 @@ public interface FetchSchedule extends Configurable {
* the <code>fetchTime</code> and <code>fetchInterval</code>. The default
* implementation set the <code>fetchTime</code> to now, using the default
* <code>fetchInterval</code>.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance to be initialized.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
@@ -58,31 +58,31 @@ public interface FetchSchedule extends Configurable {
* Sets the <code>fetchInterval</code> and <code>fetchTime</code> on a
* successfully fetched page. Implementations may use supplied arguments to
* support different re-fetching schedules.
- *
+ *
* @param url
* url of the page
- *
+ *
* @param datum
* page description to be adjusted. NOTE: this instance, passed by
* reference, may be modified inside the method.
- *
+ *
* @param prevFetchTime
* previous value of fetch time, or 0 if not available.
- *
+ *
* @param prevModifiedTime
* previous value of modifiedTime, or 0 if not available.
- *
+ *
* @param fetchTime
* the latest time, when the page was recently re-fetched. Most
* FetchSchedule implementations should update the value in @see
* CrawlDatum to something greater than this value.
- *
+ *
* @param modifiedTime
* last time the content was modified. This information comes from
* the protocol implementations, or is set to &lt; 0 if not available.
* Most FetchSchedule implementations should update the value in @see
* CrawlDatum to this value.
- *
+ *
* @param state
* if {@link #STATUS_MODIFIED}, then the content is considered to be
* "changed" before the <code>fetchTime</code>, if
@@ -92,7 +92,7 @@ public interface FetchSchedule extends Configurable {
* {@link #STATUS_UNKNOWN}, then it is unknown whether the page was
* changed; implementations are free to follow a sensible default
* behavior.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
@@ -107,10 +107,10 @@ public interface FetchSchedule extends Configurable {
* Default implementation increases fetchInterval by 50%, and if it exceeds
* the <code>maxInterval</code> it calls
* {@link #forceRefetch(Text, CrawlDatum, boolean)}.
- *
+ *
* @param url
* URL of the page
- *
+ *
* @param datum
* datum instance to be adjusted.
* @param prevFetchTime previous fetch time.
@@ -128,22 +128,22 @@ public interface FetchSchedule extends Configurable {
* This method adjusts the fetch schedule if fetching needs to be re-tried due
* to transient errors. The default implementation sets the next fetch time 1
* day in the future and increases the retry counter.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* page information.
- *
+ *
* @param prevFetchTime
* previous fetch time.
- *
+ *
* @param prevModifiedTime
* previous modified time.
- *
+ *
* @param fetchTime
* current fetch time.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
@@ -168,17 +168,17 @@ public interface FetchSchedule extends Configurable {
* and true otherwise. It will also check that fetchTime is not too remote
* (more than <code>maxInterval</code>), in which case it lowers the interval
* and returns true.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance.
- *
+ *
* @param curTime
* reference time (usually set to the time when the fetchlist
* generation process was started).
- *
+ *
* @return true, if the page should be considered for inclusion in the current
* fetchlist, otherwise false.
*/
@@ -187,18 +187,18 @@ public interface FetchSchedule extends Configurable {
/**
* This method resets fetchTime, fetchInterval, modifiedTime and page
* signature, so that it forces refetching.
- *
+ *
* @param url
* URL of the page.
- *
+ *
* @param datum
* datum instance.
- *
+ *
* @param asap
* if true, force refetch as soon as possible - this sets the
* fetchTime to now. If false, force refetch whenever the next fetch
* time is set.
- *
+ *
* @return adjusted page information, including all original information.
* NOTE: this may be a different instance than @see CrawlDatum, but
* implementations should make sure that it contains at least all
diff --git a/src/java/org/apache/nutch/crawl/Injector.java b/src/java/org/apache/nutch/crawl/Injector.java
index ae5218369..f04c2783e 100644
--- a/src/java/org/apache/nutch/crawl/Injector.java
+++ b/src/java/org/apache/nutch/crawl/Injector.java
@@ -77,7 +77,7 @@ import java.util.concurrent.TimeUnit;
* </dl>
* <p>
* Example:
- *
+ *
* <pre>
* http://www.nutch.org/ \t nutch.score=10 \t nutch.fetchInterval=2592000 \t userType=open_source
* </pre>
@@ -318,7 +318,7 @@ public class Injector extends NutchTool implements Tool {
update = conf.getBoolean("db.injector.update", false);
LOG.info("Injector: overwrite: {}", overwrite);
LOG.info("Injector: update: {}", update);
-
+
// Initialize cached counter references
initCounters(context);
}
@@ -335,7 +335,7 @@ public class Injector extends NutchTool implements Tool {
/**
* Merge the input records of one URL as per rules below :
- *
+ *
* <pre>
* 1. If there is ONLY new injected record ==&gt; emit injected record
* 2. If there is ONLY old record ==&gt; emit existing record
@@ -345,7 +345,7 @@ public class Injector extends NutchTool implements Tool {
* (i) If 'update' is false ==&gt; emit existing record
* (ii) If 'update' is true ==&gt; update existing record and emit it
* </pre>
- *
+ *
* For more details @see NUTCH-1405
*/
@Override
diff --git a/src/java/org/apache/nutch/crawl/Inlinks.java b/src/java/org/apache/nutch/crawl/Inlinks.java
index 55163758b..871ef8a98 100644
--- a/src/java/org/apache/nutch/crawl/Inlinks.java
+++ b/src/java/org/apache/nutch/crawl/Inlinks.java
@@ -87,7 +87,7 @@ public class Inlinks implements Writable {
/**
* Get all anchor texts. Only a single anchor with a given text is
* permitted from a given domain.
- * @return the set of anchor texts.
+ * @return the set of anchor texts.
*/
public String[] getAnchors() {
HashMap<String, Set<String>> domainToAnchors = new HashMap<>();
diff --git a/src/java/org/apache/nutch/crawl/LinkDbFilter.java b/src/java/org/apache/nutch/crawl/LinkDbFilter.java
index d58d34e9d..b8c78fa51 100644
--- a/src/java/org/apache/nutch/crawl/LinkDbFilter.java
+++ b/src/java/org/apache/nutch/crawl/LinkDbFilter.java
@@ -31,7 +31,7 @@ import org.apache.nutch.net.URLNormalizers;
/**
* This class provides a way to separate the URL normalization and filtering
* steps from the rest of LinkDb manipulation code.
- *
+ *
*/
public class LinkDbFilter extends Mapper<Text, Inlinks, Text, Inlinks> {
public static final String URL_FILTERING = "linkdb.url.filters";
diff --git a/src/java/org/apache/nutch/crawl/LinkDbMerger.java b/src/java/org/apache/nutch/crawl/LinkDbMerger.java
index e02a5555f..6130d8d6f 100644
--- a/src/java/org/apache/nutch/crawl/LinkDbMerger.java
+++ b/src/java/org/apache/nutch/crawl/LinkDbMerger.java
@@ -46,7 +46,7 @@ import org.apache.nutch.util.NutchJob;
/**
* This tool merges several LinkDb-s into one, optionally filtering URLs through
* the current URLFilters, to skip prohibited URLs and links.
- *
+ *
* <p>
* It's possible to use this tool just for filtering - in that case only one
* LinkDb should be specified in arguments.
@@ -62,7 +62,7 @@ import org.apache.nutch.util.NutchJob;
* will be removed, including the target URL. If some of incoming links are
* prohibited, only they will be removed, and they won't count when checking the
* above-mentioned maximum limit.
- *
+ *
*/
public class LinkDbMerger extends Configured implements Tool {
private static final Logger LOG = LoggerFactory
@@ -76,7 +76,7 @@ public class LinkDbMerger extends Configured implements Tool {
setConf(conf);
}
- public static class LinkDbMergeReducer extends
+ public static class LinkDbMergeReducer extends
Reducer<Text, Inlinks, Text, Inlinks> {
private int maxInlinks;
diff --git a/src/java/org/apache/nutch/crawl/LinkDbReader.java b/src/java/org/apache/nutch/crawl/LinkDbReader.java
index 897aa1aca..2779377fe 100644
--- a/src/java/org/apache/nutch/crawl/LinkDbReader.java
+++ b/src/java/org/apache/nutch/crawl/LinkDbReader.java
@@ -122,11 +122,11 @@ public class LinkDbReader extends AbstractChecker implements Closeable {
}
}
}
-
+
public static class LinkDBDumpMapper extends Mapper<Text, Inlinks, Text, Inlinks> {
Pattern pattern = null;
Matcher matcher = null;
-
+
@Override
public void setup(Mapper<Text, Inlinks, Text, Inlinks>.Context context) {
Configuration conf = context.getConfiguration();
@@ -150,7 +150,7 @@ public class LinkDbReader extends AbstractChecker implements Closeable {
}
}
- public void processDumpJob(String linkdb, String output, String regex)
+ public void processDumpJob(String linkdb, String output, String regex)
throws IOException, InterruptedException, ClassNotFoundException {
StopWatch stopWatch = new StopWatch();
stopWatch.start();
@@ -161,9 +161,9 @@ public class LinkDbReader extends AbstractChecker implements Closeable {
Job job = Job.getInstance(getConf(), "Nutch LinkDbReader: " + linkdb);
job.setJarByClass(LinkDbReader.class);
-
+
Configuration conf = job.getConfiguration();
-
+
if (regex != null) {
conf.set("linkdb.regex", regex);
job.setMapperClass(LinkDBDumpMapper.class);
diff --git a/src/java/org/apache/nutch/crawl/MimeAdaptiveFetchSchedule.java b/src/java/org/apache/nutch/crawl/MimeAdaptiveFetchSchedule.java
index 3b2c60d6a..f11fd6e7a 100644
--- a/src/java/org/apache/nutch/crawl/MimeAdaptiveFetchSchedule.java
+++ b/src/java/org/apache/nutch/crawl/MimeAdaptiveFetchSchedule.java
@@ -34,18 +34,18 @@ import org.slf4j.LoggerFactory;
/**
* Extension of @see AdaptiveFetchSchedule that allows for more flexible
* configuration of DEC and INC factors for various MIME-types.
- *
+ *
* This class can be typically used in cases where a recrawl consists of many
* different MIME-types. It's not very common for MIME-types other than
* text/html to change frequently. Using this class you can configure different
* factors per MIME-type so to prefer frequently changing MIME-types over
* others.
- *
+ *
* For it to work this class relies on the Content-Type MetaData key being
* present in the CrawlDB. This can either be done when injecting new URL's or
* by adding "Content-Type" to the db.parsemeta.to.crawldb configuration setting
* to force MIME-types of newly discovered URL's to be added to the CrawlDB.
- *
+ *
*/
public class MimeAdaptiveFetchSchedule extends AdaptiveFetchSchedule {
// Loggg
@@ -126,7 +126,7 @@ public class MimeAdaptiveFetchSchedule extends AdaptiveFetchSchedule {
/**
* Reads the mime types and their associated INC/DEC factors in a HashMap
- *
+ *
* @param mimeFile
* Reader
* @return void
diff --git a/src/java/org/apache/nutch/crawl/SignatureFactory.java b/src/java/org/apache/nutch/crawl/SignatureFactory.java
index 7f989b90c..34574afdd 100644
--- a/src/java/org/apache/nutch/crawl/SignatureFactory.java
+++ b/src/java/org/apache/nutch/crawl/SignatureFactory.java
@@ -29,7 +29,7 @@ import java.lang.invoke.MethodHandles;
* Factory class, which instantiates a Signature implementation according to the
* current Configuration configuration. This newly created instance is cached in
* the Configuration instance, so that it could be later retrieved.
- *
+ *
*/
public class SignatureFactory {
private static final Logger LOG = LoggerFactory
@@ -39,7 +39,7 @@ public class SignatureFactory {
} // no public constructor
/**
- * Return the {@link Signature} implementation for a given
+ * Return the {@link Signature} implementation for a given
* {@link Configuration}, or {@link MD5Signature} by default.
* @param conf a populated {@link Configuration}
* @return the {@link Signature} implementation
diff --git a/src/java/org/apache/nutch/fetcher/FetchItemQueue.java b/src/java/org/apache/nutch/fetcher/FetchItemQueue.java
index 77715b8b3..bcd57d191 100644
--- a/src/java/org/apache/nutch/fetcher/FetchItemQueue.java
+++ b/src/java/org/apache/nutch/fetcher/FetchItemQueue.java
@@ -53,11 +53,11 @@ public class FetchItemQueue {
int maxThreads;
Text cookie;
boolean variableFetchDelaySet = false;
- // keep track of duplicates if fetcher.follow.outlinks.depth > 0. Some urls may
+ // keep track of duplicates if fetcher.follow.outlinks.depth > 0. Some urls may
// not get followed due to hash collisions. Hashing is used to reduce memory
// usage.
Set<Integer> alreadyFetched;
-
+
public FetchItemQueue(Configuration conf, int maxThreads, long crawlDelay,
long minCrawlDelay) {
this.maxThreads = maxThreads;
@@ -107,7 +107,7 @@ public class FetchItemQueue {
minCrawlDelay = ((LongWritable)(it.datum.getMetaData().get(variableFetchDelayKey))).get();
setEndTime(System.currentTimeMillis() - crawlDelay);
}
-
+
// Remove it!
it.datum.getMetaData().remove(variableFetchDelayKey);
}
@@ -139,11 +139,11 @@ public class FetchItemQueue {
}
return it;
}
-
+
public void setCookie(Text cookie) {
this.cookie = cookie;
}
-
+
public Text getCookie() {
return cookie;
}
diff --git a/src/java/org/apache/nutch/fetcher/FetcherThreadEvent.java b/src/java/org/apache/nutch/fetcher/FetcherThreadEvent.java
index c5eeafc13..2d1d4b558 100644
--- a/src/java/org/apache/nutch/fetcher/FetcherThreadEvent.java
+++ b/src/java/org/apache/nutch/fetcher/FetcherThreadEvent.java
@@ -25,23 +25,23 @@ import java.util.Map;
import org.apache.nutch.parse.Outlink;
/**
- * This class is used to capture the various events occurring
- * at fetch time. These events are sent to a
+ * This class is used to capture the various events occurring
+ * at fetch time. These events are sent to a
* {@link org.apache.nutch.publisher.NutchPublisher} implementation.
*/
public class FetcherThreadEvent implements Serializable {
/** Type of event to specify start, end or reporting of a fetch item. **/
public static enum PublishEventType {START, END, REPORT}
-
+
private PublishEventType eventType;
private Map<String, Object> eventData;
- private String url;
- private Long timestamp;
-
+ private String url;
+ private Long timestamp;
+
/**
* Constructor to create an event to be published
- * @param eventType Type of {@link #eventType event} being created
+ * @param eventType Type of {@link #eventType event} being created
* @param url URL of the fetched page to which this event belongs to
*/
public FetcherThreadEvent(PublishEventType eventType, String url) {
@@ -49,7 +49,7 @@ public class FetcherThreadEvent implements Serializable {
this.url = url;
this.timestamp = System.currentTimeMillis();
}
-
+
/**
* Get type of this event object
* @return {@link PublishEventType Event} type
@@ -57,7 +57,7 @@ public class FetcherThreadEvent implements Serializable {
public PublishEventType getEventType() {
return eventType;
}
-
+
/**
* Set event type of this object
* @param eventType Set {@link #eventType event} type
@@ -65,7 +65,7 @@ public class FetcherThreadEvent implements Serializable {
public void setEventType(PublishEventType eventType) {
this.eventType = eventType;
}
-
+
/**
* Get event data
* @return a Map of event data
@@ -73,16 +73,16 @@ public class FetcherThreadEvent implements Serializable {
public Map<String, Object> getEventData() {
return eventData;
}
- /**
+ /**
* Set metadata to this even
- * @param eventData A map containing important information relevant
+ * @param eventData A map containing important information relevant
* to this event (fetched page).
* Exeample - score, title, outlinks, content-type, etc
*/
public void setEventData(Map<String, Object> eventData) {
this.eventData = eventData;
}
-
+
/**
* Get URL of this event
* @return {@link #url URL} of this event
@@ -90,7 +90,7 @@ public class FetcherThreadEvent implements Serializable {
public String getUrl() {
return url;
}
-
+
/**
* Set URL of this event (fetched page)
* @param url URL of the fetched page
@@ -99,7 +99,7 @@ public class FetcherThreadEvent implements Serializable {
this.url = url;
}
/**
- * Add new data to the eventData object.
+ * Add new data to the eventData object.
* @param key A key to refer to the data being added to this event
* @param value Data to be stored in the event referenced by the above key
*/
@@ -109,10 +109,10 @@ public class FetcherThreadEvent implements Serializable {
}
eventData.put(key, value);
}
-
+
/**
- * Given a collection of lists this method will add it
- * the oultink metadata
+ * Given a collection of lists this method will add it
+ * the oultink metadata
* @param links A collection of outlinks generating from the fetched page
* this event refers to
*/
@@ -126,15 +126,15 @@ public class FetcherThreadEvent implements Serializable {
}
this.addEventData("outlinks", outlinkList);
}
-
+
/**
- * Get timestamp of current event.
+ * Get timestamp of current event.
* @return {@link #timestamp Timestamp}
*/
public Long getTimestamp() {
return timestamp;
}
-
+
/**
* Set timestamp for this event
* @param timestamp Timestamp of the occurrence of this event
diff --git a/src/java/org/apache/nutch/fetcher/FetcherThreadPublisher.java b/src/java/org/apache/nutch/fetcher/FetcherThreadPublisher.java
index 8dd20117c..863c0c07f 100644
--- a/src/java/org/apache/nutch/fetcher/FetcherThreadPublisher.java
+++ b/src/java/org/apache/nutch/fetcher/FetcherThreadPublisher.java
@@ -24,7 +24,7 @@ import org.slf4j.LoggerFactory;
import java.lang.invoke.MethodHandles;
/**
- * This class handles the publishing of the events to the queue implementation.
+ * This class handles the publishing of the events to the queue implementation.
*
*/
public class FetcherThreadPublisher {
diff --git a/src/java/org/apache/nutch/hostdb/ReadHostDb.java b/src/java/org/apache/nutch/hostdb/ReadHostDb.java
index 23d94bc88..41dd20518 100644
--- a/src/java/org/apache/nutch/hostdb/ReadHostDb.java
+++ b/src/java/org/apache/nutch/hostdb/ReadHostDb.java
@@ -86,11 +86,11 @@ public class ReadHostDb extends Configured implements Tool {
context.write(new Text("hostname"), new Text("unfetched\tfetched\tgone\tredirTemp\tredirPerm\tnotModified\tnumRecords\tdnsFail\tcnxFail\tsumFail\tscore\tlastCheck\thomepage\tmetadata"));
fieldHeader = false;
}
-
+
if (expr != null) {
// Create a context and add data
JexlContext jcontext = new MapContext();
-
+
// Set some fixed variables
jcontext.set("unfetched", datum.getUnfetched());
jcontext.set("fetched", datum.getFetched());
@@ -103,7 +103,7 @@ public class ReadHostDb extends Configured implements Tool {
jcontext.set("numRecords", datum.numRecords());
jcontext.set("dnsFailures", datum.getDnsFailures());
jcontext.set("connectionFailures", datum.getConnectionFailures());
-
+
// Set metadata variables
if (datum.hasMetaData()) {
for (Map.Entry<Writable, Writable> entry : datum.getMetaData()
@@ -123,7 +123,7 @@ public class ReadHostDb extends Configured implements Tool {
}
}
}
-
+
// Filter this record if evaluation did not pass
try {
if (!Boolean.TRUE.equals(expr.execute(jcontext))) {
@@ -133,19 +133,19 @@ public class ReadHostDb extends Configured implements Tool {
LOG.info("{} for {}", e.toString(), key.toString());
}
}
-
+
if (dumpHomepages) {
if (datum.hasHomepageUrl()) {
context.write(new Text(datum.getHomepageUrl()), emptyText);
}
return;
}
-
+
if (dumpHostnames) {
context.write(key, emptyText);
return;
}
-
+
// Write anyway
context.write(key, new Text(datum.toString()));
}
@@ -174,7 +174,7 @@ public class ReadHostDb extends Configured implements Tool {
}
conf.setBoolean("mapreduce.fileoutputcommitter.marksuccessfuljobs", false);
conf.set("mapreduce.output.textoutputformat.separator", "\t");
-
+
Job job = Job.getInstance(conf, "Nutch ReadHostDb");
job.setJarByClass(ReadHostDb.class);
@@ -208,20 +208,20 @@ public class ReadHostDb extends Configured implements Tool {
LOG.info("ReadHostDb: finished, elapsed: {} ms", stopWatch.getTime(
TimeUnit.MILLISECONDS));
}
-
+
private void getHostDbRecord(Path hostDb, String host) throws Exception {
Configuration conf = getConf();
SequenceFile.Reader[] readers = SegmentReaderUtil.getReaders(hostDb, conf);
Class<?> keyClass = readers[0].getKeyClass();
Class<?> valueClass = readers[0].getValueClass();
-
+
if (!keyClass.getName().equals("org.apache.hadoop.io.Text"))
throw new IOException("Incompatible key (" + keyClass.getName() + ")");
-
+
Text key = (Text) keyClass.getConstructor().newInstance();
HostDatum value = (HostDatum) valueClass.getConstructor().newInstance();
-
+
for (int i = 0; i < readers.length; i++) {
while (readers[i].next(key, value)) {
if (host.equals(key.toString())) {
@@ -229,7 +229,7 @@ public class ReadHostDb extends Configured implements Tool {
}
}
readers[i].close();
- }
+ }
}
public static void main(String args[]) throws Exception {
diff --git a/src/java/org/apache/nutch/hostdb/ResolverThread.java b/src/java/org/apache/nutch/hostdb/ResolverThread.java
index e730992c5..fe89628e6 100644
--- a/src/java/org/apache/nutch/hostdb/ResolverThread.java
+++ b/src/java/org/apache/nutch/hostdb/ResolverThread.java
@@ -73,7 +73,7 @@ public class ResolverThread implements Runnable {
this.datum = datum;
this.context = context;
this.purgeFailedHostsThreshold = purgeFailedHostsThreshold;
-
+
// Initialize cached counters for performance
initCounters();
}
diff --git a/src/java/org/apache/nutch/hostdb/UpdateHostDb.java b/src/java/org/apache/nutch/hostdb/UpdateHostDb.java
index a3115c4f1..18d7879af 100644
--- a/src/java/org/apache/nutch/hostdb/UpdateHostDb.java
+++ b/src/java/org/apache/nutch/hostdb/UpdateHostDb.java
@@ -68,7 +68,7 @@ public class UpdateHostDb extends Configured implements Tool {
public static final String HOSTDB_PERCENTILES = "hostdb.percentiles";
public static final String HOSTDB_CRAWLDATUM_PROCESSORS = "hostdb.crawldatum.processors";
public static final String HOSTDB_URL_LIMIT = "hostdb.url.limit";
-
+
private void updateHostDb(Path hostDb, Path crawlDb, Path topHosts,
boolean checkFailed, boolean checkNew, boolean checkKnown,
boolean force, boolean filter, boolean normalize, long urlLimit) throws Exception {
@@ -128,7 +128,7 @@ public class UpdateHostDb extends Configured implements Tool {
conf.setBoolean(HOSTDB_URL_NORMALIZING, normalize);
conf.setLong(HOSTDB_URL_LIMIT, urlLimit);
conf.setClassLoader(Thread.currentThread().getContextClassLoader());
-
+
try {
boolean success = job.waitForCompletion(true);
if (!success) {
diff --git a/src/java/org/apache/nutch/hostdb/UpdateHostDbMapper.java b/src/java/org/apache/nutch/hostdb/UpdateHostDbMapper.java
index b1736348b..50699d7df 100644
--- a/src/java/org/apache/nutch/hostdb/UpdateHostDbMapper.java
+++ b/src/java/org/apache/nutch/hostdb/UpdateHostDbMapper.java
@@ -192,7 +192,7 @@ public class UpdateHostDbMapper
if (crawlDatum.getStatus() != CrawlDatum.STATUS_DB_UNFETCHED) {
// Get the protocol
String protocol = URLUtil.getProtocol(url);
-
+
// Check if the current key is equals the host
if (URLUtil.isHomePageOf(url, buffer)) {
// Check if this is a redirect to the real home page
diff --git a/src/java/org/apache/nutch/hostdb/UpdateHostDbReducer.java b/src/java/org/apache/nutch/hostdb/UpdateHostDbReducer.java
index 878216b3c..441991818 100644
--- a/src/java/org/apache/nutch/hostdb/UpdateHostDbReducer.java
+++ b/src/java/org/apache/nutch/hostdb/UpdateHostDbReducer.java
@@ -70,7 +70,7 @@ public class UpdateHostDbReducer
protected static Text[] numericFieldWritables;
protected static Text[] stringFieldWritables;
protected static CrawlDatumProcessor[] crawlDatumProcessors;
-
+
protected BlockingQueue<Runnable> queue = new SynchronousQueue<>();
protected ThreadPoolExecutor executor = null;
@@ -128,7 +128,7 @@ public class UpdateHostDbReducer
}
}
}
-
+
// What fields do we need to collect metadata from
if (numericFields != null) {
numericFieldWritables = new Text[numericFields.length];
@@ -136,7 +136,7 @@ public class UpdateHostDbReducer
numericFieldWritables[i] = new Text(numericFields[i]);
}
}
-
+
if (stringFields != null) {
stringFieldWritables = new Text[stringFields.length];
for (int i = 0; i < stringFields.length; i++) {
@@ -182,25 +182,25 @@ public class UpdateHostDbReducer
Map<String,Long> counts = new HashMap<>(); // used to calc averages
Map<String,Float> minimums = new HashMap<>();
Map<String,TDigest> tdigests = new HashMap<String,TDigest>();
-
+
HostDatum hostDatum = new HostDatum();
float score = 0;
-
+
if (stringFields != null) {
for (int i = 0; i < stringFields.length; i++) {
stringCounts.put(stringFields[i], new HashMap<>());
}
}
-
+
// Loop through all values until we find a non-empty HostDatum or use
// an empty if this is a new host for the host db
for (NutchWritable val : values) {
final Writable value = val.get(); // unwrap
-
+
// Count crawl datum status's and collect metadata from fields
if (value instanceof CrawlDatum) {
CrawlDatum buffer = (CrawlDatum)value;
-
+
// Set the correct status field
switch (buffer.getStatus()) {
case CrawlDatum.STATUS_DB_UNFETCHED:
@@ -227,14 +227,14 @@ public class UpdateHostDbReducer
hostDatum.setNotModified(hostDatum.getNotModified() + 1l);
break;
}
-
+
// Record connection failures
if (buffer.getRetriesSinceFetch() != 0) {
hostDatum.incConnectionFailures();
}
-
+
// Only gather metadata statistics for proper fetched pages
- if (buffer.getStatus() == CrawlDatum.STATUS_DB_FETCHED || buffer.getStatus() == CrawlDatum.STATUS_DB_NOTMODIFIED) {
+ if (buffer.getStatus() == CrawlDatum.STATUS_DB_FETCHED || buffer.getStatus() == CrawlDatum.STATUS_DB_NOTMODIFIED) {
// Deal with the string fields
if (stringFields != null) {
for (int i = 0; i < stringFields.length; i++) {
@@ -247,7 +247,7 @@ public class UpdateHostDbReducer
} catch (Exception e) {
LOG.error("Metadata field {} is probably not a numeric value", stringFields[i]);
}
-
+
// Does the value exist?
if (stringCounts.get(stringFields[i]).containsKey(metadataValue)) {
// Yes, increment it
@@ -259,7 +259,7 @@ public class UpdateHostDbReducer
}
}
}
-
+
// Deal with the numeric fields
if (numericFields != null) {
for (int i = 0; i < numericFields.length; i++) {
@@ -268,7 +268,7 @@ public class UpdateHostDbReducer
try {
// Get it!
Float metadataValue = Float.parseFloat(buffer.getMetaData().get(numericFieldWritables[i]).toString());
-
+
// Does the median value exist?
if (tdigests.containsKey(numericFields[i])) {
tdigests.get(numericFields[i]).add(metadataValue);
@@ -278,7 +278,7 @@ public class UpdateHostDbReducer
tdigest.add((double)metadataValue);
tdigests.put(numericFields[i], tdigest);
}
-
+
// Does the minimum value exist?
if (minimums.containsKey(numericFields[i])) {
// Write if this is lower than existing value
@@ -289,7 +289,7 @@ public class UpdateHostDbReducer
// Create it!
minimums.put(numericFields[i], metadataValue);
}
-
+
// Does the maximum value exist?
if (maximums.containsKey(numericFields[i])) {
// Write if this is lower than existing value
@@ -300,7 +300,7 @@ public class UpdateHostDbReducer
// Create it!
maximums.put(numericFields[i], metadataValue);
}
-
+
// Sum it up!
if (sums.containsKey(numericFields[i])) {
// Increment
@@ -327,7 +327,7 @@ public class UpdateHostDbReducer
}
}
- //
+ //
else if (value instanceof HostDatum) {
HostDatum buffer = (HostDatum)value;
@@ -350,7 +350,7 @@ public class UpdateHostDbReducer
if (buffer.getConnectionFailures() > 0) {
hostDatum.setConnectionFailures(buffer.getConnectionFailures());
}
-
+
// Check metadata
if (buffer.hasMetaData()) {
hostDatum.setMetaData(buffer.getMetaData());
@@ -375,7 +375,7 @@ public class UpdateHostDbReducer
if (score > 0) {
hostDatum.setScore(score);
}
-
+
// Set metadata
for (Map.Entry<String, Map<String,Long>> entry : stringCounts.entrySet()) {
for (Map.Entry<String,Long> subEntry : entry.getValue().entrySet()) {
@@ -393,11 +393,11 @@ public class UpdateHostDbReducer
for (int i = 0; i < percentiles.length; i++) {
hostDatum.getMetaData().put(new Text("pct" + Long.toString(percentiles[i]) + "." + entry.getKey()), new FloatWritable((float)entry.getValue().quantile(0.5)));
}
- }
+ }
for (Map.Entry<String, Float> entry : minimums.entrySet()) {
hostDatum.getMetaData().put(new Text("min." + entry.getKey()), new FloatWritable(entry.getValue()));
}
-
+
// Impose limits on minimum number of URLs?
if (urlLimit > -1l) {
if (hostDatum.numRecords() < urlLimit) {
@@ -405,7 +405,7 @@ public class UpdateHostDbReducer
return;
}
}
-
+
totalHostsCounter.increment(1);
// See if this record is to be checked
diff --git a/src/java/org/apache/nutch/indexer/CleaningJob.java b/src/java/org/apache/nutch/indexer/CleaningJob.java
index dc466dad0..b3f56b89f 100644
--- a/src/java/org/apache/nutch/indexer/CleaningJob.java
+++ b/src/java/org/apache/nutch/indexer/CleaningJob.java
@@ -103,7 +103,7 @@ public class CleaningJob implements Tool {
throw new RuntimeException(e);
}
noCommit = conf.getBoolean("noCommit", false);
-
+
// Initialize cached counter reference
initCounters(context);
}
@@ -139,7 +139,7 @@ public class CleaningJob implements Tool {
}
}
- public void delete(String crawldb, boolean noCommit)
+ public void delete(String crawldb, boolean noCommit)
throws IOException, InterruptedException, ClassNotFoundException {
StopWatch stopWatch = new StopWatch();
stopWatch.start();
diff --git a/src/java/org/apache/nutch/indexer/IndexingFilter.java b/src/java/org/apache/nutch/indexer/IndexingFilter.java
index 4774aab9c..a24f58bd0 100644
--- a/src/java/org/apache/nutch/indexer/IndexingFilter.java
+++ b/src/java/org/apache/nutch/indexer/IndexingFilter.java
@@ -37,7 +37,7 @@ public interface IndexingFilter extends Pluggable, Configurable {
* Adds fields or otherwise modifies the document that will be indexed for a
* parse. Unwanted documents can be removed from indexing by returning a null
* value.
- *
+ *
* @param doc
* document instance for collecting fields
* @param parse
diff --git a/src/java/org/apache/nutch/indexer/IndexingFiltersChecker.java b/src/java/org/apache/nutch/indexer/IndexingFiltersChecker.java
index f985dc9a7..d20b45400 100644
--- a/src/java/org/apache/nutch/indexer/IndexingFiltersChecker.java
+++ b/src/java/org/apache/nutch/indexer/IndexingFiltersChecker.java
@@ -46,9 +46,9 @@ import org.slf4j.LoggerFactory;
/**
* Reads and parses a URL and run the indexers on it. Displays the fields
* obtained and the first 100 characters of their value
- *
+ *
* Tested with e.g.
- *
+ *
* <pre>
echo "http://www.lemonde.fr" | $NUTCH_HOME/bin/nutch indexchecker -stdin
* </pre>
@@ -131,7 +131,7 @@ public class IndexingFiltersChecker extends AbstractChecker {
url = args[i];
}
}
-
+
if (url != null) {
return super.processSingle(url);
} else {
@@ -300,7 +300,7 @@ public class IndexingFiltersChecker extends AbstractChecker {
}
}
}
-
+
output.append("\n"); // For readability if keepClientCnxOpen
if (doIndex) {
@@ -312,7 +312,7 @@ public class IndexingFiltersChecker extends AbstractChecker {
return 0;
}
-
+
public static void main(String[] args) throws Exception {
final int res = ToolRunner.run(NutchConfiguration.create(),
new IndexingFiltersChecker(), args);
diff --git a/src/java/org/apache/nutch/indexer/IndexingJob.java b/src/java/org/apache/nutch/indexer/IndexingJob.java
index 8bf336880..cfbd75919 100644
--- a/src/java/org/apache/nutch/indexer/IndexingJob.java
+++ b/src/java/org/apache/nutch/indexer/IndexingJob.java
@@ -315,7 +315,7 @@ public class IndexingJob extends NutchTool implements Tool {
@Override
public Map<String, Object> run(Map<String, Object> args, String crawlId) throws Exception {
boolean noCommit = false;
- boolean deleteGone = false;
+ boolean deleteGone = false;
boolean filter = false;
boolean normalize = false;
boolean isSegment = false;
@@ -371,7 +371,7 @@ public class IndexingJob extends NutchTool implements Tool {
if (SegmentChecker.isIndexable(p,fs)) {
segments.add(p);
}
- }
+ }
}
if(args.containsKey(Nutch.ARG_SEGMENTS)) {
@@ -391,7 +391,7 @@ public class IndexingJob extends NutchTool implements Tool {
if(!isSegment){
String segment_dir = crawlId+"/segments";
File segmentsDir = new File(segment_dir);
- File[] segmentsList = segmentsDir.listFiles();
+ File[] segmentsList = segmentsDir.listFiles();
Arrays.sort(segmentsList, (f1, f2) -> {
if(f1.lastModified()>f2.lastModified())
return -1;
diff --git a/src/java/org/apache/nutch/indexer/package-info.java b/src/java/org/apache/nutch/indexer/package-info.java
index 2307dd9e1..9dfdd8ee2 100644
--- a/src/java/org/apache/nutch/indexer/package-info.java
+++ b/src/java/org/apache/nutch/indexer/package-info.java
@@ -16,8 +16,8 @@
*/
/**
- * Index content, configure and run indexing and cleaning jobs to
- * add, update, and delete documents from an index. Two tasks are
+ * Index content, configure and run indexing and cleaning jobs to
+ * add, update, and delete documents from an index. Two tasks are
* delegated to plugins:
* <ul>
* <li>indexing filters, which fill index fields of each document</li>
diff --git a/src/java/org/apache/nutch/metadata/CreativeCommons.java b/src/java/org/apache/nutch/metadata/CreativeCommons.java
index 0ddd4127c..d8b250b66 100644
--- a/src/java/org/apache/nutch/metadata/CreativeCommons.java
+++ b/src/java/org/apache/nutch/metadata/CreativeCommons.java
@@ -18,9 +18,9 @@ package org.apache.nutch.metadata;
/**
* A collection of Creative Commons properties names.
- *
+ *
* @see <a href="http://www.creativecommons.org/">creativecommons.org</a>
- *
+ *
*/
public interface CreativeCommons {
diff --git a/src/java/org/apache/nutch/metadata/DublinCore.java b/src/java/org/apache/nutch/metadata/DublinCore.java
index 8c703592e..f2928bcc7 100644
--- a/src/java/org/apache/nutch/metadata/DublinCore.java
+++ b/src/java/org/apache/nutch/metadata/DublinCore.java
@@ -18,9 +18,9 @@ package org.apache.nutch.metadata;
/**
* A collection of Dublin Core metadata names.
- *
+ *
* @see <a href="http://dublincore.org">dublincore.org</a>
- *
+ *
*/
public interface DublinCore {
diff --git a/src/java/org/apache/nutch/metadata/Feed.java b/src/java/org/apache/nutch/metadata/Feed.java
index ec937dae0..965ee9dd0 100644
--- a/src/java/org/apache/nutch/metadata/Feed.java
+++ b/src/java/org/apache/nutch/metadata/Feed.java
@@ -18,8 +18,8 @@ package org.apache.nutch.metadata;
/**
* A collection of Feed property names extracted by the ROME library.
- *
- *
+ *
+ *
*/
public interface Feed {
diff --git a/src/java/org/apache/nutch/metadata/HttpHeaders.java b/src/java/org/apache/nutch/metadata/HttpHeaders.java
index 33eb07e18..df2c7f961 100644
--- a/src/java/org/apache/nutch/metadata/HttpHeaders.java
+++ b/src/java/org/apache/nutch/metadata/HttpHeaders.java
@@ -20,7 +20,7 @@ import org.apache.hadoop.io.Text;
/**
* A collection of HTTP header names.
- *
+ *
* @see <a href="http://rfc-ref.org/RFC-TEXTS/2616/">Hypertext Transfer Protocol
* -- HTTP/1.1 (RFC 2616)</a>
*/
diff --git a/src/java/org/apache/nutch/metadata/MetaWrapper.java b/src/java/org/apache/nutch/metadata/MetaWrapper.java
index 1e32ee2c2..6bfd3af52 100644
--- a/src/java/org/apache/nutch/metadata/MetaWrapper.java
+++ b/src/java/org/apache/nutch/metadata/MetaWrapper.java
@@ -29,7 +29,7 @@ import org.apache.nutch.crawl.NutchWritable;
* serialized by {@link NutchWritable}. This is useful when data needs to be
* temporarily enriched during processing, but this temporary metadata doesn't
* need to be permanently stored after the job is done.
- *
+ *
*/
public class MetaWrapper extends NutchWritable {
private Metadata metadata;
diff --git a/src/java/org/apache/nutch/metadata/Metadata.java b/src/java/org/apache/nutch/metadata/Metadata.java
index 7fa0bb12c..c39d2532c 100644
--- a/src/java/org/apache/nutch/metadata/Metadata.java
+++ b/src/java/org/apache/nutch/metadata/Metadata.java
@@ -47,7 +47,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Returns true if named value is multivalued.
- *
+ *
* @param name
* name of metadata
* @return true is named value is multivalued, false if single value or null
@@ -58,7 +58,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Returns an array of the names contained in the metadata.
- *
+ *
* @return Metadata names
*/
public String[] names() {
@@ -68,7 +68,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Get the value associated to a metadata name. If many values are associated
* to the specified name, then the first one is returned.
- *
+ *
* @param name
* of the metadata.
* @return the value associated to the specified metadata name.
@@ -84,7 +84,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Get the values associated to a metadata name.
- *
+ *
* @param name
* of the metadata.
* @return the values associated to a metadata name.
@@ -104,7 +104,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Add a metadata name/value mapping. Add the specified value to the list of
* values associated to the specified metadata name.
- *
+ *
* @param name
* the metadata name.
* @param value
@@ -149,7 +149,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Copy All key-value pairs from properties.
- *
+ *
* @param properties
* properties to copy from
*/
@@ -165,7 +165,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
* Set metadata name/value. Associate the specified value to the specified
* metadata name. If some previous values were associated to this name, they
* are removed.
- *
+ *
* @param name
* the metadata name.
* @param value
@@ -177,7 +177,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Remove a metadata and all its associated values.
- *
+ *
* @param name
* metadata name to remove
*/
@@ -187,7 +187,7 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
/**
* Returns the number of metadata names in this metadata.
- *
+ *
* @return number of metadata names
*/
public int size() {
@@ -296,4 +296,3 @@ public class Metadata implements Writable, CreativeCommons, DublinCore,
}
}
-
\ No newline at end of file
diff --git a/src/java/org/apache/nutch/metadata/Nutch.java b/src/java/org/apache/nutch/metadata/Nutch.java
index 1645ca283..2542b35ee 100644
--- a/src/java/org/apache/nutch/metadata/Nutch.java
+++ b/src/java/org/apache/nutch/metadata/Nutch.java
@@ -20,7 +20,7 @@ import org.apache.hadoop.io.Text;
/**
* A collection of Nutch internal metadata constants.
- *
+ *
*/
public interface Nutch {
diff --git a/src/java/org/apache/nutch/metadata/SpellCheckedMetadata.java b/src/java/org/apache/nutch/metadata/SpellCheckedMetadata.java
index 70f9e7163..28654fb05 100644
--- a/src/java/org/apache/nutch/metadata/SpellCheckedMetadata.java
+++ b/src/java/org/apache/nutch/metadata/SpellCheckedMetadata.java
@@ -27,14 +27,14 @@ import org.apache.commons.text.similarity.LevenshteinDistance;
* A decorator to Metadata that adds spellchecking capabilities to property
* names. Currently used spelling vocabulary contains just the HTTP headers from
* {@link HttpHeaders} class. Other names are case insensitive.
- *
+ *
*/
public class SpellCheckedMetadata extends CaseInsensitiveMetadata {
/**
* Threshold divider to calculate max. Levenshtein distance for misspelled
* header field names:
- *
+ *
* <code>threshold = Math.min(3, searched.length() / TRESHOLD_DIVIDER);</code>
*/
private static final int TRESHOLD_DIVIDER = 3;
@@ -74,7 +74,7 @@ public class SpellCheckedMetadata extends CaseInsensitiveMetadata {
/**
* Normalizes String.
- *
+ *
* @param str
* the string to normalize
* @return normalized String
@@ -103,7 +103,7 @@ public class SpellCheckedMetadata extends CaseInsensitiveMetadata {
* </ul>
* If no matching with a well-known metadata name is found, then the original
* name is returned.
- *
+ *
* @param name
* HTTP header name to normalize
* @return normalized HTTP header name
diff --git a/src/java/org/apache/nutch/metadata/package-info.java b/src/java/org/apache/nutch/metadata/package-info.java
index b64dca365..5ad4ee1d8 100644
--- a/src/java/org/apache/nutch/metadata/package-info.java
+++ b/src/java/org/apache/nutch/metadata/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* A Multi-valued Metadata container, and set
* of constant fields for Nutch Metadata.
*/
diff --git a/src/java/org/apache/nutch/metrics/ErrorTracker.java b/src/java/org/apache/nutch/metrics/ErrorTracker.java
index efc97a09f..6b5408013 100644
--- a/src/java/org/apache/nutch/metrics/ErrorTracker.java
+++ b/src/java/org/apache/nutch/metrics/ErrorTracker.java
@@ -29,32 +29,32 @@ import org.apache.hadoop.mapreduce.TaskInputOutputContext;
/**
* A utility class for tracking errors by category with automatic classification.
- *
+ *
* <p>This class provides thread-safe error counting with automatic categorization
* based on exception type. It uses a bounded set of error categories to stay within
* Hadoop's counter limits (~120 counters).
- *
+ *
* <p><b>Usage in mapper/reducer or task threads:</b>
* <pre>
* // In mapper/reducer setup or thread initialization
* errorTracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
* // or with context for cached counters:
* errorTracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER, context);
- *
+ *
* // When catching exceptions
* try {
* // ... operation ...
* } catch (Exception e) {
* errorTracker.recordError(e); // Auto-categorizes
* }
- *
+ *
* // Or with manual categorization
* errorTracker.recordError(ErrorTracker.ErrorType.NETWORK);
- *
+ *
* // In cleanup - emit all error counters to the job
* errorTracker.emitCounters(context);
* </pre>
- *
+ *
* <p><b>Usage in driver/client code (no task context):</b>
* When used in a job driver or other code that does not run inside a mapper/reducer,
* create an ErrorTracker with the single-argument constructor (counter group only).
@@ -76,7 +76,7 @@ import org.apache.hadoop.mapreduce.TaskInputOutputContext;
* <li>errors_timeout_total - timeout errors</li>
* <li>errors_other_total - uncategorized errors</li>
* </ul>
- *
+ *
* @since 1.22
*/
public class ErrorTracker {
@@ -107,14 +107,14 @@ public class ErrorTracker {
private final String group;
private final Map<ErrorType, AtomicLong> counts;
private final AtomicLong totalCount;
-
+
// Cached counter references for performance (optional - set via initCounters)
private org.apache.hadoop.mapreduce.Counter cachedTotalCounter;
private final Map<ErrorType, org.apache.hadoop.mapreduce.Counter> cachedCounters;
/**
* Creates a new ErrorTracker for the specified counter group.
- *
+ *
* <p>Use in mapper/reducer setup or thread initialization: call
* {@link #initCounters(TaskInputOutputContext)} in setup() to cache counter
* references, then {@link #emitCounters(TaskInputOutputContext)} in cleanup to
@@ -124,7 +124,7 @@ public class ErrorTracker {
* emitCounters. Only {@link #recordError(Throwable)} and
* {@link #recordError(ErrorTracker.ErrorType)} are used; counts stay in-memory
* for consistent categorization and logging (e.g. with LOG.error).
- *
+ *
* @param group the Hadoop counter group name (e.g., NutchMetrics.GROUP_FETCHER)
*/
public ErrorTracker(String group) {
@@ -132,7 +132,7 @@ public class ErrorTracker {
this.counts = new EnumMap<>(ErrorType.class);
this.cachedCounters = new EnumMap<>(ErrorType.class);
this.totalCount = new AtomicLong(0);
-
+
// Initialize all counts to 0
for (ErrorType type : ErrorType.values()) {
counts.put(type, new AtomicLong(0));
@@ -141,10 +141,10 @@ public class ErrorTracker {
/**
* Creates a new ErrorTracker with cached counter references.
- *
+ *
* <p>This constructor caches all counter references at creation time,
* avoiding repeated counter lookups in hot paths.
- *
+ *
* @param group the Hadoop counter group name
* @param context the Hadoop task context for caching counters
*/
@@ -155,10 +155,10 @@ public class ErrorTracker {
/**
* Initializes cached counter references from the Hadoop context.
- *
+ *
* <p>Call this method in the mapper/reducer setup() method to cache
* counter references and avoid repeated lookups during processing.
- *
+ *
* @param context the Hadoop task context
*/
public void initCounters(TaskInputOutputContext<?, ?, ?, ?> context) {
@@ -170,7 +170,7 @@ public class ErrorTracker {
/**
* Records an error with automatic categorization based on the throwable type.
- *
+ *
* @param t the throwable to categorize and record
*/
public void recordError(Throwable t) {
@@ -179,7 +179,7 @@ public class ErrorTracker {
/**
* Records an error with explicit category.
- *
+ *
* @param type the error type category
*/
public void recordError(ErrorType type) {
@@ -189,7 +189,7 @@ public class ErrorTracker {
/**
* Returns the count for a specific error type.
- *
+ *
* @param type the error type
* @return the count for that error type
*/
@@ -199,7 +199,7 @@ public class ErrorTracker {
/**
* Returns the total count of all errors.
- *
+ *
* @return the total error count
*/
public long getTotalCount() {
@@ -208,13 +208,13 @@ public class ErrorTracker {
/**
* Emits all error counters to the Hadoop context.
- *
+ *
* <p>Should be called once during cleanup to emit aggregated metrics.
* Only emits counters for error types that have non-zero counts.
- *
+ *
* <p>If counters were cached via {@link #initCounters(TaskInputOutputContext)},
* uses the cached references for better performance.
- *
+ *
* @param context the Hadoop task context
*/
public void emitCounters(TaskInputOutputContext<?, ?, ?, ?> context) {
@@ -241,11 +241,11 @@ public class ErrorTracker {
/**
* Directly increments cached error counters without local accumulation.
- *
+ *
* <p>Use this method when you want to immediately update Hadoop counters
* rather than accumulating locally and emitting in cleanup.
* Requires {@link #initCounters(TaskInputOutputContext)} to have been called.
- *
+ *
* @param t the throwable to categorize and count
* @throws IllegalStateException if counters have not been initialized
*/
@@ -255,11 +255,11 @@ public class ErrorTracker {
/**
* Directly increments cached error counters without local accumulation.
- *
+ *
* <p>Use this method when you want to immediately update Hadoop counters
* rather than accumulating locally and emitting in cleanup.
* Requires {@link #initCounters(TaskInputOutputContext)} to have been called.
- *
+ *
* @param type the error type to count
* @throws IllegalStateException if counters have not been initialized
*/
@@ -274,11 +274,11 @@ public class ErrorTracker {
/**
* Categorizes a throwable into an error type.
- *
+ *
* <p>The categorization checks the exception class hierarchy to determine
* the most appropriate category. Timeout exceptions are checked first as
* they are a subclass of IOException.
- *
+ *
* @param t the throwable to categorize
* @return the appropriate ErrorType for the throwable
*/
@@ -286,43 +286,43 @@ public class ErrorTracker {
if (t == null) {
return ErrorType.OTHER;
}
-
+
String className = t.getClass().getName();
-
+
// Check for timeout first (before general IOException)
- if (t instanceof SocketTimeoutException
+ if (t instanceof SocketTimeoutException
|| className.contains("TimeoutException")
|| className.contains("Timeout")) {
return ErrorType.TIMEOUT;
}
-
+
// Network errors
- if (t instanceof SocketException
+ if (t instanceof SocketException
|| t instanceof UnknownHostException
|| className.contains("ConnectException")
|| className.contains("NoRouteToHostException")
|| className.contains("ConnectionRefusedException")) {
return ErrorType.NETWORK;
}
-
+
// URL errors (check before general IOException since MalformedURLException extends IOException)
if (t instanceof MalformedURLException
|| className.contains("URLFilterException")
|| className.contains("URISyntaxException")) {
return ErrorType.URL;
}
-
+
// General IOException (but not the specific subtypes above)
if (t instanceof IOException) {
return ErrorType.NETWORK;
}
-
+
// Protocol errors
if (className.contains("ProtocolException")
|| className.contains("ProtocolNotFound")) {
return ErrorType.PROTOCOL;
}
-
+
// Parsing errors
if (className.contains("ParseException")
|| className.contains("ParserNotFound")
@@ -330,17 +330,17 @@ public class ErrorTracker {
|| className.contains("ParserConfigurationException")) {
return ErrorType.PARSING;
}
-
+
// Scoring errors
if (className.contains("ScoringFilterException")) {
return ErrorType.SCORING;
}
-
+
// Indexing errors
if (className.contains("IndexingException")) {
return ErrorType.INDEXING;
}
-
+
// Check cause chain for more specific categorization
Throwable cause = t.getCause();
if (cause != null && cause != t) {
@@ -349,13 +349,13 @@ public class ErrorTracker {
return causeType;
}
}
-
+
return ErrorType.OTHER;
}
/**
* Gets the counter name constant for a given error type.
- *
+ *
* @param type the error type
* @return the counter name constant from NutchMetrics
*/
@@ -383,14 +383,14 @@ public class ErrorTracker {
/**
* Gets the counter name for a throwable based on its categorization.
- *
+ *
* <p>This is a convenience method for direct use in catch blocks:
* <pre>
* } catch (Exception e) {
* context.getCounter(group, ErrorTracker.getCounterName(e)).increment(1);
* }
* </pre>
- *
+ *
* @param t the throwable to get the counter name for
* @return the counter name constant from NutchMetrics
*/
diff --git a/src/java/org/apache/nutch/metrics/NutchMetrics.java b/src/java/org/apache/nutch/metrics/NutchMetrics.java
index 620b65b6b..1c8b6f6e9 100644
--- a/src/java/org/apache/nutch/metrics/NutchMetrics.java
+++ b/src/java/org/apache/nutch/metrics/NutchMetrics.java
@@ -18,7 +18,7 @@ package org.apache.nutch.metrics;
/**
* Centralized constants for Hadoop metrics counter groups and names.
- *
+ *
* <p>Follows <a href="https://prometheus.io/docs/practices/naming/">Prometheus
* naming conventions</a>:
* <ul>
@@ -27,7 +27,7 @@ package org.apache.nutch.metrics;
* <li>Accumulating counters use {@code _total} suffix</li>
* <li>Units are included in counter names where applicable (e.g., {@code _bytes})</li>
* </ul>
- *
+ *
* @since 1.22
*/
public final class NutchMetrics {
diff --git a/src/java/org/apache/nutch/metrics/package-info.java b/src/java/org/apache/nutch/metrics/package-info.java
index 376605d04..019bf5fcf 100644
--- a/src/java/org/apache/nutch/metrics/package-info.java
+++ b/src/java/org/apache/nutch/metrics/package-info.java
@@ -17,15 +17,15 @@
/**
* Metrics infrastructure for Apache Nutch.
- *
+ *
* <p>This package provides centralized constants and utilities for Hadoop
* MapReduce metrics/counters following
* <a href="https://prometheus.io/docs/practices/naming/">Prometheus naming
* conventions</a>.
- *
+ *
* <p>The main class is {@link org.apache.nutch.metrics.NutchMetrics} which
* defines all counter group names and counter names as constants.
- *
+ *
* @since 1.22
*/
package org.apache.nutch.metrics;
diff --git a/src/java/org/apache/nutch/net/URLFilter.java b/src/java/org/apache/nutch/net/URLFilter.java
index 6767b98c9..b23e4fd3f 100644
--- a/src/java/org/apache/nutch/net/URLFilter.java
+++ b/src/java/org/apache/nutch/net/URLFilter.java
@@ -33,7 +33,7 @@ public interface URLFilter extends Pluggable, Configurable {
/**
* Interface for a filter that transforms a URL: it can pass the original URL
* through or "delete" the URL by returning null
- *
+ *
* @param urlString
* the URL string the filter is applied on
* @return the original URL string if the URL is accepted by the filter or
diff --git a/src/java/org/apache/nutch/net/URLFilterChecker.java b/src/java/org/apache/nutch/net/URLFilterChecker.java
index b52d38d9e..68cd4614f 100644
--- a/src/java/org/apache/nutch/net/URLFilterChecker.java
+++ b/src/java/org/apache/nutch/net/URLFilterChecker.java
@@ -23,7 +23,7 @@ import org.apache.nutch.util.NutchConfiguration;
/**
* Checks one given filter or all filters.
- *
+ *
*/
public class URLFilterChecker extends AbstractChecker {
diff --git a/src/java/org/apache/nutch/net/URLFilters.java b/src/java/org/apache/nutch/net/URLFilters.java
index 4404626de..97ce48649 100644
--- a/src/java/org/apache/nutch/net/URLFilters.java
+++ b/src/java/org/apache/nutch/net/URLFilters.java
@@ -41,7 +41,7 @@ public class URLFilters {
/**
* Run all defined filters. Assume logical AND. To control performance, the
* ULFilter classes can be ordered by the property "urlfilter.order".
- *
+ *
* @param urlString
* to execute filters on
* @return filtered result
diff --git a/src/java/org/apache/nutch/net/URLNormalizers.java b/src/java/org/apache/nutch/net/URLNormalizers.java
index 596142cf8..eee4ca88d 100644
--- a/src/java/org/apache/nutch/net/URLNormalizers.java
+++ b/src/java/org/apache/nutch/net/URLNormalizers.java
@@ -43,7 +43,7 @@ import org.apache.nutch.util.ObjectCache;
* Different lists of normalizers may be defined for different "scopes", or
* contexts where they are used (note however that they need to be activated
* first through <code>plugin.include</code> property).
- *
+ *
* <p>
* There is one global scope defined by default, which consists of all active
* normalizers. The order in which these normalizers are executed may be defined
@@ -85,7 +85,7 @@ import org.apache.nutch.util.ObjectCache;
* count can be configured through <code>urlnormalizer.loop.count</code> property.
* As soon as the url is unchanged the loop will stop and return the result.
* </p>
- *
+ *
*/
public final class URLNormalizers {
@@ -164,7 +164,7 @@ public final class URLNormalizers {
/**
* Function returns an array of {@link URLNormalizer}s for a given scope, with
* a specified order.
- *
+ *
* @param scope
* The scope to return the <code>Array</code> of
* {@link URLNormalizer}s for.
@@ -208,7 +208,7 @@ public final class URLNormalizers {
/**
* Finds the best-suited normalizer plugin for a given scope.
- *
+ *
* @param scope
* Scope for which we seek a normalizer plugin.
* @return a list of extensions to be used for this scope. If none, returns
@@ -245,7 +245,7 @@ public final class URLNormalizers {
/**
* searches a list of suitable url normalizer plugins for the given scope.
- *
+ *
* @param scope
* Scope for which we seek a url normalizer plugin.
* @return List - List of extensions to be used for this scope. If none,
@@ -295,7 +295,7 @@ public final class URLNormalizers {
/**
* Normalize
- *
+ *
* @param urlString
* The URL string to normalize.
* @param scope
diff --git a/src/java/org/apache/nutch/net/protocols/HttpDateFormat.java b/src/java/org/apache/nutch/net/protocols/HttpDateFormat.java
index b000690e9..769c78aa1 100644
--- a/src/java/org/apache/nutch/net/protocols/HttpDateFormat.java
+++ b/src/java/org/apache/nutch/net/protocols/HttpDateFormat.java
@@ -30,13 +30,13 @@ import java.time.format.DateTimeParseException;
/**
* Parse and format HTTP dates in HTTP headers, e.g., used to fill the
* &quot;If-Modified-Since&quot; request header field.
- *
+ *
* HTTP dates use Greenwich Mean Time (GMT) as time zone and a date format like:
- *
+ *
* <pre>
* Sun, 06 Nov 1994 08:49:37 GMT
* </pre>
- *
+ *
* See <a href=
* "https://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.3.1">sec. 3.3.1
* in RFC 2616</a> and
diff --git a/src/java/org/apache/nutch/parse/HtmlParseFilter.java b/src/java/org/apache/nutch/parse/HtmlParseFilter.java
index cf03aa356..ceca9a450 100644
--- a/src/java/org/apache/nutch/parse/HtmlParseFilter.java
+++ b/src/java/org/apache/nutch/parse/HtmlParseFilter.java
@@ -36,8 +36,8 @@ public interface HtmlParseFilter extends Pluggable, Configurable {
* Adds metadata or otherwise modifies a parse of HTML content, given the DOM
* tree of a page.
* @param content the {@link Content} for a given response
- * @param parseResult the result of running on or more
- * {@link Parser}'s on the content.
+ * @param parseResult the result of running on or more
+ * {@link Parser}'s on the content.
* @see Parser#getParse(Content)
* @param metaTags a populated {@link HTMLMetaTags} object
* @param doc a {@link DocumentFragment} (DOM) which can be processed in
diff --git a/src/java/org/apache/nutch/parse/HtmlParseFilters.java b/src/java/org/apache/nutch/parse/HtmlParseFilters.java
index 30ddd21e8..53be46b35 100644
--- a/src/java/org/apache/nutch/parse/HtmlParseFilters.java
+++ b/src/java/org/apache/nutch/parse/HtmlParseFilters.java
@@ -38,8 +38,8 @@ public class HtmlParseFilters {
/**
* Run all defined filters.
* @param content the {@link Content} for a given response
- * @param parseResult the result of running on or more
- * {@link Parser}'s on the content.
+ * @param parseResult the result of running on or more
+ * {@link Parser}'s on the content.
* @see Parser#getParse(Content)
* @param metaTags a populated {@link HTMLMetaTags} object
* @param doc a {@link DocumentFragment} (DOM) which can be processed in
diff --git a/src/java/org/apache/nutch/parse/OutlinkExtractor.java b/src/java/org/apache/nutch/parse/OutlinkExtractor.java
index 4d3a1d208..0c5887c0d 100644
--- a/src/java/org/apache/nutch/parse/OutlinkExtractor.java
+++ b/src/java/org/apache/nutch/parse/OutlinkExtractor.java
@@ -31,13 +31,13 @@ import org.slf4j.LoggerFactory;
/**
* Extractor to extract {@link org.apache.nutch.parse.Outlink}s / URLs from
* plain text using Regular Expressions.
- *
+ *
* @see <a
* href="http://wiki.java.net/bin/view/Javapedia/RegularExpressions">Comparison
* of different regexp-Implementations </a>
* @see <a href="http://regex.info/java.html">Overview about Java Regexp APIs
* </a>
- *
+ *
* @version 1.0
* @since 0.7
*/
@@ -47,7 +47,7 @@ public class OutlinkExtractor {
/**
* Regex pattern to get URLs within a plain text.
- *
+ *
* @see documentation on <a href="http://web.archive.org/web/20190220011657/http://www.truerwords.net/articles/ut/urlactivation.html">
* urlactivation</a>
*/
@@ -58,7 +58,7 @@ public class OutlinkExtractor {
* Extracts <code>Outlink</code> from given plain text. Applying this method
* to non-plain-text can result in extremely lengthy runtimes for parasitic
* cases (postscript is a known example).
- *
+ *
* @param plainText
* the plain text from which URLs should be extracted.
* @param conf a populated {@link Configuration}
@@ -72,7 +72,7 @@ public class OutlinkExtractor {
/**
* Extracts <code>Outlink</code> from given plain text and adds anchor to the
* extracted <code>Outlink</code>s
- *
+ *
* @param plainText
* the plain text from which URLs should be extracted.
* @param anchor
diff --git a/src/java/org/apache/nutch/parse/Parse.java b/src/java/org/apache/nutch/parse/Parse.java
index 3fffc7705..6bd308653 100644
--- a/src/java/org/apache/nutch/parse/Parse.java
+++ b/src/java/org/apache/nutch/parse/Parse.java
@@ -18,7 +18,7 @@ package org.apache.nutch.parse;
/**
* The result of parsing a page's raw content.
- *
+ *
* @see Parser#getParse(Content)
*/
public interface Parse {
diff --git a/src/java/org/apache/nutch/parse/ParseData.java b/src/java/org/apache/nutch/parse/ParseData.java
index 31a720f44..e8b651dfc 100644
--- a/src/java/org/apache/nutch/parse/ParseData.java
+++ b/src/java/org/apache/nutch/parse/ParseData.java
@@ -35,7 +35,7 @@ import org.apache.nutch.util.NutchConfiguration;
/**
* Data extracted from a page's content.
- *
+ *
* @see Parse#getData()
*/
public final class ParseData extends VersionedWritable {
@@ -125,7 +125,7 @@ public final class ParseData extends VersionedWritable {
* in the content metadata.
* @param name the metadata key for which to retrieve a value
* @return the (string) metadata value
- *
+ *
* @see #getContentMeta()
* @see #getParseMeta()
*/
diff --git a/src/java/org/apache/nutch/parse/ParseImpl.java b/src/java/org/apache/nutch/parse/ParseImpl.java
index ef4dd167b..d79834b49 100644
--- a/src/java/org/apache/nutch/parse/ParseImpl.java
+++ b/src/java/org/apache/nutch/parse/ParseImpl.java
@@ -24,7 +24,7 @@ import org.apache.hadoop.io.Writable;
/**
* The result of parsing a page's raw content.
- *
+ *
* @see Parser#getParse(Content)
*/
public class ParseImpl implements Parse, Writable {
diff --git a/src/java/org/apache/nutch/parse/ParsePluginList.java b/src/java/org/apache/nutch/parse/ParsePluginList.java
index 6e46ab4ff..920c23309 100644
--- a/src/java/org/apache/nutch/parse/ParsePluginList.java
+++ b/src/java/org/apache/nutch/parse/ParsePluginList.java
@@ -26,7 +26,7 @@ import java.util.Map;
* called for a particular mimeType. It provides methods to store the
* parse-plugins.xml data, and methods to retrieve the name of the appropriate
* parsing plugin for a contentType.
- *
+ *
* @version 1.0
*/
class ParsePluginList {
diff --git a/src/java/org/apache/nutch/parse/ParsePluginsReader.java b/src/java/org/apache/nutch/parse/ParsePluginsReader.java
index 4ed599db0..97b8c8c98 100644
--- a/src/java/org/apache/nutch/parse/ParsePluginsReader.java
+++ b/src/java/org/apache/nutch/parse/ParsePluginsReader.java
@@ -43,7 +43,7 @@ import org.apache.nutch.util.XmlUtil;
/**
* A reader to load the information stored in the
* <code>$NUTCH_HOME/conf/parse-plugins.xml</code> file.
- *
+ *
* @version 1.0
*/
class ParsePluginsReader {
@@ -67,7 +67,7 @@ class ParsePluginsReader {
/**
* Reads the <code>parse-plugins.xml</code> file and returns the
* {@link #ParsePluginList} defined by it.
- *
+ *
* @return A {@link #ParsePluginList} specified by the
* <code>parse-plugins.xml</code> file.
* @throws Exception
@@ -171,7 +171,7 @@ class ParsePluginsReader {
* Tests parsing of the parse-plugins.xml file. An alternative name for the
* file can be specified via the <code>--file</code> option, although the file
* must be located in the <code>$NUTCH_HOME/conf</code> directory.
- *
+ *
* @param args
* Currently only the --file argument to specify an alternative name
* for the parse-plugins.xml file is supported.
diff --git a/src/java/org/apache/nutch/parse/ParseResult.java b/src/java/org/apache/nutch/parse/ParseResult.java
index 23a64dfc6..f443ca894 100644
--- a/src/java/org/apache/nutch/parse/ParseResult.java
+++ b/src/java/org/apache/nutch/parse/ParseResult.java
@@ -47,7 +47,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Create a container for parse results.
- *
+ *
* @param originalUrl
* the original url from which all parse results have been obtained.
*/
@@ -59,7 +59,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Convenience method for obtaining {@link ParseResult} from a single
* {@link Parse} output.
- *
+ *
* @param url
* canonical url.
* @param parse
@@ -75,7 +75,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Checks whether the result is empty.
- *
+ *
* @return true if empty, false otherwise
*/
public boolean isEmpty() {
@@ -92,7 +92,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Retrieve a single parse output.
- *
+ *
* @param key
* sub-url under which the parse output is stored.
* @return parse output corresponding to this sub-url, or null.
@@ -103,7 +103,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Retrieve a single parse output.
- *
+ *
* @param key
* sub-url under which the parse output is stored.
* @return parse output corresponding to this sub-url, or null.
@@ -114,7 +114,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Store a result of parsing.
- *
+ *
* @param key
* URL or sub-url of this parse result
* @param text
@@ -128,7 +128,7 @@ public class ParseResult implements Iterable<Map.Entry<Text, Parse>> {
/**
* Store a result of parsing.
- *
+ *
* @param key
* URL or sub-url of this parse result
* @param text
diff --git a/src/java/org/apache/nutch/parse/ParseUtil.java b/src/java/org/apache/nutch/parse/ParseUtil.java
index c974a1054..ebdf00134 100644
--- a/src/java/org/apache/nutch/parse/ParseUtil.java
+++ b/src/java/org/apache/nutch/parse/ParseUtil.java
@@ -33,7 +33,7 @@ import com.google.common.util.concurrent.ThreadFactoryBuilder;
* A Utility class containing methods to simply perform parsing utilities such
* as iterating through a preferred list of {@link Parser}s to obtain
* {@link Parse} objects.
- *
+ *
*/
public class ParseUtil {
@@ -61,7 +61,7 @@ public class ParseUtil {
* until a successful parse is performed and a {@link Parse} object is
* returned. If the parse is unsuccessful, a message is logged to the
* <code>WARNING</code> level, and an empty parse is returned.
- *
+ *
* @param content
* The content to try and parse.
* @return &lt;key, {@link Parse}&gt; pairs.
@@ -122,17 +122,17 @@ public class ParseUtil {
* message is logged, and a ParseException is thrown. If the parse is
* uncessful for any other reason, then a <code>WARNING</code> level message
* is logged, and a <code>ParseStatus.getEmptyParse()</code> is returned.
- *
+ *
* @param extId
* The extension implementation ID of the {@link Parser} to use to
* parse the specified content.
* @param content
* The content to parse.
- *
+ *
* @return &lt;key, {@link Parse}&gt; pairs if the parse is successful,
* otherwise, a single &lt;key,
* <code>ParseStatus.getEmptyParse()</code>&gt; pair.
- *
+ *
* @throws ParseException
* If there is no suitable {@link Parser} found to perform the
* parse.
diff --git a/src/java/org/apache/nutch/parse/Parser.java b/src/java/org/apache/nutch/parse/Parser.java
index fbff009e8..b5b0ab1bf 100644
--- a/src/java/org/apache/nutch/parse/Parser.java
+++ b/src/java/org/apache/nutch/parse/Parser.java
@@ -45,7 +45,7 @@ public interface Parser extends Pluggable, Configurable {
* of the form &lt;"foo.bar.com/redirect.html", {@link Parse} with a
* {@link ParseStatus} indicating the redirect&gt;.
* </p>
- *
+ *
* @param c
* Content to be parsed
* @return a map containing &lt;key, parse&gt; pairs
diff --git a/src/java/org/apache/nutch/parse/ParserChecker.java b/src/java/org/apache/nutch/parse/ParserChecker.java
index b65d475d8..402c4d1df 100644
--- a/src/java/org/apache/nutch/parse/ParserChecker.java
+++ b/src/java/org/apache/nutch/parse/ParserChecker.java
@@ -62,7 +62,7 @@ import org.slf4j.LoggerFactory;
* <li><code>ParseText</code>: The page parse text which varies in length depdnecing
* on <code>content.length</code> configuration.</li>
* </ol>
- *
+ *
*/
public class ParserChecker extends AbstractChecker {
@@ -145,7 +145,7 @@ public class ParserChecker extends AbstractChecker {
}
this.scfilters = new ScoringFilters(getConf());
-
+
if (url != null) {
return super.processSingle(url);
} else {
diff --git a/src/java/org/apache/nutch/parse/ParserFactory.java b/src/java/org/apache/nutch/parse/ParserFactory.java
index e089679fa..2f4ae20c2 100644
--- a/src/java/org/apache/nutch/parse/ParserFactory.java
+++ b/src/java/org/apache/nutch/parse/ParserFactory.java
@@ -77,11 +77,11 @@ public final class ParserFactory {
/**
* Function returns an array of {@link Parser}s for a given content type.
- *
+ *
* The function consults the internal list of parse plugins for the
* ParserFactory to determine the list of pluginIds, then gets the appropriate
* extension points to instantiate as {@link Parser}s.
- *
+ *
* @param contentType
* The contentType to return the <code>Array</code> of {@link Parser}
* s for.
@@ -155,7 +155,7 @@ public final class ParserFactory {
* instantiated Parser. Otherwise, if it has to instantiate the Parser itself
* , then this function will cache that Parser in the internal
* <code>PARSER_CACHE</code>.
- *
+ *
* @param id
* The string extension ID (e.g.,
* "org.apache.nutch.parse.rss.RSSParser",
@@ -206,7 +206,7 @@ public final class ParserFactory {
/**
* Finds the best-suited parse plugin for a given contentType.
- *
+ *
* @param contentType
* Content-Type for which we seek a parse plugin.
* @return a list of extensions to be used for this contentType. If none,
@@ -246,7 +246,7 @@ public final class ParserFactory {
* <p>
* It first looks for a preferred plugin defined in the parse-plugin file. If
* none is found, it returns a list of default plugins.
- *
+ *
* @param contentType
* Content-Type for which we seek a parse plugin.
* @return List - List of extensions to be used for this contentType. If none,
@@ -278,7 +278,7 @@ public final class ParserFactory {
* <li>If this list is empty, it tries to find amongst the loaded extensions
* whether some of them might suit and warns the user.</li>
* </ol>
- *
+ *
* @param plugins
* List of candidate plugins.
* @param extensions
diff --git a/src/java/org/apache/nutch/plugin/CircularDependencyException.java b/src/java/org/apache/nutch/plugin/CircularDependencyException.java
index 21cf0c8ee..53852fba1 100644
--- a/src/java/org/apache/nutch/plugin/CircularDependencyException.java
+++ b/src/java/org/apache/nutch/plugin/CircularDependencyException.java
@@ -19,7 +19,7 @@ package org.apache.nutch.plugin;
/**
* <code>CircularDependencyException</code> will be thrown if a circular
* dependency is detected.
- *
+ *
*/
public class CircularDependencyException extends Exception {
diff --git a/src/java/org/apache/nutch/plugin/Extension.java b/src/java/org/apache/nutch/plugin/Extension.java
index a055b73f3..4bd7ece9d 100644
--- a/src/java/org/apache/nutch/plugin/Extension.java
+++ b/src/java/org/apache/nutch/plugin/Extension.java
@@ -44,7 +44,7 @@ public class Extension {
* an unique id of the plugin
* @param pExtensionClass the class extending the extension point
* @param conf a populated {@link org.apache.hadoop.conf.Configuration}
- * @param pluginRepository a {@link PluginRepository} containing
+ * @param pluginRepository a {@link PluginRepository} containing
* all plugin artifacts
*/
public Extension(PluginDescriptor pDescriptor, String pExtensionPoint,
@@ -68,7 +68,7 @@ public class Extension {
/**
* Returns a attribute value, that is setuped in the manifest file and is
* defined by the extension point xml schema.
- *
+ *
* @param pKey
* a key
* @return String a value
@@ -79,7 +79,7 @@ public class Extension {
/**
* Returns the full class name of the extension point implementation
- *
+ *
* @return String
*/
public String getClazz() {
@@ -88,7 +88,7 @@ public class Extension {
/**
* Return the unique id of the extension.
- *
+ *
* @return String
*/
public String getId() {
@@ -98,7 +98,7 @@ public class Extension {
/**
* Adds a attribute and is only used until model creation at plugin system
* start up.
- *
+ *
* @param pKey
* a key
* @param pValue
@@ -111,7 +111,7 @@ public class Extension {
/**
* Sets the Class that implement the concrete extension and is only used until
* model creation at system start up.
- *
+ *
* @param extensionClazz
* The extensionClasname to set
*/
@@ -122,7 +122,7 @@ public class Extension {
/**
* Sets the unique extension Id and is only used until model creation at
* system start up.
- *
+ *
* @param extensionID
* The extensionID to set
*/
@@ -148,7 +148,7 @@ public class Extension {
* only its own <i>plugin runtime libraries</i> defined in the
* <code>plugin.xml</code> manifest file and exported libraries of the
* dependent plugins.
- *
+ *
* @return Object An instance of the extension implementation
* @throws PluginRuntimeException
* if there is a fatal runtime error
@@ -189,7 +189,7 @@ public class Extension {
/**
* Get the plugin descriptor.
- *
+ *
* @return PluginDescriptor
*/
public PluginDescriptor getDescriptor() {
@@ -199,7 +199,7 @@ public class Extension {
/**
* Sets the plugin descriptor and is only used until model creation at system
* start up.
- *
+ *
* @param pDescriptor a instantiated {@link org.apache.nutch.plugin.PluginDescriptor}
*/
public void setDescriptor(PluginDescriptor pDescriptor) {
diff --git a/src/java/org/apache/nutch/plugin/ExtensionPoint.java b/src/java/org/apache/nutch/plugin/ExtensionPoint.java
index 17c6ccda2..0c911be56 100644
--- a/src/java/org/apache/nutch/plugin/ExtensionPoint.java
+++ b/src/java/org/apache/nutch/plugin/ExtensionPoint.java
@@ -21,7 +21,7 @@ import java.util.ArrayList;
/**
* The <code>ExtensionPoint</code> provide meta information of a extension
* point.
- *
+ *
*/
public class ExtensionPoint {
private String ftId;
@@ -31,7 +31,7 @@ public class ExtensionPoint {
/**
* Constructor
- *
+ *
* @param pId
* unique extension point Id
* @param pName
@@ -48,7 +48,7 @@ public class ExtensionPoint {
/**
* Returns the unique id of the extension point.
- *
+ *
* @return String
*/
public String getId() {
@@ -57,7 +57,7 @@ public class ExtensionPoint {
/**
* Returns the name of the extension point.
- *
+ *
* @return String
*/
public String getName() {
@@ -66,7 +66,7 @@ public class ExtensionPoint {
/**
* Returns a path to the xml schema of a extension point.
- *
+ *
* @return String
*/
public String getSchema() {
@@ -75,7 +75,7 @@ public class ExtensionPoint {
/**
* Sets the extensionPointId.
- *
+ *
* @param pId
* extension point id
*/
@@ -85,7 +85,7 @@ public class ExtensionPoint {
/**
* Sets the extension point name.
- *
+ *
* @param pName
*/
private void setName(String pName) {
@@ -94,7 +94,7 @@ public class ExtensionPoint {
/**
* Sets the schema.
- *
+ *
* @param pSchema
*/
private void setSchema(String pSchema) {
@@ -103,7 +103,7 @@ public class ExtensionPoint {
/**
* Install a corresponding extension to this extension point.
- *
+ *
* @param extension the new {@link org.apache.nutch.plugin.Extension}
* to install
*/
@@ -113,7 +113,7 @@ public class ExtensionPoint {
/**
* Returns a array of extensions that lsiten to this extension point
- *
+ *
* @return Extension[]
*/
public Extension[] getExtensions() {
diff --git a/src/java/org/apache/nutch/plugin/MissingDependencyException.java b/src/java/org/apache/nutch/plugin/MissingDependencyException.java
index 61ab62bd4..e4deafb3b 100644
--- a/src/java/org/apache/nutch/plugin/MissingDependencyException.java
+++ b/src/java/org/apache/nutch/plugin/MissingDependencyException.java
@@ -19,7 +19,7 @@ package org.apache.nutch.plugin;
/**
* <code>MissingDependencyException</code> will be thrown if a plugin dependency
* cannot be found.
- *
+ *
*/
public class MissingDependencyException extends Exception {
diff --git a/src/java/org/apache/nutch/plugin/Pluggable.java b/src/java/org/apache/nutch/plugin/Pluggable.java
index 55b9e265b..4f0044116 100644
--- a/src/java/org/apache/nutch/plugin/Pluggable.java
+++ b/src/java/org/apache/nutch/plugin/Pluggable.java
@@ -19,8 +19,8 @@ package org.apache.nutch.plugin;
/**
* Defines the capability of a class to be plugged into Nutch. This is a common
* interface that must be implemented by all Nutch Extension Points.
- *
- *
+ *
+ *
* @see <a href="https://cwiki.apache.org/confluence/display/NUTCH/AboutPlugins">About Plugins</a>
* @see <a href="package-summary.html#package_description"> plugin package
* description</a>
diff --git a/src/java/org/apache/nutch/plugin/Plugin.java b/src/java/org/apache/nutch/plugin/Plugin.java
index 67de18ecc..55a7c822d 100644
--- a/src/java/org/apache/nutch/plugin/Plugin.java
+++ b/src/java/org/apache/nutch/plugin/Plugin.java
@@ -25,17 +25,17 @@ import org.apache.hadoop.conf.Configuration;
* Extensions are components that can be dynamically installed as a kind of
* listener to extension points. Extension points are a kind of publisher that
* provide a API and invoke one or a set of installed extensions.
- *
+ *
* Each plugin may extend the base <code>Plugin</code>. <code>Plugin</code>
* instances are used as the point of life cycle management of plugin related
* functionality.
- *
+ *
* The <code>Plugin</code> will be started up and shutdown by the nutch plugin
* management system.
- *
+ *
* A possible usecase of the <code>Plugin</code> implementation is to create or
* close a database connection.
- *
+ *
*/
public class Plugin {
private PluginDescriptor fDescriptor;
@@ -55,7 +55,7 @@ public class Plugin {
* Will be invoked until plugin start up. Since the nutch-plugin system use
* lazy loading the start up is invoked until the first time a extension is
* used.
- *
+ *
* @throws PluginRuntimeException
* If the startup was without success.
*/
@@ -64,7 +64,7 @@ public class Plugin {
/**
* Shutdown the plugin. This happens until nutch will be stopped.
- *
+ *
* @throws PluginRuntimeException
* if a problems occurs until shutdown the plugin.
*/
@@ -73,7 +73,7 @@ public class Plugin {
/**
* Returns the plugin descriptor
- *
+ *
* @return PluginDescriptor
*/
public PluginDescriptor getDescriptor() {
diff --git a/src/java/org/apache/nutch/plugin/PluginClassLoader.java b/src/java/org/apache/nutch/plugin/PluginClassLoader.java
index a1d180ff0..fc60e4d99 100644
--- a/src/java/org/apache/nutch/plugin/PluginClassLoader.java
+++ b/src/java/org/apache/nutch/plugin/PluginClassLoader.java
@@ -34,7 +34,7 @@ import java.util.List;
* exported or not. Not exported libraries are only used in the plugin own
* <code>PluginClassLoader</code>. Exported libraries are available for
* <code>PluginClassLoader</code> of plugins that depends on these plugins.
- *
+ *
*/
public class PluginClassLoader extends URLClassLoader {
@@ -44,11 +44,11 @@ public class PluginClassLoader extends URLClassLoader {
/**
* Overloaded constructor
- *
+ *
* @param urls
* Array of urls with own libraries and all exported libraries of
* plugins that are required for this plugin
- * @param parent the parent {@link java.lang.ClassLoader} responsible for
+ * @param parent the parent {@link java.lang.ClassLoader} responsible for
* loading classes defined in urls.
*/
public PluginClassLoader(URL[] urls, ClassLoader parent) {
diff --git a/src/java/org/apache/nutch/plugin/PluginDescriptor.java b/src/java/org/apache/nutch/plugin/PluginDescriptor.java
index 3449e1cc0..e7da40f5e 100644
--- a/src/java/org/apache/nutch/plugin/PluginDescriptor.java
+++ b/src/java/org/apache/nutch/plugin/PluginDescriptor.java
@@ -58,7 +58,7 @@ public class PluginDescriptor {
/**
* Overloaded constructor
- *
+ *
* @param pId set plugin ID
* @param pVersion set plugin version
* @param pName set plugin name
@@ -92,7 +92,7 @@ public class PluginDescriptor {
/**
* Returns the name of the plugin.
- *
+ *
* @return String
*/
public String getName() {
@@ -123,7 +123,7 @@ public class PluginDescriptor {
/**
* Returns the fully qualified name of the class which implements the abstarct
* <code>Plugin</code> class.
- *
+ *
* @return the name of this plug-in's runtime class or <code>null</code>.
*/
public String getPluginClass() {
@@ -132,7 +132,7 @@ public class PluginDescriptor {
/**
* Returns the unique identifier of the plug-in or <code>null</code>.
- *
+ *
* @return String
*/
public String getPluginId() {
@@ -141,7 +141,7 @@ public class PluginDescriptor {
/**
* Returns an array of extensions.
- *
+ *
* @return Exception[]
*/
public Extension[] getExtensions() {
@@ -150,7 +150,7 @@ public class PluginDescriptor {
/**
* Adds a extension.
- *
+ *
* @param pExtension a {@link org.apache.nutch.plugin.Extension}
*/
public void addExtension(Extension pExtension) {
@@ -159,7 +159,7 @@ public class PluginDescriptor {
/**
* Sets the pluginClass.
- *
+ *
* @param pluginClass
* The pluginClass to set
*/
@@ -169,7 +169,7 @@ public class PluginDescriptor {
/**
* Sets the plugin Id.
- *
+ *
* @param pluginId
* The pluginId to set
*/
@@ -179,7 +179,7 @@ public class PluginDescriptor {
/**
* Adds a extension point.
- *
+ *
* @param extensionPoint a {@link org.apache.nutch.plugin.ExtensionPoint}
*/
public void addExtensionPoint(ExtensionPoint extensionPoint) {
@@ -188,7 +188,7 @@ public class PluginDescriptor {
/**
* Returns a array of extension points.
- *
+ *
* @return ExtensionPoint[]
*/
public ExtensionPoint[] getExtenstionPoints() {
@@ -198,7 +198,7 @@ public class PluginDescriptor {
/**
* Returns a array of plugin ids.
- *
+ *
* @return String[]
*/
public String[] getDependencies() {
@@ -207,7 +207,7 @@ public class PluginDescriptor {
/**
* Adds a dependency
- *
+ *
* @param pId
* id of the dependent plugin
*/
@@ -218,15 +218,15 @@ public class PluginDescriptor {
/**
* Adds a exported library with a relative path to the plugin directory. We
* automatically escape characters that are illegal in URLs. It is recommended
- * that code converts an abstract pathname into a {@link java.net.URL} by
- * first converting it into a {@link java.net.URI}, via the
- * {@link java.net.URL#toURI()} method, and then converting the
- * {@link java.net.URI} into a {@link java.net.URL} via the
+ * that code converts an abstract pathname into a {@link java.net.URL} by
+ * first converting it into a {@link java.net.URI}, via the
+ * {@link java.net.URL#toURI()} method, and then converting the
+ * {@link java.net.URI} into a {@link java.net.URL} via the
* {@link java.net.URI#toURL()} method.
- *
+ *
* @param pLibPath path to a exported library relative to the plugin directory
- * @throws MalformedURLException if the pLibPath is not a relative path
- * (to the plugin directory)
+ * @throws MalformedURLException if the pLibPath is not a relative path
+ * (to the plugin directory)
*/
public void addExportedLibRelative(String pLibPath)
throws MalformedURLException {
@@ -237,7 +237,7 @@ public class PluginDescriptor {
/**
* Returns the directory path of the plugin.
- *
+ *
* @return String
*/
public String getPluginPath() {
@@ -246,7 +246,7 @@ public class PluginDescriptor {
/**
* Returns a array of exported libs as URLs
- *
+ *
* @return URL[]
*/
public URL[] getExportedLibUrls() {
@@ -256,15 +256,15 @@ public class PluginDescriptor {
/**
* Adds a non-exported library with a relative path to the plugin directory. We
* automatically escape characters that are illegal in URLs. It is recommended
- * that code converts an abstract pathname into a {@link java.net.URL} by
- * first converting it into a {@link java.net.URI}, via the
- * {@link java.net.URL#toURI()} method, and then converting the
- * {@link java.net.URI} into a {@link java.net.URL} via the
+ * that code converts an abstract pathname into a {@link java.net.URL} by
+ * first converting it into a {@link java.net.URI}, via the
+ * {@link java.net.URL#toURI()} method, and then converting the
+ * {@link java.net.URI} into a {@link java.net.URL} via the
* {@link java.net.URI#toURL()} method.
- *
+ *
* @param pLibPath path to a exported library relative to the plugin directory
- * @throws MalformedURLException if the pLibPath is not a relative path
- * (to the plugin directory)
+ * @throws MalformedURLException if the pLibPath is not a relative path
+ * (to the plugin directory)
*/
public void addNotExportedLibRelative(String pLibPath)
throws MalformedURLException {
@@ -275,7 +275,7 @@ public class PluginDescriptor {
/**
* Returns a array of libraries as URLs that are not exported by the plugin.
- *
+ *
* @return URL[]
*/
public URL[] getNotExportedLibUrls() {
@@ -286,7 +286,7 @@ public class PluginDescriptor {
* Returns a cached classloader for a plugin. Until classloader creation all
* needed libraries are collected. A classloader use as first the plugins own
* libraries and add then all exported libraries of dependent plugins.
- *
+ *
* @return PluginClassLoader the classloader for the plugin
*/
public PluginClassLoader getClassLoader() {
@@ -339,10 +339,10 @@ public class PluginDescriptor {
/**
* Returns a I18N'd resource string. The resource bundles could be stored in
* root directory of a plugin in the well known i18n file name conventions.
- *
+ *
* @param pKey a plugin key
* @param pLocale the required {@link java.util.Locale}
- * @return a string for the given key from the
+ * @return a string for the given key from the
* {@link java.util.ResourceBundle} bundle or one of its parents
* @throws IOException if there is an error obtaining the key
*/
diff --git a/src/java/org/apache/nutch/plugin/PluginManifestParser.java b/src/java/org/apache/nutch/plugin/PluginManifestParser.java
index 152a80591..4a2def9ab 100644
--- a/src/java/org/apache/nutch/plugin/PluginManifestParser.java
+++ b/src/java/org/apache/nutch/plugin/PluginManifestParser.java
@@ -44,7 +44,7 @@ import org.xml.sax.SAXException;
* The <code>PluginManifestParser</code> provides a mechanism for
* parsing Nutch plugin manifest files (<code>plugin.xml</code>) contained
* in a {@link java.lang.String[]} of plugin directories.
- *
+ *
*/
public class PluginManifestParser {
private static final String ATTR_NAME = "name";
@@ -66,7 +66,7 @@ public class PluginManifestParser {
/**
* Returns a list of all found plugin descriptors.
- *
+ *
* @param pluginFolders
* folders to search plugins from
* @return A {@link Map} of all found {@link PluginDescriptor}s.
@@ -105,7 +105,7 @@ public class PluginManifestParser {
* Return the named plugin folder. If the name is absolute then it is
* returned. Otherwise, for relative names, the classpath is scanned.
* @param name the name of a plugin folder
- * @return the plugin directory as a {@link File}
+ * @return the plugin directory as a {@link File}
*/
public File getPluginFolder(String name) {
File directory = new File(name);
@@ -180,7 +180,7 @@ public class PluginManifestParser {
}
PluginDescriptor pluginDescriptor = new PluginDescriptor(id, version, name,
providerName, pluginClazz, pPath, this.conf);
- LOG.debug("plugin: id={} name={} version={} provider={} class={}",
+ LOG.debug("plugin: id={} name={} version={} provider={} class={}",
id, name, version, providerName, pluginClazz);
parseExtension(rootElement, pluginDescriptor);
parseExtensionPoints(rootElement, pluginDescriptor);
diff --git a/src/java/org/apache/nutch/plugin/PluginRepository.java b/src/java/org/apache/nutch/plugin/PluginRepository.java
index 9db52a008..f2ae676bf 100644
--- a/src/java/org/apache/nutch/plugin/PluginRepository.java
+++ b/src/java/org/apache/nutch/plugin/PluginRepository.java
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
/**
* <p>The plugin repository is a registry of all plugins.</p>
- *
+ *
* <p>At system boot up a repository is built by parsing the manifest files of
* all plugins. Plugins that require other plugins which do not exist are not
* registered. For each plugin a plugin descriptor instance will be created. The
@@ -72,7 +72,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* @param conf a populated {@link Configuration}
- * @throws RuntimeException if a fatal runtime error is encountered
+ * @throws RuntimeException if a fatal runtime error is encountered
*/
public PluginRepository(Configuration conf) throws RuntimeException {
this.fActivatedPlugins = new HashMap<>();
@@ -232,7 +232,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* Returns all registered plugin descriptors.
- *
+ *
* @return PluginDescriptor[]
*/
public PluginDescriptor[] getPluginDescriptors() {
@@ -242,7 +242,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* Returns the descriptor of one plugin identified by a plugin id.
- *
+ *
* @param pPluginId a pluginId for which the descriptor will be retrieved
* @return PluginDescriptor
*/
@@ -257,7 +257,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* Returns a extension point identified by a extension point id.
- *
+ *
* @param pXpId an extension point id
* @return a extentsion point
*/
@@ -269,13 +269,13 @@ public class PluginRepository implements URLStreamHandlerFactory {
* <p>Returns an instance of a plugin. Plugin instances are cached. So a plugin
* exist only as one instance. This allow a central management of plugin's own
* resources.</p>
- *
+ *
* <p>After creating the plugin instance the startUp() method is invoked. The
* plugin use a own classloader that is used as well by all instance of
* extensions of the same plugin. This class loader use all exported libraries
* from the dependent plugins and all plugin libraries.</p>
- *
- * @param pDescriptor a {@link PluginDescriptor} for which to retrieve a
+ *
+ * @param pDescriptor a {@link PluginDescriptor} for which to retrieve a
* {@link Plugin} instance
* @return a {@link Plugin} instance
* @throws PluginRuntimeException if there is a fatal runtime plugin error
@@ -328,7 +328,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* Shuts down all plugins
- *
+ *
* @throws PluginRuntimeException
*/
private void shutDownActivatedPlugins() throws PluginRuntimeException {
@@ -379,7 +379,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
* Filters a list of plugins. The list of plugins is filtered regarding the
* configuration properties <code>plugin.excludes</code> and
* <code>plugin.includes</code>.
- *
+ *
* @param excludes
* @param includes
* @param plugins
@@ -424,7 +424,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
* output of another plugin. This method loads the plugins in the order
* defined by orderProperty. If orderProperty is empty or unset, all active
* plugins of the given interface and extension point are loaded.
- *
+ *
* @param clazz
* interface class implemented by required plugins
* @param xPointId
@@ -469,7 +469,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
Object f = filterMap.get(orderedFilter);
if (f == null) {
LOG.error("{} : {} declared in configuration property {} "
- + "but not found in an active plugin - ignoring.",
+ + "but not found in an active plugin - ignoring.",
clazz.getSimpleName(), orderedFilter, orderProperty);
continue;
}
@@ -494,7 +494,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* Loads all necessary dependencies for a selected plugin, and then runs one
* of the classes' main() method.
- *
+ *
* @param args
* plugin ID (needs to be activated in the configuration), and the
* class name. The rest of arguments is passed to the main method of
@@ -549,16 +549,16 @@ public class PluginRepository implements URLStreamHandlerFactory {
/**
* <p>Invoked whenever a {@link java.net.URL} needs to be instantiated. Tries to find a
- * suitable extension and allows it to provide a {@link java.net.URLStreamHandler}.</p>
+ * suitable extension and allows it to provide a {@link java.net.URLStreamHandler}.</p>
* This is done by several attempts:
* <ul>
* <li>Find a protocol plugin that implements the desired protocol. If found,
* instantiate it so eventually the plugin can install a {@link java.net.URLStreamHandler}
* through a static hook.</li>
- * <li>If the plugin specifies a {@link java.net.URLStreamHandler} in its
- * <code>plugin.xml</code> manifest, return an instance of this
+ * <li>If the plugin specifies a {@link java.net.URLStreamHandler} in its
+ * <code>plugin.xml</code> manifest, return an instance of this
* {@link java.net.URLStreamHandler}. Example:
- *
+ *
* <pre>
* ...
* &lt;implementation id="org.apache.nutch.protocol.foo.Foo" class="org.apache.nutch.protocol.foo.Foo"&gt;
@@ -571,7 +571,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
* <li>If all else fails, return null. This will fallback to the JVM's method
* of evaluating the system property <code>java.protocol.handler.pkgs</code>.</li>
* </ul>
- *
+ *
* @return the URLStreamHandler found, or null.
* @see java.net.URL
* @see <a href="https://issues.apache.org/jira/browse/NUTCH-2429">NUTCH-2429</a>
@@ -617,7 +617,7 @@ public class PluginRepository implements URLStreamHandlerFactory {
Class<?> clazz = cl.loadClass(handlerClass);
return (URLStreamHandler) clazz.getDeclaredConstructor().newInstance();
} catch (Exception e) {
- LOG.error("Could not instantiate protocol {} handler class {} defined by extension {}",
+ LOG.error("Could not instantiate protocol {} handler class {} defined by extension {}",
protocol, handlerClass, extension.getId(), e);
return null;
}
diff --git a/src/java/org/apache/nutch/plugin/PluginRuntimeException.java b/src/java/org/apache/nutch/plugin/PluginRuntimeException.java
index 58addfcf9..eec48bcf6 100644
--- a/src/java/org/apache/nutch/plugin/PluginRuntimeException.java
+++ b/src/java/org/apache/nutch/plugin/PluginRuntimeException.java
@@ -19,7 +19,7 @@ package org.apache.nutch.plugin;
/**
* <code>PluginRuntimeException</code> will be thrown until a exception in the
* plugin managemnt occurs.
- *
+ *
*/
public class PluginRuntimeException extends Exception {
diff --git a/src/java/org/apache/nutch/plugin/URLStreamHandlerFactory.java b/src/java/org/apache/nutch/plugin/URLStreamHandlerFactory.java
index e2956eb04..9d09b66e1 100644
--- a/src/java/org/apache/nutch/plugin/URLStreamHandlerFactory.java
+++ b/src/java/org/apache/nutch/plugin/URLStreamHandlerFactory.java
@@ -71,7 +71,7 @@ public class URLStreamHandlerFactory
* Protocols covered by standard JVM URL handlers. These protocols must not be
* handled by Nutch plugins, in order to avoid that basic actions (eg. loading
* of classes and configuration files) break.
- *
+ *
* Also the "ftp" protocol is included: it's usually supported by the standard
* JVM URL handler and Nutch does not yet provide a dedicated URL stream
* handler.
@@ -99,7 +99,7 @@ public class URLStreamHandlerFactory
}
}
- /**
+ /**
* Get the singleton instance of this class.
* @return a {@link org.apache.nutch.plugin.URLStreamHandlerFactory} instance
*/
@@ -108,7 +108,7 @@ public class URLStreamHandlerFactory
}
/** Use this method once a new PluginRepository was created to register it.
- *
+ *
* @param pr The PluginRepository to be registered.
*/
public void registerPluginRepository(PluginRepository pr) {
diff --git a/src/java/org/apache/nutch/plugin/package-info.java b/src/java/org/apache/nutch/plugin/package-info.java
index f7d95f9d4..843398b2c 100644
--- a/src/java/org/apache/nutch/plugin/package-info.java
+++ b/src/java/org/apache/nutch/plugin/package-info.java
@@ -15,16 +15,16 @@
* limitations under the License.
*/
-/**
+/**
* The Nutch {@link org.apache.nutch.plugin.Pluggable Plugin} System.
* <p><b>The Nutch Plugin System provides a way to extend nutch functionality</b>.
* A large part of the functionality of Nutch are provided by plugins:
- * All of the parsing, indexing and searching that nutch does is actually
+ * All of the parsing, indexing and searching that nutch does is actually
* accomplished by various plugins.</p>
- * <p>In writing a plugin, you're actually providing one or more extensions
- * of the existing extension-points (<i>hooks</i>). The core Nutch extension-points
+ * <p>In writing a plugin, you're actually providing one or more extensions
+ * of the existing extension-points (<i>hooks</i>). The core Nutch extension-points
* are themselves defined in a plugin, the <code>nutch-extensionpoints</code> plugin.
- * Each extension-point defines an interface that must be implemented by the
+ * Each extension-point defines an interface that must be implemented by the
* extension. The core extension-points and extensions available in Nutch are
* listed in the {@link org.apache.nutch.plugin.Pluggable} interface.</p>
* @see <a href="./doc-files/plugin.dtd">Nutch plugin manifest DTD</a>
diff --git a/src/java/org/apache/nutch/protocol/Content.java b/src/java/org/apache/nutch/protocol/Content.java
index edd117f3c..94cd2714d 100644
--- a/src/java/org/apache/nutch/protocol/Content.java
+++ b/src/java/org/apache/nutch/protocol/Content.java
@@ -229,7 +229,7 @@ public final class Content implements Writable {
/**
* The media type of the retrieved content.
- *
+ *
* @see <a href="http://www.iana.org/assignments/media-types/">
* http://www.iana.org/assignments/media-types/</a>
* @return content type
diff --git a/src/java/org/apache/nutch/protocol/ProtocolOutput.java b/src/java/org/apache/nutch/protocol/ProtocolOutput.java
index fb99be3d8..d4b650afe 100644
--- a/src/java/org/apache/nutch/protocol/ProtocolOutput.java
+++ b/src/java/org/apache/nutch/protocol/ProtocolOutput.java
@@ -24,7 +24,7 @@ import org.apache.nutch.net.protocols.Response;
/**
* Simple aggregate to pass from protocol plugins both content and protocol
* status.
- *
+ *
*/
public class ProtocolOutput {
private Content content;
diff --git a/src/java/org/apache/nutch/publisher/NutchPublisher.java b/src/java/org/apache/nutch/publisher/NutchPublisher.java
index 15fdacb25..60e713a5a 100644
--- a/src/java/org/apache/nutch/publisher/NutchPublisher.java
+++ b/src/java/org/apache/nutch/publisher/NutchPublisher.java
@@ -21,7 +21,7 @@ import org.apache.hadoop.conf.Configuration;
import org.apache.nutch.plugin.Pluggable;
/**
- * All publisher subscriber model implementations should implement this interface.
+ * All publisher subscriber model implementations should implement this interface.
*
*/
public interface NutchPublisher extends Configurable, Pluggable {
@@ -37,7 +37,7 @@ public interface NutchPublisher extends Configurable, Pluggable {
public boolean setConfig(Configuration conf);
/**
- * This method publishes the event. Make sure that the event is a Java POJO to avoid
+ * This method publishes the event. Make sure that the event is a Java POJO to avoid
* Jackson JSON conversion errors. Currently we use the FetcherThreadEvent
* @param event the {@link java.lang.Object} (event) to publish
* @param conf {@link org.apache.hadoop.conf.Configuration} to be used
diff --git a/src/java/org/apache/nutch/publisher/NutchPublishers.java b/src/java/org/apache/nutch/publisher/NutchPublishers.java
index bb608973e..18076424c 100644
--- a/src/java/org/apache/nutch/publisher/NutchPublishers.java
+++ b/src/java/org/apache/nutch/publisher/NutchPublishers.java
@@ -34,7 +34,7 @@ public class NutchPublishers extends Configured implements NutchPublisher{
public NutchPublishers(Configuration conf) {
this.conf = conf;
this.publishers = (NutchPublisher[])PluginRepository.get(conf).
- getOrderedPlugins(NutchPublisher.class,
+ getOrderedPlugins(NutchPublisher.class,
NutchPublisher.X_POINT_ID, "publisher.order");
}
@@ -45,14 +45,14 @@ public class NutchPublishers extends Configured implements NutchPublisher{
for(int i=0; i<this.publishers.length; i++) {
success |= this.publishers[i].setConfig(conf);
if(success)
- LOG.info("Successfully loaded {} publisher",
+ LOG.info("Successfully loaded {} publisher",
this.publishers[i].getClass().getName());
}
}catch(Exception e) {
LOG.warn("Error while loading publishers : {}", e.getMessage());
}
if(!success) {
- LOG.warn("Could not load any publishers out of {} publishers",
+ LOG.warn("Could not load any publishers out of {} publishers",
this.publishers.length);
}
return success;
@@ -64,7 +64,7 @@ public class NutchPublishers extends Configured implements NutchPublisher{
try{
this.publishers[i].publish(event, conf);
}catch(Exception e){
- LOG.warn("Could not post event to {}",
+ LOG.warn("Could not post event to {}",
this.publishers[i].getClass().getName());
}
}
@@ -77,6 +77,6 @@ public class NutchPublishers extends Configured implements NutchPublisher{
@Override
public void setConf(Configuration arg0) {
-
+
}
}
diff --git a/src/java/org/apache/nutch/scoring/ScoringFilter.java b/src/java/org/apache/nutch/scoring/ScoringFilter.java
index 3a3a9bfa8..360545a0d 100644
--- a/src/java/org/apache/nutch/scoring/ScoringFilter.java
+++ b/src/java/org/apache/nutch/scoring/ScoringFilter.java
@@ -32,11 +32,11 @@ import org.apache.nutch.protocol.Content;
/**
* A contract defining behavior of scoring plugins.
- *
+ *
* A scoring filter will manipulate scoring variables in CrawlDatum and in
* resulting search indexes. Filters can be chained in a specific order, to
* provide multi-stage scoring adjustments.
- *
+ *
*/
public interface ScoringFilter extends Configurable, Pluggable {
/** The name of the extension point. */
@@ -46,13 +46,13 @@ public interface ScoringFilter extends Configurable, Pluggable {
* Set an initial score for newly injected pages. Note: newly injected pages
* may have no inlinks, so filter implementations may wish to set this score
* to a non-zero value, to give newly injected pages some initial credit.
- *
+ *
* @param url
* url of the page
* @param datum
* new datum. Filters will modify it in-place.
- * @throws ScoringFilterException if there is a fatal error
- * setting an initial score for newly injected pages
+ * @throws ScoringFilterException if there is a fatal error
+ * setting an initial score for newly injected pages
*/
public void injectedScore(Text url, CrawlDatum datum)
throws ScoringFilterException;
@@ -63,13 +63,13 @@ public interface ScoringFilter extends Configurable, Pluggable {
* implementations may choose to set initial score to zero (unknown value),
* and then the inlink score contribution will set the "real" value of the new
* page.
- *
+ *
* @param url
* url of the page
* @param datum
* new datum. Filters will modify it in-place.
- * @throws ScoringFilterException if there is a fatal error
- * setting an initial score for newly discovered pages
+ * @throws ScoringFilterException if there is a fatal error
+ * setting an initial score for newly discovered pages
*/
public void initialScore(Text url, CrawlDatum datum)
throws ScoringFilterException;
@@ -77,7 +77,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
/**
* This method prepares a sort value for the purpose of sorting and selecting
* top N scoring pages during fetchlist generation.
- *
+ *
* @param url
* url of the page
* @param datum
@@ -86,8 +86,8 @@ public interface ScoringFilter extends Configurable, Pluggable {
* initial sort value, or a value from previous filters in chain
* @return a sort value for use in sorting and selecting the
* top N scoring pages during fetchlist generation
- * @throws ScoringFilterException if there is a fatal error
- * preparing the sort value
+ * @throws ScoringFilterException if there is a fatal error
+ * preparing the sort value
*/
public float generatorSortValue(Text url, CrawlDatum datum, float initSort)
throws ScoringFilterException;
@@ -98,7 +98,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* {@link org.apache.nutch.protocol.Content} metadata. This is needed in order
* to pass this value(s) to the mechanism that distributes it to outlinked
* pages.
- *
+ *
* @param url
* url of the page
* @param datum
@@ -106,7 +106,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* @param content
* instance of content. Implementations may modify this in-place,
* primarily by setting some metadata properties.
- * @throws ScoringFilterException if there is a fatal error
+ * @throws ScoringFilterException if there is a fatal error
* injecting score information from the current datum into
* {@link org.apache.nutch.protocol.Content} metadata
*/
@@ -117,7 +117,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* Currently a part of score distribution is performed using only data coming
* from the parsing process. We need this method in order to ensure the
* presence of score data in these steps.
- *
+ *
* @param url
* page url
* @param content
@@ -127,7 +127,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* target instance to copy the score information to. Implementations
* may modify this in-place, primarily by setting some metadata
* properties.
- * @throws ScoringFilterException if there is a fatal error
+ * @throws ScoringFilterException if there is a fatal error
* processing score data in subsequent steps after parsing
*/
public void passScoreAfterParsing(Text url, Content content, Parse parse)
@@ -135,7 +135,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
/**
* Distribute score value from the current page to all its outlinked pages.
- *
+ *
* @param fromUrl
* url of the source page
* @param parseData
@@ -156,8 +156,8 @@ public interface ScoringFilter extends Configurable, Pluggable {
* with status {@link CrawlDatum#STATUS_LINKED}, which contains
* adjustments to be applied to the original CrawlDatum score(s) and
* metadata. This can be null if not needed.
- * @throws ScoringFilterException there is a fatal error distributing
- * score data from the current page to all of its outlinks
+ * @throws ScoringFilterException there is a fatal error distributing
+ * score data from the current page to all of its outlinks
*/
public CrawlDatum distributeScoreToOutlinks(Text fromUrl,
ParseData parseData, Collection<Entry<Text, CrawlDatum>> targets,
@@ -167,7 +167,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* This method calculates a new score of CrawlDatum during CrawlDb update,
* based on the initial value of the original CrawlDatum, and also score
* values contributed by inlinked pages.
- *
+ *
* @param url
* url of the page
* @param old
@@ -184,7 +184,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* @param inlinked
* (partial) list of CrawlDatum-s (with their scores) from links
* pointing to this page, found in the current update batch.
- * @throws ScoringFilterException there is a fatal error calculating
+ * @throws ScoringFilterException there is a fatal error calculating
* a new score of {@link CrawlDatum} during CrawlDb update
*/
public void updateDbScore(Text url, CrawlDatum old, CrawlDatum datum,
@@ -200,7 +200,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
* CrawlDatum for page
* @throws ScoringFilterException if there is a fatal error whilst
* changing the score or status of {@link CrawlDatum} during
- * {@link org.apache.nutch.crawl.CrawlDb} update, when the URL is
+ * {@link org.apache.nutch.crawl.CrawlDb} update, when the URL is
* neither fetched nor has any inlinks
*/
public default void orphanedScore(Text url, CrawlDatum datum)
@@ -209,7 +209,7 @@ public interface ScoringFilter extends Configurable, Pluggable {
/**
* This method calculates a indexed document score/boost.
- *
+ *
* @param url
* url of the page
* @param doc
diff --git a/src/java/org/apache/nutch/scoring/ScoringFilterException.java b/src/java/org/apache/nutch/scoring/ScoringFilterException.java
index ffc41a1b0..57534c85e 100644
--- a/src/java/org/apache/nutch/scoring/ScoringFilterException.java
+++ b/src/java/org/apache/nutch/scoring/ScoringFilterException.java
@@ -18,7 +18,7 @@ package org.apache.nutch.scoring;
/**
* Specialized exception for errors during scoring.
- *
+ *
*/
@SuppressWarnings("serial")
public class ScoringFilterException extends Exception {
diff --git a/src/java/org/apache/nutch/scoring/ScoringFilters.java b/src/java/org/apache/nutch/scoring/ScoringFilters.java
index 7d4734568..caee8ff22 100644
--- a/src/java/org/apache/nutch/scoring/ScoringFilters.java
+++ b/src/java/org/apache/nutch/scoring/ScoringFilters.java
@@ -33,7 +33,7 @@ import org.apache.nutch.protocol.Content;
/**
* Creates and caches {@link ScoringFilter} implementing plugins.
- *
+ *
*/
public class ScoringFilters extends Configured implements ScoringFilter {
diff --git a/src/java/org/apache/nutch/scoring/webgraph/LinkDatum.java b/src/java/org/apache/nutch/scoring/webgraph/LinkDatum.java
index db98c69a4..a55465627 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/LinkDatum.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/LinkDatum.java
@@ -47,7 +47,7 @@ public class LinkDatum implements Writable {
/**
* Creates a LinkDatum with a given url. Timestamp is set to current time.
- *
+ *
* @param url
* The link url.
*/
@@ -58,7 +58,7 @@ public class LinkDatum implements Writable {
/**
* Creates a LinkDatum with a url and an anchor text. Timestamp is set to
* current time.
- *
+ *
* @param url
* The link url.
* @param anchor
diff --git a/src/java/org/apache/nutch/scoring/webgraph/LinkDumper.java b/src/java/org/apache/nutch/scoring/webgraph/LinkDumper.java
index 898495f57..1ed2c7961 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/LinkDumper.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/LinkDumper.java
@@ -215,7 +215,7 @@ public class LinkDumper extends Configured implements Tool {
/**
* Wraps all values in ObjectWritables.
*/
- public static class InvertMapper extends
+ public static class InvertMapper extends
Mapper<Text, Writable, Text, ObjectWritable> {
@Override
@@ -251,7 +251,7 @@ public class LinkDumper extends Configured implements Tool {
String fromUrl = key.toString();
List<LinkDatum> outlinks = new ArrayList<>();
Node node = null;
-
+
// loop through all values aggregating outlinks, saving node
for (ObjectWritable write : values) {
Object obj = write.get();
@@ -317,13 +317,13 @@ public class LinkDumper extends Configured implements Tool {
* Runs the inverter and merger jobs of the LinkDumper tool to create the url
* to inlink node database.
* @param webGraphDb the {@link org.apache.hadoop.fs.Path} to the output
- * of {@link org.apache.nutch.scoring.webgraph.WebGraph#createWebGraph(Path, Path[], boolean, boolean)}
+ * of {@link org.apache.nutch.scoring.webgraph.WebGraph#createWebGraph(Path, Path[], boolean, boolean)}
* @throws IOException if there is a fatal I/O issue at runtime
* @throws InterruptedException if the Job is interrupted during execution
- * @throws ClassNotFoundException if classes required to run
+ * @throws ClassNotFoundException if classes required to run
* the Job cannot be located
*/
- public void dumpLinks(Path webGraphDb) throws IOException,
+ public void dumpLinks(Path webGraphDb) throws IOException,
InterruptedException, ClassNotFoundException {
StopWatch stopWatch = new StopWatch();
diff --git a/src/java/org/apache/nutch/scoring/webgraph/Node.java b/src/java/org/apache/nutch/scoring/webgraph/Node.java
index d95ca9fc5..3535eb423 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/Node.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/Node.java
@@ -26,7 +26,7 @@ import org.apache.nutch.metadata.Metadata;
/**
* A class which holds the number of inlinks and outlinks for a given url along
* with an inlink score from a link analysis program and any metadata.
- *
+ *
* The Node is the core unit of the NodeDb in the WebGraph.
*/
public class Node implements Writable {
diff --git a/src/java/org/apache/nutch/scoring/webgraph/NodeDumper.java b/src/java/org/apache/nutch/scoring/webgraph/NodeDumper.java
index e88ef7986..4f75f2ccc 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/NodeDumper.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/NodeDumper.java
@@ -53,7 +53,7 @@ import org.apache.nutch.util.URLUtil;
* A tools that dumps out the top urls by number of inlinks, number of outlinks,
* or by score, to a text file. One of the major uses of this tool is to check
* the top scoring urls of a link analysis program such as LinkRank.
- *
+ *
* For number of inlinks or number of outlinks the WebGraph program will need to
* have been run. For link analysis score a program such as LinkRank will need
* to have been run which updates the NodeDb of the WebGraph.
@@ -86,7 +86,7 @@ public class NodeDumper extends Configured implements Tool {
* Outputs the url with the appropriate number of inlinks, outlinks, or for
* score.
*/
- public static class SorterMapper extends
+ public static class SorterMapper extends
Mapper<Text, Node, FloatWritable, Text> {
private Configuration conf;
@@ -127,7 +127,7 @@ public class NodeDumper extends Configured implements Tool {
*/
public static class SorterReducer extends
Reducer<FloatWritable, Text, Text, FloatWritable> {
-
+
private Configuration conf;
private long topn = Long.MAX_VALUE;
@@ -218,12 +218,12 @@ public class NodeDumper extends Configured implements Tool {
*/
public static class DumperReducer extends
Reducer<Text, FloatWritable, Text, FloatWritable> {
-
+
private Configuration conf;
private long topn = Long.MAX_VALUE;
private boolean sum = false;
-
- @Override
+
+ @Override
public void reduce(Text key, Iterable<FloatWritable> values,
Context context) throws IOException, InterruptedException {
@@ -265,24 +265,24 @@ public class NodeDumper extends Configured implements Tool {
/**
* Runs the process to dump the top urls out to a text file.
- *
+ *
* @param webGraphDb
- * The {@link org.apache.nutch.scoring.webgraph.WebGraph}
+ * The {@link org.apache.nutch.scoring.webgraph.WebGraph}
* from which to pull values.
- * @param type the node property type to dump, one of
- * {@link NodeDumper.DumpType#INLINKS}, {@link NodeDumper.DumpType#OUTLINKS}
+ * @param type the node property type to dump, one of
+ * {@link NodeDumper.DumpType#INLINKS}, {@link NodeDumper.DumpType#OUTLINKS}
* or {@link NodeDumper.DumpType#SCORES}
* @param topN maximum value of top links to dump
* @param output a {@link org.apache.hadoop.fs.Path} to write output to
- * @param asEff if true set equals-sign as separator for
+ * @param asEff if true set equals-sign as separator for
* <a href="https://lucene.apache.org/solr/api/org/apache/solr/schema/ExternalFileField.html">
* Solr's ExternalFileField</a>, false otherwise
- * @param nameType either {@link NodeDumper.NameType#HOST} or
+ * @param nameType either {@link NodeDumper.NameType#HOST} or
* {@link NodeDumper.NameType#DOMAIN}
- * @param aggrType the aggregation type, either
+ * @param aggrType the aggregation type, either
* {@link NodeDumper.AggrType#MAX} or {@link NodeDumper.AggrType#SUM}
- * @param asSequenceFile true output will be written as
- * {@link SequenceFileOutputFormat}, otherwise default
+ * @param asSequenceFile true output will be written as
+ * {@link SequenceFileOutputFormat}, otherwise default
* {@link TextOutputFormat}
* @throws Exception
* If an error occurs while dumping the top values.
diff --git a/src/java/org/apache/nutch/scoring/webgraph/NodeReader.java b/src/java/org/apache/nutch/scoring/webgraph/NodeReader.java
index 855b7d878..f48ed6789 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/NodeReader.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/NodeReader.java
@@ -52,12 +52,12 @@ public class NodeReader extends Configured {
/**
* Prints the content of the Node represented by the url to system out.
- *
+ *
* @param webGraphDb
* The webgraph from which to get the node.
* @param url
* The url of the node.
- *
+ *
* @throws IOException
* If an error occurs while getting the node.
*/
@@ -83,7 +83,7 @@ public class NodeReader extends Configured {
* Runs the NodeReader tool. The command line arguments must contain a
* webgraphdb path and a url. The url must match the normalized url that is
* contained in the NodeDb of the WebGraph.
- * @param args input parameters for running this tool, run with
+ * @param args input parameters for running this tool, run with
* "help" for information
* @throws Exception if there is a fatal error running this tool
*/
diff --git a/src/java/org/apache/nutch/scoring/webgraph/ScoreUpdater.java b/src/java/org/apache/nutch/scoring/webgraph/ScoreUpdater.java
index 235b19043..b20758937 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/ScoreUpdater.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/ScoreUpdater.java
@@ -82,7 +82,7 @@ public class ScoreUpdater extends Configured implements Tool{
* Creates new CrawlDatum objects with the updated score from the NodeDb or
* with a cleared score.
*/
- public static class ScoreUpdaterReducer extends
+ public static class ScoreUpdaterReducer extends
Reducer<Text, ObjectWritable, Text, CrawlDatum> {
private float clearScore = 0.0f;
@@ -140,7 +140,7 @@ public class ScoreUpdater extends Configured implements Tool{
/**
* Updates the inlink score in the web graph node database into the crawl
* database.
- *
+ *
* @param crawlDb
* The crawl database to update
* @param webGraphDb
@@ -148,7 +148,7 @@ public class ScoreUpdater extends Configured implements Tool{
* @throws IOException
* If an error occurs while updating the scores.
* @throws InterruptedException if the Job is interrupted during execution
- * @throws ClassNotFoundException if classes required to run
+ * @throws ClassNotFoundException if classes required to run
* the Job cannot be located
*/
public void update(Path crawlDb, Path webGraphDb) throws IOException,
diff --git a/src/java/org/apache/nutch/scoring/webgraph/WebGraph.java b/src/java/org/apache/nutch/scoring/webgraph/WebGraph.java
index f3999848e..ad21029ef 100644
--- a/src/java/org/apache/nutch/scoring/webgraph/WebGraph.java
+++ b/src/java/org/apache/nutch/scoring/webgraph/WebGraph.java
@@ -74,14 +74,14 @@ import org.apache.nutch.util.URLUtil;
* Creates three databases, one for inlinks, one for outlinks, and a node
* database that holds the number of in and outlinks to a url and the current
* score for the url.
- *
+ *
* The score is set by an analysis program such as LinkRank. The WebGraph is an
* update-able database. Outlinks are stored by their fetch time or by the
* current system time if no fetch time is available. Only the most recent
* version of outlinks for a given url is stored. As more crawls are executed
* and the WebGraph updated, newer Outlinks will replace older Outlinks. This
* allows the WebGraph to adapt to changes in the link structure of the web.
- *
+ *
* The Inlink database is created from the Outlink database and is regenerated
* when the WebGraph is updated. The Node database is created from both the
* Inlink and Outlink databases. Because the Node database is overwritten when
@@ -113,10 +113,10 @@ public class WebGraph extends Configured implements Tool {
/**
* Returns the fetch time from the parse data or the current system time if
* the fetch time doesn't exist.
- *
+ *
* @param data
* The parse data.
- *
+ *
* @return The fetch time as a long.
*/
private static long getFetchTime(ParseData data) {
@@ -165,10 +165,10 @@ public class WebGraph extends Configured implements Tool {
/**
* Normalizes and trims extra whitespace from the given url.
- *
+ *
* @param url
* The url to normalize.
- *
+ *
* @return The normalized url.
*/
private String normalizeUrl(String url) {
@@ -180,7 +180,7 @@ public class WebGraph extends Configured implements Tool {
String normalized = null;
if (urlNormalizers != null) {
try {
-
+
// normalize and trim the url
normalized = urlNormalizers.normalize(url,
URLNormalizers.SCOPE_DEFAULT);
@@ -195,10 +195,10 @@ public class WebGraph extends Configured implements Tool {
/**
* Filters the given url.
- *
+ *
* @param url
* The url to filter.
- *
+ *
* @return The filtered url or null.
*/
private String filterUrl(String url) {
@@ -207,7 +207,7 @@ public class WebGraph extends Configured implements Tool {
return url;
}
- try {
+ try {
url = filters.filter(url);
} catch (Exception e) {
url = null;
@@ -343,7 +343,7 @@ public class WebGraph extends Configured implements Tool {
ignoreDomain = conf.getBoolean("link.ignore.internal.domain", true);
limitPages = conf.getBoolean("link.ignore.limit.page", true);
limitDomains = conf.getBoolean("link.ignore.limit.domain", true);
-
+
// Initialize cached counter references
initCounters(context);
}
@@ -357,7 +357,7 @@ public class WebGraph extends Configured implements Tool {
removedLinksCounter = context.getCounter(
NutchMetrics.GROUP_WEBGRAPH, NutchMetrics.WEBGRAPH_REMOVED_LINKS_TOTAL);
}
-
+
@Override
public void reduce(Text key, Iterable<NutchWritable> values,
Context context)
@@ -480,7 +480,7 @@ public class WebGraph extends Configured implements Tool {
* Counts the number of inlinks and outlinks for each url and sets a default
* score of 0.0 for each url (node) in the webgraph.
*/
- public static class NodeDbReducer extends
+ public static class NodeDbReducer extends
Reducer<Text, LinkDatum, Text, Node> {
@Override
@@ -513,7 +513,7 @@ public class WebGraph extends Configured implements Tool {
* Creates the three different WebGraph databases, Outlinks, Inlinks, and
* Node. If a current WebGraph exists then it is updated, if it doesn't exist
* then a new WebGraph database is created.
- *
+ *
* @param webGraphDb
* The WebGraph to create or update.
* @param segments
@@ -523,15 +523,15 @@ public class WebGraph extends Configured implements Tool {
* whether to use URLNormalizers on URL's in the segment
* @param filter
* whether to use URLFilters on URL's in the segment
- *
+ *
* @throws IOException
* If an error occurs while processing the WebGraph.
* @throws InterruptedException if the Job is interrupted during execution
- * @throws ClassNotFoundException if classes required to run
+ * @throws ClassNotFoundException if classes required to run
* the Job cannot be located
*/
public void createWebGraph(Path webGraphDb, Path[] segments,
- boolean normalize, boolean filter) throws IOException,
+ boolean normalize, boolean filter) throws IOException,
InterruptedException, ClassNotFoundException {
StopWatch stopWatch = new StopWatch();
diff --git a/src/java/org/apache/nutch/segment/SegmentChecker.java b/src/java/org/apache/nutch/segment/SegmentChecker.java
index 7b02197cf..18cfec597 100644
--- a/src/java/org/apache/nutch/segment/SegmentChecker.java
+++ b/src/java/org/apache/nutch/segment/SegmentChecker.java
@@ -42,12 +42,12 @@ public class SegmentChecker {
/**
* Check if the segment is indexable. May add new check methods here.
* @param segmentPath path to an individual segment on disk
- * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
+ * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
* segment resides on
- * @return true if the checks pass and the segment can be indexed,
+ * @return true if the checks pass and the segment can be indexed,
* false otherwise
- * @throws IOException if there is an I/O error locating or
- * checking either the segment contents or locating it on
+ * @throws IOException if there is an I/O error locating or
+ * checking either the segment contents or locating it on
* the filesystem
*/
public static boolean isIndexable(Path segmentPath, FileSystem fs)
@@ -71,11 +71,11 @@ public class SegmentChecker {
/**
* Check the segment to see if it is valid based on the sub directories.
* @param segmentPath path to an individual segment on disk
- * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
+ * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
* segment resides on
* @return true if the checks pass false otherwise
- * @throws IOException if there is an I/O error locating or
- * checking either the segment contents or locating it on
+ * @throws IOException if there is an I/O error locating or
+ * checking either the segment contents or locating it on
* the filesystem
*/
public static boolean checkSegmentDir(Path segmentPath, FileSystem fs)
@@ -85,7 +85,7 @@ public class SegmentChecker {
LOG.warn("The input path at {} is not a segment... skipping", segmentPath.getName());
return false;
}
-
+
FileStatus[] fstats_segment = fs.listStatus(segmentPath,
HadoopFSUtil.getPassDirectoriesFilter(fs));
Path[] segment_files = HadoopFSUtil.getPaths(fstats_segment);
@@ -139,12 +139,12 @@ public class SegmentChecker {
/**
* Check the segment to see if it is has been parsed before.
* @param segment path to an individual segment on disk
- * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
+ * @param fs the {@link org.apache.hadoop.fs.FileSystem} that the
* segment resides on
- * @return true if the checks pass and the segment has been parsed,
+ * @return true if the checks pass and the segment has been parsed,
* false otherwise
- * @throws IOException if there is an I/O error locating or
- * checking either the segment contents or locating it on
+ * @throws IOException if there is an I/O error locating or
+ * checking either the segment contents or locating it on
* the filesystem
*/
public static boolean isParsed(Path segment, FileSystem fs)
diff --git a/src/java/org/apache/nutch/segment/SegmentMergeFilter.java b/src/java/org/apache/nutch/segment/SegmentMergeFilter.java
index c0c72c71b..0b6235e08 100644
--- a/src/java/org/apache/nutch/segment/SegmentMergeFilter.java
+++ b/src/java/org/apache/nutch/segment/SegmentMergeFilter.java
@@ -28,7 +28,7 @@ import org.apache.nutch.protocol.Content;
* Interface used to filter segments during segment merge. It allows filtering
* on more sophisticated criteria than just URLs. In particular it allows
* filtering based on metadata collected while parsing page.
- *
+ *
*/
public interface SegmentMergeFilter {
/** The name of the extension point. */
diff --git a/src/java/org/apache/nutch/segment/SegmentMergeFilters.java b/src/java/org/apache/nutch/segment/SegmentMergeFilters.java
index a75966e61..34fa7d6fe 100644
--- a/src/java/org/apache/nutch/segment/SegmentMergeFilters.java
+++ b/src/java/org/apache/nutch/segment/SegmentMergeFilters.java
@@ -37,7 +37,7 @@ import org.apache.nutch.protocol.Content;
* This class wraps all {@link SegmentMergeFilter} extensions in a single object
* so it is easier to operate on them. If any of extensions returns
* <code>false</code> this one will return <code>false</code> as well.
- *
+ *
*/
public class SegmentMergeFilters {
private static final Logger LOG = LoggerFactory
diff --git a/src/java/org/apache/nutch/segment/SegmentMerger.java b/src/java/org/apache/nutch/segment/SegmentMerger.java
index c14fcaf68..4e2d5785b 100644
--- a/src/java/org/apache/nutch/segment/SegmentMerger.java
+++ b/src/java/org/apache/nutch/segment/SegmentMerger.java
@@ -161,7 +161,7 @@ public class SegmentMerger extends Configured implements Tool{
private Writable w;
@Override
- public void initialize(InputSplit split, TaskAttemptContext context)
+ public void initialize(InputSplit split, TaskAttemptContext context)
throws IOException, InterruptedException {
splitReader.initialize(split, context);
}
@@ -295,7 +295,7 @@ public class SegmentMerger extends Configured implements Tool{
SequenceFile.Writer.blockSize(1073741824),
SequenceFile.Writer.compression(SequenceFileOutputFormat.getOutputCompressionType(context), new DefaultCodec()),
SequenceFile.Writer.progressable((Progressable)context),
- SequenceFile.Writer.metadata(new Metadata()));
+ SequenceFile.Writer.metadata(new Metadata()));
sliceWriters.put(slice + dirName, res);
return res;
@@ -421,14 +421,14 @@ public class SegmentMerger extends Configured implements Tool{
private SegmentMergeFilters mergeFilters = null;
private long sliceSize = -1;
- private long curCount = 0;
+ private long curCount = 0;
@Override
public void setup(Reducer<Text, MetaWrapper, Text, MetaWrapper>.Context context) {
Configuration conf = context.getConfiguration();
if (conf.getBoolean("segment.merger.filter", false)) {
mergeFilters = new SegmentMergeFilters(conf);
- }
+ }
sliceSize = conf.getLong("segment.merger.slice", -1);
if (sliceSize > 0) {
LOG.info("Slice size: {} URLs.", sliceSize);
diff --git a/src/java/org/apache/nutch/segment/SegmentPart.java b/src/java/org/apache/nutch/segment/SegmentPart.java
index 9e42ebfb3..5f6873355 100644
--- a/src/java/org/apache/nutch/segment/SegmentPart.java
+++ b/src/java/org/apache/nutch/segment/SegmentPart.java
@@ -22,7 +22,7 @@ import org.apache.hadoop.mapreduce.lib.input.FileSplit;
/**
* Utility class for handling information about segment parts.
- *
+ *
*/
public class SegmentPart {
/** Name of the segment (just the last path component). */
@@ -50,10 +50,10 @@ public class SegmentPart {
/**
* Create SegmentPart from a FileSplit.
- *
+ *
* @param split a {@link FileSplit} segment part
* @return a {@link SegmentPart} resultant from a {@link FileSplit}.
- * @throws IOException if there is a fatal error locating the split
+ * @throws IOException if there is a fatal error locating the split
*/
public static SegmentPart get(FileSplit split) throws IOException {
return get(split.getPath().toString());
@@ -61,7 +61,7 @@ public class SegmentPart {
/**
* Create SegmentPart from a full path of a location inside any segment part.
- *
+ *
* @param path
* full path into a segment part (may include "part-xxxxx"
* components)
@@ -94,7 +94,7 @@ public class SegmentPart {
/**
* Create SegmentPart from a String in format "segmentName/partName".
- *
+ *
* @param string
* input String
* @return parsed instance of SegmentPart
diff --git a/src/java/org/apache/nutch/tools/CommonCrawlFormat.java b/src/java/org/apache/nutch/tools/CommonCrawlFormat.java
index 1f7ae9634..3be4db04b 100644
--- a/src/java/org/apache/nutch/tools/CommonCrawlFormat.java
+++ b/src/java/org/apache/nutch/tools/CommonCrawlFormat.java
@@ -56,7 +56,7 @@ public interface CommonCrawlFormat extends Closeable {
* Returns a string representation of the JSON structure of the URL content.
* Takes into consideration the {@link Content}, {@link Metadata} and
* {@link ParseData}.
- *
+ *
* @param url the canonical url
* @param content url {@link Content}
* @param metadata url {@link Metadata}
diff --git a/src/java/org/apache/nutch/tools/CommonCrawlFormatFactory.java b/src/java/org/apache/nutch/tools/CommonCrawlFormatFactory.java
index 78239a854..c4cb57056 100644
--- a/src/java/org/apache/nutch/tools/CommonCrawlFormatFactory.java
+++ b/src/java/org/apache/nutch/tools/CommonCrawlFormatFactory.java
@@ -21,7 +21,7 @@ import java.io.IOException;
import org.apache.hadoop.conf.Configuration;
/**
- * Factory class that creates new {@link org.apache.nutch.tools.CommonCrawlFormat CommonCrawlFormat} objects (a.k.a. formatter) that map crawled files to CommonCrawl format.
+ * Factory class that creates new {@link org.apache.nutch.tools.CommonCrawlFormat CommonCrawlFormat} objects (a.k.a. formatter) that map crawled files to CommonCrawl format.
*
*/
public class CommonCrawlFormatFactory {
diff --git a/src/java/org/apache/nutch/tools/CommonCrawlFormatJettinson.java b/src/java/org/apache/nutch/tools/CommonCrawlFormatJettinson.java
index 169606c14..499530f41 100644
--- a/src/java/org/apache/nutch/tools/CommonCrawlFormatJettinson.java
+++ b/src/java/org/apache/nutch/tools/CommonCrawlFormatJettinson.java
@@ -28,7 +28,7 @@ import org.codehaus.jettison.json.JSONException;
import org.codehaus.jettison.json.JSONObject;
/**
- * This class provides methods to map crawled data on JSON using Jettinson APIs.
+ * This class provides methods to map crawled data on JSON using Jettinson APIs.
*
*/
public class CommonCrawlFormatJettinson extends AbstractCommonCrawlFormat {
diff --git a/src/java/org/apache/nutch/tools/CommonCrawlFormatSimple.java b/src/java/org/apache/nutch/tools/CommonCrawlFormatSimple.java
index c0cf64b6a..4a592a08d 100644
--- a/src/java/org/apache/nutch/tools/CommonCrawlFormatSimple.java
+++ b/src/java/org/apache/nutch/tools/CommonCrawlFormatSimple.java
@@ -24,7 +24,7 @@ import org.apache.nutch.protocol.Content;
/**
* This class provides methods to map crawled data on JSON using a StringBuilder object.
- * @see <a href='https://docs.oracle.com/javase/7/docs/api/java/lang/StringBuilder.html'>StringBuilder</a>
+ * @see <a href='https://docs.oracle.com/javase/7/docs/api/java/lang/StringBuilder.html'>StringBuilder</a>
*
*/
public class CommonCrawlFormatSimple extends AbstractCommonCrawlFormat {
diff --git a/src/java/org/apache/nutch/tools/FreeGenerator.java b/src/java/org/apache/nutch/tools/FreeGenerator.java
index 93eec6e53..2a90b9b1d 100644
--- a/src/java/org/apache/nutch/tools/FreeGenerator.java
+++ b/src/java/org/apache/nutch/tools/FreeGenerator.java
@@ -65,7 +65,7 @@ public class FreeGenerator extends Configured implements Tool {
public static class FGMapper extends
Mapper<WritableComparable<?>, Text, Text, Generator.SelectorEntry> {
-
+
private URLNormalizers normalizers = null;
private URLFilters filters = null;
private ScoringFilters scfilters;
diff --git a/src/java/org/apache/nutch/tools/WARCUtils.java b/src/java/org/apache/nutch/tools/WARCUtils.java
index 6b6f1cf01..abb009947 100644
--- a/src/java/org/apache/nutch/tools/WARCUtils.java
+++ b/src/java/org/apache/nutch/tools/WARCUtils.java
@@ -173,13 +173,13 @@ public class WARCUtils {
return record;
}
-
+
/**
* Modify verbatim HTTP response headers: fix, remove or replace headers
* <code>Content-Length</code>, <code>Content-Encoding</code> and
* <code>Transfer-Encoding</code> which may confuse WARC readers. Ensure that
* returned header end with a single empty line (<code>\r\n\r\n</code>).
- *
+ *
* @param headers
* HTTP 1.1 or 1.0 response header string, CR-LF-separated lines,
* first line is status line
@@ -279,5 +279,5 @@ public class WARCUtils {
return headers;
}
-
+
}
diff --git a/src/java/org/apache/nutch/tools/arc/ArcInputFormat.java b/src/java/org/apache/nutch/tools/arc/ArcInputFormat.java
index fd86d2f72..2d0650a64 100644
--- a/src/java/org/apache/nutch/tools/arc/ArcInputFormat.java
+++ b/src/java/org/apache/nutch/tools/arc/ArcInputFormat.java
@@ -34,23 +34,23 @@ import org.apache.hadoop.mapreduce.Mapper.Context;
* A input format the reads arc files.
*/
public class ArcInputFormat extends FileInputFormat<Text, BytesWritable> {
-
+
@Override
- public RecordReader<Text, BytesWritable> createRecordReader(InputSplit split,
+ public RecordReader<Text, BytesWritable> createRecordReader(InputSplit split,
TaskAttemptContext context){
return new SequenceFileRecordReader<Text, BytesWritable>();
- }
+ }
/**
* Get the <code>RecordReader</code> for reading the arc file.
- *
+ *
* @param split
* The InputSplit of the arc file to process.
* @param job
* The job configuration.
* @param context
* The task context.
- * @return A configured {@link ArcRecordReader}
- * @throws IOException if there is a fatal I/O error reading
+ * @return A configured {@link ArcRecordReader}
+ * @throws IOException if there is a fatal I/O error reading
* the {@link InputSplit}
*/
public RecordReader<Text, BytesWritable> getRecordReader(InputSplit split,
diff --git a/src/java/org/apache/nutch/util/CommandRunner.java b/src/java/org/apache/nutch/util/CommandRunner.java
index 2515bf1c2..1b0a4d55c 100644
--- a/src/java/org/apache/nutch/util/CommandRunner.java
+++ b/src/java/org/apache/nutch/util/CommandRunner.java
@@ -75,8 +75,8 @@ public class CommandRunner {
/**
* Execute the command
* @return process exit value (return code) or -1 if timed out.
- * @throws IOException if there is a fatal error interfacing
- * with the environment in which the application is running.
+ * @throws IOException if there is a fatal error interfacing
+ * with the environment in which the application is running.
*/
public int exec() throws IOException {
Process proc = Runtime.getRuntime().exec(_command);
@@ -100,7 +100,7 @@ public class CommandRunner {
boolean _timedout = false;
long end = System.currentTimeMillis() + _timeout * 1000;
-
+
try {
if (_timeout == 0) {
_barrier.await();
diff --git a/src/java/org/apache/nutch/util/CrawlCompletionStats.java b/src/java/org/apache/nutch/util/CrawlCompletionStats.java
index 46d1505b6..ac815f74f 100644
--- a/src/java/org/apache/nutch/util/CrawlCompletionStats.java
+++ b/src/java/org/apache/nutch/util/CrawlCompletionStats.java
@@ -135,7 +135,7 @@ public class CrawlCompletionStats extends Configured implements Tool {
} else if (cli.getOptionValue("mode").equals("domain")) {
jobName = jobName + "Domain statistics";
mode = MODE_DOMAIN;
- }
+ }
Configuration conf = getConf();
conf.setInt("domain.statistics.mode", mode);
diff --git a/src/java/org/apache/nutch/util/DomUtil.java b/src/java/org/apache/nutch/util/DomUtil.java
index c31c2a1f0..669cbbf1b 100644
--- a/src/java/org/apache/nutch/util/DomUtil.java
+++ b/src/java/org/apache/nutch/util/DomUtil.java
@@ -48,7 +48,7 @@ public class DomUtil {
/**
* Returns parsed dom tree or null if any error
- *
+ *
* @param is XML {@link InputStream}
* @return A parsed DOM tree from the given {@link InputStream}.
*/
@@ -81,7 +81,7 @@ public class DomUtil {
/**
* Save dom into {@link OutputStream}
- *
+ *
* @param os Output DOM XML stream to save to
* @param e A specific DOM {@link org.w3c.dom.Element} to save
*/
@@ -106,7 +106,7 @@ public class DomUtil {
/**
* Save dom into {@link OutputStream}
- *
+ *
* @param os Output DOM XML stream to save to
* @param doc A specific DOM {@link org.w3c.dom.DocumentFragment} to save
*/
diff --git a/src/java/org/apache/nutch/util/DomainStatistics.java b/src/java/org/apache/nutch/util/DomainStatistics.java
index 4057795d5..62600ffb9 100644
--- a/src/java/org/apache/nutch/util/DomainStatistics.java
+++ b/src/java/org/apache/nutch/util/DomainStatistics.java
@@ -76,7 +76,7 @@ public class DomainStatistics extends Configured implements Tool {
System.err.println("\t\t\t\ttld\tGather statistics by top level directory");
System.err.println("\t[numOfReducers]\tOptional number of reduce jobs to use. Defaults to 1.");
-
+
return 1;
}
String inputDir = args[0];
diff --git a/src/java/org/apache/nutch/util/FSUtils.java b/src/java/org/apache/nutch/util/FSUtils.java
index 6aed8d591..97e63591d 100644
--- a/src/java/org/apache/nutch/util/FSUtils.java
+++ b/src/java/org/apache/nutch/util/FSUtils.java
@@ -32,7 +32,7 @@ public class FSUtils {
* Replaces the current path with the new path and if set removes the old
* path. If removeOld is set to false then the old path will be set to the
* name current.old.
- *
+ *
* @param fs
* The FileSystem.
* @param current
@@ -41,7 +41,7 @@ public class FSUtils {
* The path to replace with.
* @param removeOld
* True if we are removing the current path.
- *
+ *
* @throws IOException
* If an error occurs during replacement.
*/
@@ -63,7 +63,7 @@ public class FSUtils {
/**
* Closes a group of SequenceFile readers.
- *
+ *
* @param readers
* The SequenceFile readers to close.
* @throws IOException
@@ -85,7 +85,7 @@ public class FSUtils {
/**
* Closes a group of MapFile readers.
- *
+ *
* @param readers
* The MapFile readers to close.
* @throws IOException
diff --git a/src/java/org/apache/nutch/util/LockUtil.java b/src/java/org/apache/nutch/util/LockUtil.java
index aebaf97f9..b2f6d9674 100644
--- a/src/java/org/apache/nutch/util/LockUtil.java
+++ b/src/java/org/apache/nutch/util/LockUtil.java
@@ -24,13 +24,13 @@ import org.apache.hadoop.fs.Path;
/**
* Utility methods for handling application-level locking.
- *
+ *
*/
public class LockUtil {
/**
* Create a lock file.
- *
+ *
* @param fs
* filesystem
* @param lockFile
@@ -82,7 +82,7 @@ public class LockUtil {
/**
* Remove lock file. NOTE: applications enforce the semantics of this file -
* this method simply removes any file with a given name.
- *
+ *
* @param fs
* filesystem
* @param lockFile
diff --git a/src/java/org/apache/nutch/util/MimeUtil.java b/src/java/org/apache/nutch/util/MimeUtil.java
index eacd69a16..2ed2c5ab3 100644
--- a/src/java/org/apache/nutch/util/MimeUtil.java
+++ b/src/java/org/apache/nutch/util/MimeUtil.java
@@ -105,11 +105,11 @@ public final class MimeUtil {
/**
* Cleans a {@link MimeType} name by removing out the actual {@link MimeType},
* from a string of the form:
- *
+ *
* <pre>
* &lt;primary type&gt;/&lt;sub type&gt; ; &lt; optional params
* </pre>
- *
+ *
* @param origType
* The original mime type string to be cleaned.
* @return The primary type, and subtype, concatenated, e.g., the actual mime
@@ -140,7 +140,7 @@ public final class MimeUtil {
* the mime type. However, if <code>mime.type.magic</code> is enabled in
* {@link NutchConfiguration}, then mime type magic resolution is used to try
* and obtain a better-than-the-default approximation of the {@link MimeType}.
- *
+ *
* @param typeName
* The original mime type, returned from a {@link ProtocolOutput}.
* @param url
@@ -223,7 +223,7 @@ public final class MimeUtil {
/**
* Facade interface to Tika's underlying {@link MimeTypes#getMimeType(String)}
* method.
- *
+ *
* @param url
* A string representation of the document URL to sense the
* {@link org.apache.tika.mime.MimeType MimeType} for.
@@ -237,7 +237,7 @@ public final class MimeUtil {
/**
* A facade interface to Tika's underlying {@link MimeTypes#forName(String)}
* method.
- *
+ *
* @param name
* The name of a valid {@link MimeType} in the Tika mime registry.
* @return The object representation of the {@link MimeType}, if it exists, or
@@ -255,7 +255,7 @@ public final class MimeUtil {
/**
* Facade interface to Tika's underlying {@link MimeTypes#getMimeType(File)}
* method.
- *
+ *
* @param f
* The {@link File} to sense the {@link MimeType} for.
* @return The {@link MimeType} of the given {@link File}, or null if it
diff --git a/src/java/org/apache/nutch/util/NodeWalker.java b/src/java/org/apache/nutch/util/NodeWalker.java
index 9296d4717..57509b0db 100644
--- a/src/java/org/apache/nutch/util/NodeWalker.java
+++ b/src/java/org/apache/nutch/util/NodeWalker.java
@@ -28,7 +28,7 @@ import org.w3c.dom.NodeList;
* stack and all of its children are automatically added to the stack to be
* called in tree order.
* </p>
- *
+ *
* <p>
* Currently this class is not thread safe. It is assumed that only one thread
* will be accessing the <code>NodeWalker</code> at any given time.
@@ -43,7 +43,7 @@ public class NodeWalker {
/**
* Starts the {@link org.w3c.dom.Node} tree from the root node.
- *
+ *
* @param rootNode A root node which will contain all nodes
*/
public NodeWalker(Node rootNode) {
@@ -59,7 +59,7 @@ public class NodeWalker {
* of recursion. If there are no more nodes on the stack then null is
* returned.
* </p>
- *
+ *
* @return Node The next <code>Node</code> on the stack or null if there isn't
* a next node.
*/
@@ -91,12 +91,12 @@ public class NodeWalker {
* automatically added to the stack. You can call this method to remove those
* children from the stack.
* </p>
- *
+ *
* <p>
* This is useful when you don't want to process deeper into the current path
* of the node tree but you want to continue processing sibling nodes.
* </p>
- *
+ *
*/
public void skipChildren() {
@@ -112,7 +112,7 @@ public class NodeWalker {
/**
* Return the current node.
- *
+ *
* @return Node
*/
public Node getCurrentNode() {
@@ -121,7 +121,7 @@ public class NodeWalker {
/**
* @return returns true if there are more nodes on the current stack.
- *
+ *
*/
public boolean hasNext() {
return (nodes.size() > 0);
diff --git a/src/java/org/apache/nutch/util/NutchConfiguration.java b/src/java/org/apache/nutch/util/NutchConfiguration.java
index 627784608..d0b68ed1a 100644
--- a/src/java/org/apache/nutch/util/NutchConfiguration.java
+++ b/src/java/org/apache/nutch/util/NutchConfiguration.java
@@ -45,7 +45,7 @@ public class NutchConfiguration {
/**
* Retrieve a Nutch UUID of this configuration object, or null if the
* configuration was created elsewhere.
- *
+ *
* @param conf
* configuration instance
* @return uuid or null
@@ -69,7 +69,7 @@ public class NutchConfiguration {
/**
* Create a {@link Configuration} from supplied properties.
- *
+ *
* @param addNutchResources
* if true, then first <code>nutch-default.xml</code>, and then
* <code>nutch-site.xml</code> will be loaded prior to applying the
@@ -93,7 +93,7 @@ public class NutchConfiguration {
/**
* Add the standard Nutch resources to {@link Configuration}.
- *
+ *
* @param conf
* Configuration object to which configuration is to be added.
*/
diff --git a/src/java/org/apache/nutch/util/NutchTool.java b/src/java/org/apache/nutch/util/NutchTool.java
index a6a1cee4b..fddf4c487 100644
--- a/src/java/org/apache/nutch/util/NutchTool.java
+++ b/src/java/org/apache/nutch/util/NutchTool.java
@@ -39,9 +39,9 @@ public abstract class NutchTool extends Configured {
/**
* Runs the tool, using a map of arguments. May return results, or null.
* @param args a {@link Map} of arguments to be run with the tool
- * @param crawlId a crawl identifier to associate with the tool invocation
- * @return Map results object if tool executes successfully
- * otherwise null
+ * @param crawlId a crawl identifier to associate with the tool invocation
+ * @return Map results object if tool executes successfully
+ * otherwise null
* @throws Exception if there is an error during the tool execution
*/
public abstract Map<String, Object> run(Map<String, Object> args, String crawlId)
@@ -54,7 +54,7 @@ public abstract class NutchTool extends Configured {
public NutchTool(){
super(null);
}
-
+
@Override
public void setConf(Configuration conf) {
super.setConf(conf);
@@ -65,7 +65,7 @@ public abstract class NutchTool extends Configured {
/**
* Get relative progress of the tool. Progress is represented as a
- * float in range [0,1] where 1 is complete.
+ * float in range [0,1] where 1 is complete.
* @return a float in range [0,1].
*/
public float getProgress() {
@@ -91,7 +91,7 @@ public abstract class NutchTool extends Configured {
/**
* Returns current status of the running tool
- * @return a populated {@link Map}, the fields
+ * @return a populated {@link Map}, the fields
* of which can be accessed to obtain status.
*/
public Map<String, Object> getStatus() {
@@ -101,7 +101,7 @@ public abstract class NutchTool extends Configured {
/**
* Stop the job with the possibility to resume. Subclasses should override
* this, since by default it calls {@link #killJob()}.
- *
+ *
* @return true if succeeded, false otherwise
* @throws Exception if there is an error stopping the current
* {@link org.apache.hadoop.mapreduce.Job}
@@ -113,7 +113,7 @@ public abstract class NutchTool extends Configured {
/**
* Kill the job immediately. Clients should assume that any results that the
* job produced so far are in an inconsistent state or missing.
- *
+ *
* @return true if succeeded, false otherwise.
* @throws Exception if there is an error stopping the current
* {@link org.apache.hadoop.mapreduce.Job}
diff --git a/src/java/org/apache/nutch/util/SegmentReaderUtil.java b/src/java/org/apache/nutch/util/SegmentReaderUtil.java
index fa9a7c85e..9bd664bea 100644
--- a/src/java/org/apache/nutch/util/SegmentReaderUtil.java
+++ b/src/java/org/apache/nutch/util/SegmentReaderUtil.java
@@ -26,7 +26,7 @@ import org.apache.hadoop.io.SequenceFile;
import org.apache.hadoop.conf.Configuration;
public class SegmentReaderUtil{
-
+
public static SequenceFile.Reader[] getReaders(Path dir, Configuration conf) throws IOException{
FileSystem fs = dir.getFileSystem(conf);
Path[] names = FileUtil.stat2Paths(fs.listStatus(dir));
diff --git a/src/java/org/apache/nutch/util/StringUtil.java b/src/java/org/apache/nutch/util/StringUtil.java
index c8a84c298..b44ea8f8e 100644
--- a/src/java/org/apache/nutch/util/StringUtil.java
+++ b/src/java/org/apache/nutch/util/StringUtil.java
@@ -25,9 +25,9 @@ import java.util.regex.Pattern;
public class StringUtil {
/**
- * Returns a copy of <code>s</code> (right padded) with trailing
- * spaces so that it's length is <code>length</code>.
- * Strings already <code>length</code> characters long or longer
+ * Returns a copy of <code>s</code> (right padded) with trailing
+ * spaces so that it's length is <code>length</code>.
+ * Strings already <code>length</code> characters long or longer
* are not altered.
* @param s input string to be copied and processed
* @param length desired final length of padded string
@@ -41,10 +41,10 @@ public class StringUtil {
}
/**
- * Returns a copy of <code>s</code> (left padded) with leading
- * spaces so that it's length is <code>length</code>. Strings
+ * Returns a copy of <code>s</code> (left padded) with leading
+ * spaces so that it's length is <code>length</code>. Strings
* already <code>length</code> characters long or longer are not altered.
- * @param s input string to be copied and processed
+ * @param s input string to be copied and processed
* @param length desired final length of padded string
* @return the resulting padded string
*/
@@ -62,7 +62,7 @@ public class StringUtil {
/**
* Convenience call for {@link #toHexString(byte[], String, int)}, where
* <code>sep = null; lineLen = Integer.MAX_VALUE</code>.
- *
+ *
* @param buf input data for which to generate a hex string
* @return the hex string
*/
@@ -73,7 +73,7 @@ public class StringUtil {
/**
* Get a text representation of a byte[] as hexadecimal String, where each
* pair of hexadecimal digits corresponds to consecutive bytes in the array.
- *
+ *
* @param buf input data for which to generate a hex string
* @param sep
* separate every pair of hexadecimal digits with this separator, or
@@ -106,7 +106,7 @@ public class StringUtil {
* digits into a corresponding byte array. If the number of digits is not
* even, a '0' will be appended in the front of the String prior to
* conversion. Leading and trailing whitespace is ignored.
- *
+ *
* @param text
* input text
* @return converted byte array, or null if unable to convert
@@ -161,7 +161,7 @@ public class StringUtil {
/**
* Mask sensitive strings - passwords, etc.
- *
+ *
* @param str input string
* @return the masked string, all characters replaced by <code>*</code>
*/
@@ -171,7 +171,7 @@ public class StringUtil {
/**
* Mask sensitive strings - passwords, etc.
- *
+ *
* @param str input string
* @param mask
* char used for masking
@@ -187,7 +187,7 @@ public class StringUtil {
/**
* Mask sensitive strings - passwords, etc.
- *
+ *
* @param str input string
* @param pattern
* pattern which defines capturing groups to be masked in input
diff --git a/src/java/org/apache/nutch/util/TableUtil.java b/src/java/org/apache/nutch/util/TableUtil.java
index bd3c5c75a..88873ef82 100644
--- a/src/java/org/apache/nutch/util/TableUtil.java
+++ b/src/java/org/apache/nutch/util/TableUtil.java
@@ -5,9 +5,9 @@
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -32,7 +32,7 @@ public class TableUtil {
* <p>
* E.g. "http://bar.foo.com:8983/to/index.html?a=b" becomes
* "com.foo.bar:8983:http/to/index.html?a=b".
- *
+ *
* @param urlString
* url to be reversed
* @return Reversed url
@@ -49,7 +49,7 @@ public class TableUtil {
* <p>
* E.g. "http://bar.foo.com:8983/to/index.html?a=b" becomes
* "com.foo.bar:http:8983/to/index.html?a=b".
- *
+ *
* @param url
* url to be reversed
* @return Reversed url
@@ -112,7 +112,7 @@ public class TableUtil {
/**
* Given a reversed url, returns the reversed host E.g
* "com.foo.bar:http:8983/to/index.html?a=b" -&gt; "com.foo.bar"
- *
+ *
* @param reversedUrl
* Reversed url
* @return Reversed host
@@ -148,8 +148,8 @@ public class TableUtil {
/**
* Convert given Utf8 instance to String and and cleans out any offending "\uFFFD"
* from the String.
- *
- *
+ *
+ *
* @param utf8
* Utf8 object
* @return string-ifed Utf8 object or null if Utf8 instance is null
diff --git a/src/java/org/apache/nutch/util/TrieStringMatcher.java b/src/java/org/apache/nutch/util/TrieStringMatcher.java
index 0f615838d..36ef743d9 100644
--- a/src/java/org/apache/nutch/util/TrieStringMatcher.java
+++ b/src/java/org/apache/nutch/util/TrieStringMatcher.java
@@ -22,7 +22,7 @@ import java.util.ListIterator;
/**
* TrieStringMatcher is a base class for simple tree-based string matching.
- *
+ *
* This class is thread-safe during string matching but not when adding strings
* to the trie.
*/
diff --git a/src/java/overview.html b/src/java/overview.html
index 3de53a7d2..861668caf 100644
--- a/src/java/overview.html
+++ b/src/java/overview.html
@@ -5,9 +5,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/build-plugin.xml b/src/plugin/build-plugin.xml
index 069086336..0dd4da342 100755
--- a/src/plugin/build-plugin.xml
+++ b/src/plugin/build-plugin.xml
@@ -105,7 +105,7 @@
<antcall target="init-plugin"/>
</target>
- <!-- to be overridden by sub-projects -->
+ <!-- to be overridden by sub-projects -->
<target name="init-plugin"/>
<!--
@@ -131,8 +131,8 @@
<!-- ====================================================== -->
<target name="compile" depends="init,deps-jar, resolve-default">
<echo message="Compiling plugin: ${name}"/>
- <javac
- encoding="${build.encoding}"
+ <javac
+ encoding="${build.encoding}"
srcdir="${src.dir}"
includes="**/*.java"
destdir="${build.classes}"
@@ -149,7 +149,7 @@
<ant target="compile-core" inheritall="false" dir="${nutch.root}"/>
<ant target="compile"/>
</target>
-
+
<!-- ================================================================== -->
<!-- Make plugin .jar -->
<!-- ================================================================== -->
@@ -176,7 +176,7 @@
<!-- ================================================================== -->
<target name="deploy" depends="jar, deps-test">
<mkdir dir="${deploy.dir}"/>
- <copy file="plugin.xml" todir="${deploy.dir}"
+ <copy file="plugin.xml" todir="${deploy.dir}"
preservelastmodified="true"/>
<available property="lib-available"
file="${build.dir}/${name}.jar"/>
@@ -191,11 +191,11 @@
</target>
<!-- ================================================================== -->
- <!-- Compile test code -->
+ <!-- Compile test code -->
<!-- ================================================================== -->
<target name="compile-test" depends="resolve-test, compile, deps-test-compile" if="test.available">
- <javac
- encoding="${build.encoding}"
+ <javac
+ encoding="${build.encoding}"
srcdir="${src.test}"
includes="**/*.java"
destdir="${build.test}"
@@ -205,11 +205,11 @@
source="${javac.version}"
deprecation="${javac.deprecation}">
<classpath refid="test.classpath"/>
- </javac>
+ </javac>
</target>
<!-- ================================================================== -->
- <!-- Run unit tests -->
+ <!-- Run unit tests -->
<!-- ================================================================== -->
<target name="test" depends="compile-test, deploy" if="test.available">
<echo message="Testing plugin: ${name}"/>
diff --git a/src/plugin/creativecommons/README.txt b/src/plugin/creativecommons/README.txt
index d4d7b65bf..b010fa6c9 100644
--- a/src/plugin/creativecommons/README.txt
+++ b/src/plugin/creativecommons/README.txt
@@ -1 +1 @@
-Support for crawling and searching Creative-Commons licensed content.
+Support for crawling and searching Creative-Commons licensed content.
diff --git a/src/plugin/creativecommons/conf/nutch-site.xml b/src/plugin/creativecommons/conf/nutch-site.xml
index 4b343b2cc..c84a56682 100644
--- a/src/plugin/creativecommons/conf/nutch-site.xml
+++ b/src/plugin/creativecommons/conf/nutch-site.xml
@@ -52,7 +52,7 @@
<name>plugin.excludes</name>
<value>parse-(?!html).*</value>
<description>Exclude non-HTML content, since we don't know how to
- find a CC license in anything but HTML.
+ find a CC license in anything but HTML.
</description>
</property>
diff --git a/src/plugin/creativecommons/data/rel.html b/src/plugin/creativecommons/data/rel.html
index 3d11572d8..829b58648 100755
--- a/src/plugin/creativecommons/data/rel.html
+++ b/src/plugin/creativecommons/data/rel.html
@@ -17,6 +17,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head>
</head><body>
-<a rel="license" href="http://creativecommons.org/licenses/by-nc/2.0">CC by-nc</a>
+<a rel="license" href="http://creativecommons.org/licenses/by-nc/2.0">CC by-nc</a>
</body>
</html>
diff --git a/src/plugin/creativecommons/ivy.xml b/src/plugin/creativecommons/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/creativecommons/ivy.xml
+++ b/src/plugin/creativecommons/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/creativecommons/src/java/org/creativecommons/nutch/CCParseFilter.java b/src/plugin/creativecommons/src/java/org/creativecommons/nutch/CCParseFilter.java
index a092d5a2c..ce2b8298d 100644
--- a/src/plugin/creativecommons/src/java/org/creativecommons/nutch/CCParseFilter.java
+++ b/src/plugin/creativecommons/src/java/org/creativecommons/nutch/CCParseFilter.java
@@ -73,7 +73,7 @@ public class CCParseFilter implements HtmlParseFilter {
* @param base canonical url
* @param metadata url {@link org.apache.nutch.metadata.Metadata}
* @param conf a populated {@link org.apache.hadoop.conf.Configuration}
- * @throws ParseException if there is a fatal error or if
+ * @throws ParseException if there is a fatal error or if
* <code>creativecommons.exclude.unlicensed</code> is set to true
*/
public static void walk(Node doc, URL base, Metadata metadata,
diff --git a/src/plugin/exchange-jexl/README.md b/src/plugin/exchange-jexl/README.md
index 35a711b90..6d6ad51c1 100644
--- a/src/plugin/exchange-jexl/README.md
+++ b/src/plugin/exchange-jexl/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-exchange-jexl plugin for Nutch
+exchange-jexl plugin for Nutch
==============================
**exchange-jexl plugin** decides which index writer a document should be routed to, based on a JEXL expression.
@@ -25,16 +25,16 @@ exchange-jexl plugin for Nutch
The **exchange-jexl plugin** must be configured in the exchanges.xml file, included in the official Nutch distribution.
```xml
-<exchanges>
- <exchange id="<exchange_id>" class="org.apache.nutch.exchange.jexl.JexlExchange">
- <writers>
- ...
- </writers>
- <params>
+<exchanges>
+ <exchange id="<exchange_id>" class="org.apache.nutch.exchange.jexl.JexlExchange">
+ <writers>
+ ...
+ </writers>
+ <params>
<param name="expr" value="<jexl_expression>" />
- </params>
- </exchange>
- ...
+ </params>
+ </exchange>
+ ...
</exchanges>
```
diff --git a/src/plugin/exchange-jexl/ivy.xml b/src/plugin/exchange-jexl/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/exchange-jexl/ivy.xml
+++ b/src/plugin/exchange-jexl/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/exchange-jexl/plugin.xml b/src/plugin/exchange-jexl/plugin.xml
index 7507d2621..bc8a17fdb 100644
--- a/src/plugin/exchange-jexl/plugin.xml
+++ b/src/plugin/exchange-jexl/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/feed/build.xml b/src/plugin/feed/build.xml
index 7fe7050a1..250156137 100644
--- a/src/plugin/feed/build.xml
+++ b/src/plugin/feed/build.xml
@@ -19,7 +19,7 @@
<project name="feed" default="jar-core">
<import file="../build-plugin.xml" />
-
+
<!-- Build compilation dependencies -->
<target name="deps-jar">
<ant target="jar" inheritall="false" dir="../lib-xml"/>
@@ -38,7 +38,7 @@
dir="../nutch-extensionpoints" />
<ant target="deploy" inheritall="false" dir="../protocol-file" />
</target>
-
+
<!-- for junit test -->
<mkdir dir="${build.test}/data" />
<copy file="sample/rsstest.rss" todir="${build.test}/data" />
diff --git a/src/plugin/feed/ivy.xml b/src/plugin/feed/ivy.xml
index 6d5684d0c..166413018 100644
--- a/src/plugin/feed/ivy.xml
+++ b/src/plugin/feed/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -41,5 +41,5 @@
<exclude name="slf4j-api" />
</dependency>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/feed/plugin.xml b/src/plugin/feed/plugin.xml
index 41109c9d0..342bb28c7 100644
--- a/src/plugin/feed/plugin.xml
+++ b/src/plugin/feed/plugin.xml
@@ -25,15 +25,15 @@
<library name="rome-utils-1.5.1.jar" />
<library name="jdom-2.0.2.jar" />
</runtime>
-
+
<requires>
<import plugin="nutch-extensionpoints" />
<import plugin="lib-xml" />
</requires>
-
+
<extension id="org.apache.nutch.parse.feed" name="Feed Parser"
point="org.apache.nutch.parse.Parser">
-
+
<implementation id="org.apache.nutch.parse.feed.FeedParser"
class="org.apache.nutch.parse.feed.FeedParser">
<parameter name="contentType" value="application/rss+xml" />
diff --git a/src/plugin/feed/sample/rsstest.rss b/src/plugin/feed/sample/rsstest.rss
index 758f6a183..83caae152 100644
--- a/src/plugin/feed/sample/rsstest.rss
+++ b/src/plugin/feed/sample/rsstest.rss
@@ -18,19 +18,19 @@
<rss version="0.91">
<channel>
<title>TestChannel</title>
- <link>http://test.channel.com/</link>
- <description>Sample RSS File for Junit test</description>
+ <link>http://test.channel.com/</link>
+ <description>Sample RSS File for Junit test</description>
<language>en-us</language>
-
+
<item>
<title>Home Page of Chris Mattmann</title>
<link>http://www-scf.usc.edu/~mattmann/</link>
<description>Chris Mattmann's home page</description>
</item>
<item>
- <title>Awesome Open Source Search Engine</title>
- <link>http://www.nutch.org/</link>
- <description>Yup, that's what it is</description>
+ <title>Awesome Open Source Search Engine</title>
+ <link>http://www.nutch.org/</link>
+ <description>Yup, that's what it is</description>
</item>
</channel>
</rss>
diff --git a/src/plugin/feed/src/java/org/apache/nutch/indexer/feed/FeedIndexingFilter.java b/src/plugin/feed/src/java/org/apache/nutch/indexer/feed/FeedIndexingFilter.java
index 44971897c..a587e2252 100644
--- a/src/plugin/feed/src/java/org/apache/nutch/indexer/feed/FeedIndexingFilter.java
+++ b/src/plugin/feed/src/java/org/apache/nutch/indexer/feed/FeedIndexingFilter.java
@@ -32,11 +32,11 @@ import org.apache.nutch.parse.ParseData;
/**
* @since NUTCH-444
- *
+ *
* An {@link IndexingFilter} implementation to pull out the relevant
* extracted {@link Metadata} fields from the RSS feeds and into the
* index.
- *
+ *
*/
public class FeedIndexingFilter implements IndexingFilter {
@@ -50,7 +50,7 @@ public class FeedIndexingFilter implements IndexingFilter {
/**
* Extracts out the relevant fields:
- *
+ *
* <ul>
* <li>FEED_AUTHOR</li>
* <li>FEED_TAGS</li>
@@ -58,9 +58,9 @@ public class FeedIndexingFilter implements IndexingFilter {
* <li>FEED_UPDATED</li>
* <li>FEED</li>
* </ul>
- *
+ *
* And sends them to the {@link org.apache.nutch.indexer Indexer} for indexing within the Nutch index.
- *
+ *
*/
@Override
public NutchDocument filter(NutchDocument doc, Parse parse, Text url,
@@ -114,7 +114,7 @@ public class FeedIndexingFilter implements IndexingFilter {
/**
* Sets the {@link Configuration} object used to configure this
* {@link IndexingFilter}.
- *
+ *
* @param conf
* The {@link Configuration} object used to configure this
* {@link IndexingFilter}.
diff --git a/src/plugin/feed/src/test/org/apache/nutch/parse/feed/TestFeedParser.java b/src/plugin/feed/src/test/org/apache/nutch/parse/feed/TestFeedParser.java
index 5e5dccd3b..c133e6be7 100644
--- a/src/plugin/feed/src/test/org/apache/nutch/parse/feed/TestFeedParser.java
+++ b/src/plugin/feed/src/test/org/apache/nutch/parse/feed/TestFeedParser.java
@@ -37,10 +37,10 @@ import org.apache.nutch.util.NutchConfiguration;
import static org.junit.jupiter.api.Assertions.*;
/**
- *
- *
+ *
+ *
* Test Suite for the {@link FeedParser}.
- *
+ *
*/
public class TestFeedParser {
@@ -60,8 +60,8 @@ public class TestFeedParser {
* <li>http://www-scf.usc.edu/~mattmann/</li>
* <li>http://www.nutch.org</li>
* </ul>
- *
- *
+ *
+ *
* @throws ProtocolNotFound
* If the {@link Protocol}Layer cannot be loaded (required to fetch
* the {@link Content} for the RSS file).
diff --git a/src/plugin/headings/ivy.xml b/src/plugin/headings/ivy.xml
index 052a32bbd..da3013448 100644
--- a/src/plugin/headings/ivy.xml
+++ b/src/plugin/headings/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/index-anchor/ivy.xml b/src/plugin/index-anchor/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/index-anchor/ivy.xml
+++ b/src/plugin/index-anchor/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-anchor/plugin.xml b/src/plugin/index-anchor/plugin.xml
index 208594bc0..85beb3bb9 100644
--- a/src/plugin/index-anchor/plugin.xml
+++ b/src/plugin/index-anchor/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/index-anchor/src/test/org/apache/nutch/indexer/anchor/TestAnchorIndexingFilter.java b/src/plugin/index-anchor/src/test/org/apache/nutch/indexer/anchor/TestAnchorIndexingFilter.java
index 5c0b56e88..53352096a 100644
--- a/src/plugin/index-anchor/src/test/org/apache/nutch/indexer/anchor/TestAnchorIndexingFilter.java
+++ b/src/plugin/index-anchor/src/test/org/apache/nutch/indexer/anchor/TestAnchorIndexingFilter.java
@@ -32,8 +32,8 @@ import static org.junit.jupiter.api.Assertions.*;
/**
* JUnit test case which tests 1. that anchor text is obtained 2. that anchor
* deduplication functionality is working
- *
- *
+ *
+ *
*/
public class TestAnchorIndexingFilter {
diff --git a/src/plugin/index-arbitrary/ivy.xml b/src/plugin/index-arbitrary/ivy.xml
index 9feb1e1b4..cc8c49f6d 100644
--- a/src/plugin/index-arbitrary/ivy.xml
+++ b/src/plugin/index-arbitrary/ivy.xml
@@ -35,5 +35,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-arbitrary/src/java/org/apache/nutch/indexer/arbitrary/ArbitraryIndexingFilter.java b/src/plugin/index-arbitrary/src/java/org/apache/nutch/indexer/arbitrary/ArbitraryIndexingFilter.java
index 695e01b1c..901364985 100644
--- a/src/plugin/index-arbitrary/src/java/org/apache/nutch/indexer/arbitrary/ArbitraryIndexingFilter.java
+++ b/src/plugin/index-arbitrary/src/java/org/apache/nutch/indexer/arbitrary/ArbitraryIndexingFilter.java
@@ -39,7 +39,7 @@ import org.apache.hadoop.conf.Configuration;
* Adds arbitrary searchable fields to a document from the class and method
* the user identifies in the config. The user supplies the name of the field
* to add with the class and method names that supply the value.
- *
+ *
* Example:<br><br>
* &lt;property&gt;<br>
* &lt;name&gt;index.arbitrary.function.count&lt;/name&gt;<br>
@@ -83,37 +83,37 @@ public class ArbitraryIndexingFilter implements IndexingFilter {
/** How many arbitrary field definitions to set. */
private int arbitraryAddsCount = 0;
-
+
/** The name of the field to insert/overwrite in the NutchDocument */
private String fieldName;
-
+
/** The fully-qualified class name of the custom class to use for the
* new field. This class must be in the Nutch runtime classpath,
* e.g., nutch/lib/ dierctory. */
private String className;
-
+
/** The String values to pass to the custom class constructor. The plugin
* will add the document url as the first argument in className's
* String[] args. */
private String[] userConstrArgs;
-
+
/** The array where the plugin copies the url &amp; the userConstrArgs
* to create the instance of className. */
private String[] constrArgs;
-
+
/** The name of the method in the custom class to call. Its return value
* will become the value of fieldName in the NutchDocument. */
private String methodName;
-
+
/** The String values of the arguments to methodName. It's up to the
* developer of className to do any casts/conversions from String to
* another class in the code of className. */
private String[] methodArgs;
-
+
/** The result that returns from methodName. The plugin will set the value
* of fieldName to this. */
private Object result;
-
+
/** Optional flag to determine whether to overwrite the existing value in the
* NutchDocument fieldName if this is set to true. Default behavior is to
* add the value from calling methodName to existing values for fieldName. */
@@ -142,7 +142,7 @@ public class ArbitraryIndexingFilter implements IndexingFilter {
* {@code index.arbitrary.methodArgs}.<em>index</em>
* in nutch-default.xml or nutch-site.xml where <em>index</em> ranges from 0
* to {@code index.arbitrary.function.count} - 1.
- *
+ *
* @param doc
* The {@link NutchDocument} object
* @param parse
@@ -244,7 +244,7 @@ public class ArbitraryIndexingFilter implements IndexingFilter {
LOG.debug("{}.{}() returned {} for field {}.", className,
methodName, String.valueOf(result), String.valueOf(fieldName));
-
+
// If user chose to overwrite, remove existing value
if (overwrite) {
LOG.debug("overwrite == true for fieldName == {} ", fieldName);
diff --git a/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/Multiplier.java b/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/Multiplier.java
index 38875d0da..749be508d 100644
--- a/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/Multiplier.java
+++ b/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/Multiplier.java
@@ -22,11 +22,11 @@ public class Multiplier {
private float product = 1;
private static PrintStream err = System.err;
private static PrintStream out = System.out;
-
+
public Multiplier(String args[]) {
super();
}
-
+
public String getProduct(String args[]) {
int i = args.length - 1;
try {
diff --git a/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/TestArbitraryIndexingFilter.java b/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/TestArbitraryIndexingFilter.java
index 50a2103dd..6c49e1fa7 100644
--- a/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/TestArbitraryIndexingFilter.java
+++ b/src/plugin/index-arbitrary/src/test/org/apache/nutch/indexer/arbitrary/TestArbitraryIndexingFilter.java
@@ -60,7 +60,7 @@ public class TestArbitraryIndexingFilter {
/**
* Test adding field with arbitrary content from POJO
- *
+ *
* @throws Exception
*/
@Test
@@ -77,7 +77,7 @@ public class TestArbitraryIndexingFilter {
filter.setConf(conf);
doc = new NutchDocument();
-
+
try {
filter.filter(doc, parse, url, crawlDatum, inlinks);
} catch (Exception e) {
@@ -93,7 +93,7 @@ public class TestArbitraryIndexingFilter {
/**
* Test supplementing a doc field with arbitrary content from POJO
- *
+ *
* @throws Exception
*/
@Test
@@ -115,7 +115,7 @@ public class TestArbitraryIndexingFilter {
assertNotNull(filter, "No filter exists for testSupplementExistingField");
filter.setConf(conf);
-
+
doc = new NutchDocument();
assertNotNull(doc, "doc doesn't exist");
@@ -125,10 +125,10 @@ public class TestArbitraryIndexingFilter {
assertEquals(1, doc.getField("description").getValues().size(),
"field description does not have exactly one value");
-
+
assertTrue(doc.getField("description").getValues().contains("irrational"),
"field description does not have initial value 'irrational'");
-
+
try {
filter.filter(doc, parse, url, crawlDatum, inlinks);
} catch (Exception e) {
@@ -152,7 +152,7 @@ public class TestArbitraryIndexingFilter {
/**
* Test overwriting a doc field with arbitrary content from POJO
- *
+ *
* @throws Exception
*/
@Test
@@ -172,13 +172,13 @@ public class TestArbitraryIndexingFilter {
conf.set("index.arbitrary.constructorArgs.2","Popeye");
conf.set("index.arbitrary.methodName.2","getText");
conf.set("index.arbitrary.overwrite.2","true");
-
+
filter = new ArbitraryIndexingFilter();
assertNotNull(filter, "No filter exists for testOverwritingExistingField");
filter.setConf(conf);
assertNotNull(conf, "conf does not exist");
-
+
doc = new NutchDocument();
assertNotNull(doc, "doc does not exist");
@@ -197,7 +197,7 @@ public class TestArbitraryIndexingFilter {
assertTrue(doc.getField("philosopher").getValues().contains("Socrates"),
"field philosopher does not have initial value 'Socrates'");
-
+
try {
filter.filter(doc, parse, url, crawlDatum, inlinks);
} catch (Exception e) {
diff --git a/src/plugin/index-basic/ivy.xml b/src/plugin/index-basic/ivy.xml
index 90ae93703..1dcb81e9d 100644
--- a/src/plugin/index-basic/ivy.xml
+++ b/src/plugin/index-basic/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-basic/src/java/org/apache/nutch/indexer/basic/BasicIndexingFilter.java b/src/plugin/index-basic/src/java/org/apache/nutch/indexer/basic/BasicIndexingFilter.java
index 0eab1a772..89b449d07 100644
--- a/src/plugin/index-basic/src/java/org/apache/nutch/indexer/basic/BasicIndexingFilter.java
+++ b/src/plugin/index-basic/src/java/org/apache/nutch/indexer/basic/BasicIndexingFilter.java
@@ -55,7 +55,7 @@ public class BasicIndexingFilter implements IndexingFilter {
* configuration settings for adding basic searchable fields. See
* {@code indexer.add.domain}, {@code indexer.max.title.length},
* {@code indexer.max.content.length} in nutch-default.xml.
- *
+ *
* @param doc
* The {@link NutchDocument} object
* @param parse
diff --git a/src/plugin/index-basic/src/test/org/apache/nutch/indexer/basic/TestBasicIndexingFilter.java b/src/plugin/index-basic/src/test/org/apache/nutch/indexer/basic/TestBasicIndexingFilter.java
index 8b16add55..db5b8506c 100644
--- a/src/plugin/index-basic/src/test/org/apache/nutch/indexer/basic/TestBasicIndexingFilter.java
+++ b/src/plugin/index-basic/src/test/org/apache/nutch/indexer/basic/TestBasicIndexingFilter.java
@@ -39,8 +39,8 @@ import static org.junit.jupiter.api.Assertions.*;
* nutch-default.xml. 3. that title is truncated as per
* {@code indexer.max.title.length} in nutch-default.xml. 4. that content is
* truncated as per {@code indexer.max.content.length} in nutch-default.xml.
- *
- *
+ *
+ *
*/
public class TestBasicIndexingFilter {
diff --git a/src/plugin/index-geoip/ivy.xml b/src/plugin/index-geoip/ivy.xml
index db8f508dd..6c6de6293 100644
--- a/src/plugin/index-geoip/ivy.xml
+++ b/src/plugin/index-geoip/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -44,5 +44,5 @@
<exclude org="com.fasterxml.jackson.core" name="jackson-core" />
</dependency>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-geoip/src/java/org/apache/nutch/indexer/geoip/package-info.java b/src/plugin/index-geoip/src/java/org/apache/nutch/indexer/geoip/package-info.java
index 655018ed3..0fcf3af86 100644
--- a/src/plugin/index-geoip/src/java/org/apache/nutch/indexer/geoip/package-info.java
+++ b/src/plugin/index-geoip/src/java/org/apache/nutch/indexer/geoip/package-info.java
@@ -16,13 +16,13 @@
*/
/**
- * <p>This plugin implements an indexing filter which takes
- * advantage of the
+ * <p>This plugin implements an indexing filter which takes
+ * advantage of the
* <a href="https://github.com/maxmind/GeoIP2-java">GeoIP2-java API</a>.</p>
- * <p>The third party library distribution provides an API for the GeoIP2
- * <a href="https://dev.maxmind.com/geoip/geoip2/web-services/">Precision web services</a>
- * and <a href="https://dev.maxmind.com/geoip/geoip2/downloadable/">databases</a>.
- * The API also works with the free
+ * <p>The third party library distribution provides an API for the GeoIP2
+ * <a href="https://dev.maxmind.com/geoip/geoip2/web-services/">Precision web services</a>
+ * and <a href="https://dev.maxmind.com/geoip/geoip2/downloadable/">databases</a>.
+ * The API also works with the free
* <a href="https://dev.maxmind.com/geoip/geoip2/geolite2/">GeoLite2 databases</a>.
*
*/
diff --git a/src/plugin/index-geoip/src/test/org/apache/nutch/indexer/geoip/TestGeoIPIndexingFilter.java b/src/plugin/index-geoip/src/test/org/apache/nutch/indexer/geoip/TestGeoIPIndexingFilter.java
index cd75559ee..d4b810748 100644
--- a/src/plugin/index-geoip/src/test/org/apache/nutch/indexer/geoip/TestGeoIPIndexingFilter.java
+++ b/src/plugin/index-geoip/src/test/org/apache/nutch/indexer/geoip/TestGeoIPIndexingFilter.java
@@ -221,7 +221,7 @@ public class TestGeoIPIndexingFilter {
conf.set("index.geoip.db.connection", "GeoIP2-Connection-Type-Test.mmdb");
filter = new GeoIPIndexingFilter();
filter.setConf(conf);
-
+
// Use IP 1.0.0.1 which exists in Connection Type test database
// Note: This IP may not exist in the City database, so we just verify
// that Connection Type data is returned
@@ -285,7 +285,7 @@ public class TestGeoIPIndexingFilter {
public void testAddIfNotDuplicateNewField() {
NutchDocument testDoc = new NutchDocument();
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.1");
-
+
assertNotNull(testDoc.getFieldValue("ip"));
assertEquals("192.168.1.1", testDoc.getFieldValue("ip"));
assertEquals(1, testDoc.getField("ip").getValues().size());
@@ -297,12 +297,12 @@ public class TestGeoIPIndexingFilter {
@Test
public void testAddIfNotDuplicatePreventsDuplicates() {
NutchDocument testDoc = new NutchDocument();
-
+
// Add the same IP three times (simulating multiple database lookups)
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.1");
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.1");
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.1");
-
+
// Should only have one value
NutchField field = testDoc.getField("ip");
assertNotNull(field);
@@ -316,11 +316,11 @@ public class TestGeoIPIndexingFilter {
@Test
public void testAddIfNotDuplicateAllowsDifferentValues() {
NutchDocument testDoc = new NutchDocument();
-
+
// Add different IPs (this shouldn't happen in practice but tests the logic)
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.1");
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", "192.168.1.2");
-
+
// Should have two different values
NutchField field = testDoc.getField("ip");
assertNotNull(field);
@@ -335,10 +335,10 @@ public class TestGeoIPIndexingFilter {
@Test
public void testAddIfNotDuplicateNullValue() {
NutchDocument testDoc = new NutchDocument();
-
+
// Adding null should not create a field
GeoIPDocumentCreator.addIfNotDuplicate(testDoc, "ip", null);
-
+
assertNull(testDoc.getField("ip"));
}
@@ -376,7 +376,7 @@ public class TestGeoIPIndexingFilter {
conf.set("index.geoip.db.connection", "GeoIP2-Connection-Type-Test.mmdb");
filter = new GeoIPIndexingFilter();
filter.setConf(conf);
-
+
// Use IP 1.0.0.1 which exists in Connection Type test database
parseImpl.getData().getContentMeta().add("_ip_", "1.0.0.1");
try {
@@ -386,18 +386,18 @@ public class TestGeoIPIndexingFilter {
fail(e.getMessage());
}
assertNotNull(doc);
-
+
// Verify connection type data is present with specific network address field
assertEquals("Cable/DSL", doc.getFieldValue("connectionType"));
assertNotNull(doc.getFieldValue(GeoIPDocumentCreator.CONNECTION_NETWORK_ADDRESS));
-
+
// Verify the generic networkAddress field is NOT used
assertNull(doc.getField("networkAddress"));
-
+
// Verify IP field exists and has only one value (not duplicated)
NutchField ipField = doc.getField("ip");
assertNotNull(ipField);
- assertEquals(1, ipField.getValues().size(),
+ assertEquals(1, ipField.getValues().size(),
"IP field should have exactly one value, not duplicated across databases");
}
@@ -415,7 +415,7 @@ public class TestGeoIPIndexingFilter {
filter = new GeoIPIndexingFilter();
filter.setConf(conf);
// Configuration should be accepted without error (file missing is logged as warning)
- assertEquals("nonexistent-country-test.mmdb",
+ assertEquals("nonexistent-country-test.mmdb",
filter.getConf().get("index.geoip.db.country"));
}
diff --git a/src/plugin/index-jexl-filter/ivy.xml b/src/plugin/index-jexl-filter/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/index-jexl-filter/ivy.xml
+++ b/src/plugin/index-jexl-filter/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-jexl-filter/src/java/org/apache/nutch/indexer/jexl/package-info.java b/src/plugin/index-jexl-filter/src/java/org/apache/nutch/indexer/jexl/package-info.java
index 7ca13ef7f..8ca7b8387 100644
--- a/src/plugin/index-jexl-filter/src/java/org/apache/nutch/indexer/jexl/package-info.java
+++ b/src/plugin/index-jexl-filter/src/java/org/apache/nutch/indexer/jexl/package-info.java
@@ -16,8 +16,8 @@
*/
/**
- * <p>This plugin implements a dynamic indexing filter which uses JEXL
- * expressions to allow filtering based on the page's metadata
+ * <p>This plugin implements a dynamic indexing filter which uses JEXL
+ * expressions to allow filtering based on the page's metadata
* <p>Available primitives in the JEXL context:<ul>
* <li>status, fetchTime, modifiedTime, retries, interval, score, signature, url, text, title</li></ul>
* <p>Available objects in the JEXL context:<ul>
@@ -26,6 +26,6 @@
* Each property value is always an array of Strings (so if you expect one value, use [0])</li>
* <li>doc - contains all the NutchFields from the NutchDocument.<br>
* Each property value is always an array of Objects.</li></ul>
- *
+ *
*/
package org.apache.nutch.indexer.jexl;
\ No newline at end of file
diff --git a/src/plugin/index-links/ivy.xml b/src/plugin/index-links/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/index-links/ivy.xml
+++ b/src/plugin/index-links/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-metadata/ivy.xml b/src/plugin/index-metadata/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/index-metadata/ivy.xml
+++ b/src/plugin/index-metadata/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-metadata/src/java/org/apache/nutch/indexer/metadata/MetadataIndexer.java b/src/plugin/index-metadata/src/java/org/apache/nutch/indexer/metadata/MetadataIndexer.java
index a8eb8ef9b..63fe2bffe 100644
--- a/src/plugin/index-metadata/src/java/org/apache/nutch/indexer/metadata/MetadataIndexer.java
+++ b/src/plugin/index-metadata/src/java/org/apache/nutch/indexer/metadata/MetadataIndexer.java
@@ -48,7 +48,7 @@ public class MetadataIndexer implements IndexingFilter {
private static final String content_CONF_PROPERTY = "index.content.md";
private static final String separator_CONF_PROPERTY = "index.metadata.separator";
private static final String mvfields_CONF_PROPERTY = "index.metadata.multivalued.fields";
-
+
@Override
public NutchDocument filter(NutchDocument doc, Parse parse, Text url,
CrawlDatum datum, Inlinks inlinks) throws IndexingException {
@@ -88,7 +88,7 @@ public class MetadataIndexer implements IndexingFilter {
return doc;
}
-
+
protected void add(NutchDocument doc, String key, String value) {
if (separator == null || value.indexOf(separator) == -1 || !mvFields.contains(key)) {
value = value.trim();
@@ -112,7 +112,7 @@ public class MetadataIndexer implements IndexingFilter {
dbFieldnames = conf.getStrings(db_CONF_PROPERTY);
parseFieldnames = conf.getStrings(parse_CONF_PROPERTY);
contentFieldnames = conf.getStrings(content_CONF_PROPERTY);
-
+
separator = conf.get(separator_CONF_PROPERTY, null);
mvFields = new HashSet<>(
Arrays.asList(conf.getStrings(mvfields_CONF_PROPERTY, new String[0])));
diff --git a/src/plugin/index-more/ivy.xml b/src/plugin/index-more/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/index-more/ivy.xml
+++ b/src/plugin/index-more/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-more/src/java/org/apache/nutch/indexer/more/package-info.java b/src/plugin/index-more/src/java/org/apache/nutch/indexer/more/package-info.java
index bd20502a0..f8bd1a174 100644
--- a/src/plugin/index-more/src/java/org/apache/nutch/indexer/more/package-info.java
+++ b/src/plugin/index-more/src/java/org/apache/nutch/indexer/more/package-info.java
@@ -15,8 +15,8 @@
* limitations under the License.
*/
-/**
- * A more indexing plugin, adds "more" index fields:last modified
+/**
+ * A more indexing plugin, adds "more" index fields:last modified
* date, MIME type, content length.
*/
package org.apache.nutch.indexer.more;
diff --git a/src/plugin/index-replace/README.txt b/src/plugin/index-replace/README.txt
index 563c7fbca..1f54c1276 100644
--- a/src/plugin/index-replace/README.txt
+++ b/src/plugin/index-replace/README.txt
@@ -70,15 +70,15 @@ Plugin order
Testing your match patterns
Online Regexp testers like http://www.regexplanet.com/advanced/java/index.html
can help get the basics of your pattern working.
- To test in nutch:
- Prepare a test HTML file with the field contents you want to test.
+ To test in nutch:
+ Prepare a test HTML file with the field contents you want to test.
Place this in a directory accessible to nutch.
Use the file:/// syntax to list the test file(s) in a test/urls seed list.
See the nutch faq "index my local file system" for conf settings you will need.
(Note the urlmatch and hostmatch patterns may not conform to your test file host and url; This
test approach confirms only how your global matches behave, unless your urlmatch and hostmatch
patterns also match the file: URL pattern)
-
+
Run..
bin/nutch inject crawl/crawldb test
bin/nutch generate crawl/crawldb crawl/segments
diff --git a/src/plugin/index-replace/ivy.xml b/src/plugin/index-replace/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/index-replace/ivy.xml
+++ b/src/plugin/index-replace/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-replace/src/java/org/apache/nutch/indexer/replace/ReplaceIndexer.java b/src/plugin/index-replace/src/java/org/apache/nutch/indexer/replace/ReplaceIndexer.java
index 7f6ae8335..c21ae242d 100644
--- a/src/plugin/index-replace/src/java/org/apache/nutch/indexer/replace/ReplaceIndexer.java
+++ b/src/plugin/index-replace/src/java/org/apache/nutch/indexer/replace/ReplaceIndexer.java
@@ -41,10 +41,10 @@ import org.apache.nutch.parse.Parse;
/**
* Do pattern replacements on selected field contents prior to indexing.
- *
+ *
* To use this plugin, add <code>index-replace</code> to your
* <code>plugin.includes</code>. Example:
- *
+ *
* <pre>
* &lt;property&gt;
* &lt;name&gt;plugin.includes&lt;/name&gt;
@@ -55,11 +55,11 @@ import org.apache.nutch.parse.Parse;
* And then add the <code>index.replace.regexp</code> property to
* <code>conf/nutch-site.xml</code>. This contains a list of replacement
* instructions per field name, one per line. eg.
- *
+ *
* <pre>
* fieldname=/regexp/replacement/[flags]
* </pre>
- *
+ *
* <pre>
* &lt;property&gt;
* &lt;name&gt;index.replace.regexp&lt;/name&gt;
@@ -69,13 +69,13 @@ import org.apache.nutch.parse.Parse;
* &lt;/value&gt;
* &lt;/property&gt;
* </pre>
- *
+ *
* <code>hostmatch=</code> and <code>urlmatch=</code> lines indicate the match
* pattern for a host or url. The field replacements that follow this line will
* apply only to pages from the matching host or url. Replacements run in the
* order specified. Field names may appear multiple times if multiple
* replacements are needed.
- *
+ *
* The property format is defined in greater detail in
* <code>conf/nutch-default.xml</code>.
*
@@ -121,7 +121,7 @@ public class ReplaceIndexer implements IndexingFilter {
/**
* Parse the property value into a set of maps that store a list of
* replacements by field for each host and url configured into the property.
- *
+ *
* @param propertyValue
*/
private void parseConf(String propertyValue) {
@@ -248,7 +248,7 @@ public class ReplaceIndexer implements IndexingFilter {
/**
* Iterates through the replacement map provided, to update the fields in the
* Nutch Document.
- *
+ *
* @param doc
* the document we are modifying
* @param keyName
diff --git a/src/plugin/index-replace/src/test/org/apache/nutch/indexer/replace/TestIndexReplace.java b/src/plugin/index-replace/src/test/org/apache/nutch/indexer/replace/TestIndexReplace.java
index 170d9fa55..44d44db83 100644
--- a/src/plugin/index-replace/src/test/org/apache/nutch/indexer/replace/TestIndexReplace.java
+++ b/src/plugin/index-replace/src/test/org/apache/nutch/indexer/replace/TestIndexReplace.java
@@ -35,14 +35,14 @@ import static org.junit.jupiter.api.Assertions.*;
/**
* JUnit tests for the <code>index-replace</code> plugin.
- *
+ *
* In these tests, the sample file has some meta tags added to the Nutch
* document by the <code>index-metadata</code> plugin. The
* <code>index-replace</code> plugin is then used to either change (or not
* change) the fields depending on the various values of
* <code>index.replace.regexp</code> property being provided to Nutch.
- *
- *
+ *
+ *
*
*/
public class TestIndexReplace {
@@ -55,7 +55,7 @@ public class TestIndexReplace {
/**
* Run a test file through the Nutch parser and index filters.
- *
+ *
* @param fileName
* @param conf
* @return the Nutch document with the replace indexer applied
@@ -99,7 +99,7 @@ public class TestIndexReplace {
/**
* Test property parsing.
- *
+ *
* The filter does not expose details of the parse. So all we are checking is
* that the parse does not throw a runtime exception and that the value
* provided is the value returned.
@@ -134,7 +134,7 @@ public class TestIndexReplace {
/**
* Test metatag value replacement using global replacement settings.
- *
+ *
* The index.replace.regexp property does not use hostmatch or urlmatch, so
* all patterns are global.
*/
@@ -168,7 +168,7 @@ public class TestIndexReplace {
/**
* Test that invalid property settings are handled and ignored.
- *
+ *
* This test provides an invalid property setting that will fail property
* parsing and Pattern.compile. The expected outcome is that the patterns will
* not cause failure and the targeted fields will not be modified by the
@@ -241,7 +241,7 @@ public class TestIndexReplace {
/**
* Test URL pattern not matching.
- *
+ *
* Expected result is that the filter does not change the fields.
*/
@Test
@@ -278,7 +278,7 @@ public class TestIndexReplace {
/**
* Test a global pattern match for description and URL pattern match for
* keywords and author.
- *
+ *
* All three should be triggered. It also tests replacement groups.
*/
@Test
@@ -316,7 +316,7 @@ public class TestIndexReplace {
/**
* Test a global pattern match for description and URL pattern match for
* keywords and author.
- *
+ *
* Only the global match should be triggered.
*/
@Test
@@ -352,7 +352,7 @@ public class TestIndexReplace {
/**
* Test order-specific replacement settings.
- *
+ *
* This makes multiple replacements on the same field and will produce the
* expected value only if the replacements are run in the order specified.
*/
@@ -386,7 +386,7 @@ public class TestIndexReplace {
/**
* Test a replacement pattern that uses the flags feature.
- *
+ *
* A 2 is Pattern.CASE_INSENSITIVE. We look for upper case and expect to match
* any case.
*/
diff --git a/src/plugin/index-static/ivy.xml b/src/plugin/index-static/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/index-static/ivy.xml
+++ b/src/plugin/index-static/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/StaticFieldIndexer.java b/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/StaticFieldIndexer.java
index c022ca7c2..31f12889f 100644
--- a/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/StaticFieldIndexer.java
+++ b/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/StaticFieldIndexer.java
@@ -46,7 +46,7 @@ public class StaticFieldIndexer implements IndexingFilter {
/**
* The {@link StaticFieldIndexer} filter object which adds fields as per
* configuration setting. See {@code index.static} in nutch-default.xml.
- *
+ *
* @param doc
* The {@link NutchDocument} object
* @param parse
@@ -76,7 +76,7 @@ public class StaticFieldIndexer implements IndexingFilter {
/**
* Populate a HashMap from a list of fieldname:fieldcontent. See
* {@index.static} in nutch-default.xml.
- *
+ *
* @param fieldsString
* string containing field:value pairs
* @return HashMap of fields and their corresponding values
@@ -126,7 +126,7 @@ public class StaticFieldIndexer implements IndexingFilter {
/**
* Escapes any character that needs escaping so it can be used in a regexp.
- * @param in input string to escape-process
+ * @param in input string to escape-process
* @return the escaped string which can be used un regex operations
*/
protected String regexEscape(String in) {
diff --git a/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/package-info.java b/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/package-info.java
index 8c6eb3d2c..5defb5725 100644
--- a/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/package-info.java
+++ b/src/plugin/index-static/src/java/org/apache/nutch/indexer/staticfield/package-info.java
@@ -15,9 +15,9 @@
* limitations under the License.
*/
-/** A simple plugin called at indexing that adds fields with static data.
- * You can specify a list of fieldname:fieldcontent per nutch job.
- * It can be useful when collections can't be created by urlpatterns,
+/** A simple plugin called at indexing that adds fields with static data.
+ * You can specify a list of fieldname:fieldcontent per nutch job.
+ * It can be useful when collections can't be created by urlpatterns,
* like in subcollection, but on a job-basis.
*/
package org.apache.nutch.indexer.staticfield;
diff --git a/src/plugin/index-static/src/test/org/apache/nutch/indexer/staticfield/TestStaticFieldIndexerTest.java b/src/plugin/index-static/src/test/org/apache/nutch/indexer/staticfield/TestStaticFieldIndexerTest.java
index 8e421b2d9..4dbec98ee 100644
--- a/src/plugin/index-static/src/test/org/apache/nutch/indexer/staticfield/TestStaticFieldIndexerTest.java
+++ b/src/plugin/index-static/src/test/org/apache/nutch/indexer/staticfield/TestStaticFieldIndexerTest.java
@@ -33,7 +33,7 @@ import static org.junit.jupiter.api.Assertions.*;
* document 2. that empty {@code index.static} does not add anything to the
* document 3. that valid field:value pairs are added to the document 4. that
* fields and values added to the document are trimmed
- *
+ *
*/
public class TestStaticFieldIndexerTest {
@@ -58,7 +58,7 @@ public class TestStaticFieldIndexerTest {
/**
* Test that empty {@code index.static} does not add anything to the document
- *
+ *
* @throws Exception
*/
@Test
@@ -83,7 +83,7 @@ public class TestStaticFieldIndexerTest {
/**
* Test that valid field:value pairs are added to the document
- *
+ *
* @throws Exception
*/
@Test
diff --git a/src/plugin/indexer-cloudsearch/README.md b/src/plugin/indexer-cloudsearch/README.md
index a0609c0fb..9865b13eb 100644
--- a/src/plugin/indexer-cloudsearch/README.md
+++ b/src/plugin/indexer-cloudsearch/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-AWS CloudSearch plugin for Nutch
+AWS CloudSearch plugin for Nutch
================================
See [http://aws.amazon.com/cloudsearch/] for information on AWS CloudSearch.
@@ -49,16 +49,16 @@ Each parameter has the form `<param name="<name>" value="<value>"/>` and the par
Parameter Name | Description | Default value
--|--|--
-endpoint | Endpoint where service requests should be submitted. |
-region | Region name. |
+endpoint | Endpoint where service requests should be submitted. |
+region | Region name. |
batch.dump | **true** to store the JSON representation of the documents to a local temp dir. The files has the prefix "CloudSearch_" e.g. `/tmp/CloudSearch_4822180575734804454.json`. This temp file can be used as a template when defining the fields in the domain creation. | false
batch.maxSize | Maximum number of documents to send as a batch to CloudSearch. | -1
## Create a CloudSearch domain
-This can be done using the web console [https://eu-west-1.console.aws.amazon.com/cloudsearch/home?region=eu-west-1#]. You can use the temp file generated above to bootstrap the field definition.
+This can be done using the web console [https://eu-west-1.console.aws.amazon.com/cloudsearch/home?region=eu-west-1#]. You can use the temp file generated above to bootstrap the field definition.
-You can also create the domain using the AWS CLI [http://docs.aws.amazon.com/cloudsearch/latest/developerguide/creating-domains.html] and the `createCSDomain.sh` example script provided. This script is merely as starting point which you should further improve and fine tune.
+You can also create the domain using the AWS CLI [http://docs.aws.amazon.com/cloudsearch/latest/developerguide/creating-domains.html] and the `createCSDomain.sh` example script provided. This script is merely as starting point which you should further improve and fine tune.
Note that the creation of the domain can take some time. Once it is complete, note the document endpoint, or alternatively verify the region and domain name.
diff --git a/src/plugin/indexer-cloudsearch/ivy.xml b/src/plugin/indexer-cloudsearch/ivy.xml
index 0e53bbdc9..a9af5f6c8 100644
--- a/src/plugin/indexer-cloudsearch/ivy.xml
+++ b/src/plugin/indexer-cloudsearch/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<dependency org="com.amazonaws" name="aws-java-sdk-cloudsearch" rev="1.10.0"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/indexer-cloudsearch/plugin.xml b/src/plugin/indexer-cloudsearch/plugin.xml
index f18bc49ea..5776e2937 100644
--- a/src/plugin/indexer-cloudsearch/plugin.xml
+++ b/src/plugin/indexer-cloudsearch/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/indexer-csv/README.md b/src/plugin/indexer-csv/README.md
index 4d1288b19..612bc015d 100644
--- a/src/plugin/indexer-csv/README.md
+++ b/src/plugin/indexer-csv/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-indexer-csv plugin for Nutch
+indexer-csv plugin for Nutch
============================
**indexer-csv plugin** is used for writing documents to a CSV file. It does not work in distributed mode, the output is written to the local filesystem, not to HDFS, see [NUTCH-1541](https://issues.apache.org/jira/browse/NUTCH-1541). The configuration for the index writers is on **conf/index-writers.xml** file, included in the official Nutch distribution and it's as follow:
@@ -27,7 +27,7 @@ indexer-csv plugin for Nutch
</mapping>
<parameters>
...
- </parameters>
+ </parameters>
</writer>
```
diff --git a/src/plugin/indexer-csv/ivy.xml b/src/plugin/indexer-csv/ivy.xml
index 13abcc0c8..ea28dc225 100644
--- a/src/plugin/indexer-csv/ivy.xml
+++ b/src/plugin/indexer-csv/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -37,5 +37,5 @@
</publications>
<dependencies/>
-
+
</ivy-module>
diff --git a/src/plugin/indexer-csv/plugin.xml b/src/plugin/indexer-csv/plugin.xml
index 072c3ab1d..237ba3696 100644
--- a/src/plugin/indexer-csv/plugin.xml
+++ b/src/plugin/indexer-csv/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/indexer-csv/src/java/org/apache/nutch/indexwriter/csv/CSVConstants.java b/src/plugin/indexer-csv/src/java/org/apache/nutch/indexwriter/csv/CSVConstants.java
index aa927ced5..6359d859a 100644
--- a/src/plugin/indexer-csv/src/java/org/apache/nutch/indexwriter/csv/CSVConstants.java
+++ b/src/plugin/indexer-csv/src/java/org/apache/nutch/indexwriter/csv/CSVConstants.java
@@ -17,7 +17,7 @@
package org.apache.nutch.indexwriter.csv;
public interface CSVConstants {
-
+
String CSV_FIELDS = "fields";
String CSV_CHARSET = "charset";
diff --git a/src/plugin/indexer-dummy/README.md b/src/plugin/indexer-dummy/README.md
index a7fa53009..a35880588 100644
--- a/src/plugin/indexer-dummy/README.md
+++ b/src/plugin/indexer-dummy/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-indexer-dummy plugin for Nutch
+indexer-dummy plugin for Nutch
==============================
**indexer-dummy plugin** is used for writing "action"\t"url"\n lines to a plain text file for debugging purposes. It does not work in distributed mode, the output is written to the local filesystem, not to HDFS. The configuration for the index writers is on **conf/index-writers.xml** file, included in the official Nutch distribution and it's as follow:
@@ -27,7 +27,7 @@ indexer-dummy plugin for Nutch
</mapping>
<parameters>
...
- </parameters>
+ </parameters>
</writer>
```
diff --git a/src/plugin/indexer-dummy/ivy.xml b/src/plugin/indexer-dummy/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/indexer-dummy/ivy.xml
+++ b/src/plugin/indexer-dummy/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/indexer-dummy/plugin.xml b/src/plugin/indexer-dummy/plugin.xml
index 963c66a9f..8f566558b 100644
--- a/src/plugin/indexer-dummy/plugin.xml
+++ b/src/plugin/indexer-dummy/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/indexer-elastic/README.md b/src/plugin/indexer-elastic/README.md
index 3dfd888ff..bf7a5e736 100644
--- a/src/plugin/indexer-elastic/README.md
+++ b/src/plugin/indexer-elastic/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-indexer-elastic plugin for Nutch
+indexer-elastic plugin for Nutch
================================
**indexer-elastic plugin** is used for sending documents from one or more segments to an Elasticsearch server. The configuration for the index writers is on **conf/index-writers.xml** file, included in the official Nutch distribution and it's as follow:
@@ -27,7 +27,7 @@ indexer-elastic plugin for Nutch
</mapping>
<parameters>
...
- </parameters>
+ </parameters>
</writer>
```
@@ -47,7 +47,7 @@ Each parameter has the form `<param name="<name>" value="<value>"/>` and the par
Parameter Name | Description | Default value
--|--|--
-host | Comma-separated list of hostnames to send documents to using [TransportClient](https://static.javadoc.io/org.elasticsearch/elasticsearch/5.3.0/org/elasticsearch/client/transport/TransportClient.html). Either host and port must be defined. |
+host | Comma-separated list of hostnames to send documents to using [TransportClient](https://static.javadoc.io/org.elasticsearch/elasticsearch/5.3.0/org/elasticsearch/client/transport/TransportClient.html). Either host and port must be defined. |
port | The port to connect to using [TransportClient](https://static.javadoc.io/org.elasticsearch/elasticsearch/5.3.0/org/elasticsearch/client/transport/TransportClient.html). | 9300
scheme | The scheme (http or https) to connect to elastic server. | http
index | Default index to send documents to. | nutch
diff --git a/src/plugin/indexer-elastic/ivy.xml b/src/plugin/indexer-elastic/ivy.xml
index 04c1a071d..0bd5c3a64 100644
--- a/src/plugin/indexer-elastic/ivy.xml
+++ b/src/plugin/indexer-elastic/ivy.xml
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
-<!--
+<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
@@ -15,8 +15,8 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0" />
@@ -55,5 +55,5 @@
<dependency org="org.apache.lucene" name="lucene-spatial3d" rev="8.11.2"/>
<dependency org="org.apache.lucene" name="lucene-suggest" rev="8.11.2"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/indexer-elastic/plugin.xml b/src/plugin/indexer-elastic/plugin.xml
index ab7b3c2b0..61e1a465a 100644
--- a/src/plugin/indexer-elastic/plugin.xml
+++ b/src/plugin/indexer-elastic/plugin.xml
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
-<!--
+<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
diff --git a/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticConstants.java b/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticConstants.java
index a64566d4d..446b19797 100644
--- a/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticConstants.java
+++ b/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticConstants.java
@@ -20,7 +20,7 @@ public interface ElasticConstants {
String HOSTS = "host";
String PORT = "port";
String SCHEME = "scheme";
-
+
String USER = "username";
String PASSWORD = "password";
String USE_AUTH = "auth";
diff --git a/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticIndexWriter.java b/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticIndexWriter.java
index 0c8450e57..0e61a3d61 100644
--- a/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticIndexWriter.java
+++ b/src/plugin/indexer-elastic/src/java/org/apache/nutch/indexwriter/elastic/ElasticIndexWriter.java
@@ -157,7 +157,7 @@ public class ElasticIndexWriter implements IndexWriter {
* Generates a RestHighLevelClient with the hosts given
* @param parameters implementation specific {@link org.apache.nutch.indexer.IndexWriterParams}
* @return an initialized {@link org.elasticsearch.client.RestHighLevelClient}
- * @throws IOException if there is an error reading the
+ * @throws IOException if there is an error reading the
* {@link org.apache.nutch.indexer.IndexWriterParams}
*/
protected RestHighLevelClient makeClient(IndexWriterParams parameters)
diff --git a/src/plugin/indexer-kafka/ivy.xml b/src/plugin/indexer-kafka/ivy.xml
index ffba6746d..77c51ddf0 100644
--- a/src/plugin/indexer-kafka/ivy.xml
+++ b/src/plugin/indexer-kafka/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaConstants.java b/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaConstants.java
index f7223823b..b0528ac4d 100644
--- a/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaConstants.java
+++ b/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaConstants.java
@@ -22,7 +22,7 @@ public interface KafkaConstants {
public static final String PORT = "port";
public static final String KEY_SERIALIZER = "key.serializer";
- public static final String VALUE_SERIALIZER =
+ public static final String VALUE_SERIALIZER =
"value.serializer";
public static final String TOPIC = "topic";
public static final String MAX_DOC_COUNT = "max.doc.count";
diff --git a/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaIndexWriter.java b/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaIndexWriter.java
index d5bef2cb4..ff650841a 100644
--- a/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaIndexWriter.java
+++ b/src/plugin/indexer-kafka/src/java/org/apache/nutch/indexwriter/kafka/KafkaIndexWriter.java
@@ -70,7 +70,7 @@ public class KafkaIndexWriter implements IndexWriter {
public void open(IndexWriterParams params) throws IOException {
host = params.get(KafkaConstants.HOST);
port = params.getInt(KafkaConstants.PORT, 9092);
-
+
keySerializer = params.get(KafkaConstants.KEY_SERIALIZER,
"org.apache.kafka.common.serialization.ByteArraySerializer");
valueSerializer = params.get(KafkaConstants.VALUE_SERIALIZER,
@@ -79,14 +79,14 @@ public class KafkaIndexWriter implements IndexWriter {
maxDocCount = params.getInt(KafkaConstants.MAX_DOC_COUNT, 100);
inputDocs = new ArrayList<ProducerRecord<String, JsonNode>>(maxDocCount);
-
+
if (StringUtils.isBlank(host)) {
String message = "Missing host. It should be set in index-writers.xml";
message += "\n" + describe();
LOG.error(message);
throw new RuntimeException(message);
}
-
+
Properties configProperties = new Properties();
configProperties.put(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG,
host + ":" + port);
@@ -183,7 +183,7 @@ public class KafkaIndexWriter implements IndexWriter {
properties.put(KafkaConstants.KEY_SERIALIZER,
new AbstractMap.SimpleEntry<>(
"instruct how to turn the key object the user provides with their ProducerRecord into bytes",
- this.keySerializer));
+ this.keySerializer));
properties.put(KafkaConstants.VALUE_SERIALIZER,
new AbstractMap.SimpleEntry<>(
diff --git a/src/plugin/indexer-opensearch-1x/README.md b/src/plugin/indexer-opensearch-1x/README.md
index e5e76f0b6..a04d68625 100644
--- a/src/plugin/indexer-opensearch-1x/README.md
+++ b/src/plugin/indexer-opensearch-1x/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-indexer-opensearch1x plugin for Nutch
+indexer-opensearch1x plugin for Nutch
================================
**indexer-opensearch1x plugin** is used for sending documents from one or more segments to an OpenSearch server. The configuration for the index writers is on **conf/index-writers.xml** file, included in the official Nutch distribution and it's as follow:
@@ -27,7 +27,7 @@ indexer-opensearch1x plugin for Nutch
</mapping>
<parameters>
...
- </parameters>
+ </parameters>
</writer>
```
@@ -47,7 +47,7 @@ Each parameter has the form `<param name="<name>" value="<value>"/>` and the par
Parameter Name | Description | Default value
--|--|--
-host | Comma-separated list of hostnames to send documents to using [TransportClient](https://static.javadoc.io/org.opensearch/opensearch/1.3.8/org/opensearch/client/transport/TransportClient.html). Either host and port must be defined. |
+host | Comma-separated list of hostnames to send documents to using [TransportClient](https://static.javadoc.io/org.opensearch/opensearch/1.3.8/org/opensearch/client/transport/TransportClient.html). Either host and port must be defined. |
port | The port to connect to using [TransportClient](https://static.javadoc.io/org.opensearch/opensearch/1.3.8/org/opensearch/client/transport/TransportClient.html). | 9300
scheme | The scheme (http or https) to connect to OpenSearch server. | https
index | Default index to send documents to. | nutch
@@ -71,7 +71,7 @@ It is highly recommended that users use at least basic authentication (modify th
For a "getting started" level introduction to setting up a trust store, see: [Connecting java-high-level-rest-client](https://opensearch.org/blog/connecting-java-high-level-rest-client-with-opensearch-over-https/).
For a more in depth treatment, see: [Configuring TLS certificates](https://opensearch.org/docs/latest/security/configuration/tls/).
-Users may opt for 2-way TLS and skip basic authentication (`username` and `password`).
+Users may opt for 2-way TLS and skip basic authentication (`username` and `password`).
To do this, specify both the `trust.store.*` parameters and the `key.store.*` parameters.
If users do not specify at least 1-way TLS (trust-store), this indexer logs a warning that this is a bad idea(TM), and it will proceed by completely ignoring all the SSL security.
diff --git a/src/plugin/indexer-opensearch-1x/ivy.xml b/src/plugin/indexer-opensearch-1x/ivy.xml
index aef4c9c02..b5cc0f789 100644
--- a/src/plugin/indexer-opensearch-1x/ivy.xml
+++ b/src/plugin/indexer-opensearch-1x/ivy.xml
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
-<!--
+<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
@@ -15,8 +15,8 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0" />
@@ -59,5 +59,5 @@
<dependency org="org.apache.lucene" name="lucene-spatial3d" rev="8.11.2" />
<dependency org="org.apache.lucene" name="lucene-suggest" rev="8.11.2" />
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/indexer-opensearch-1x/plugin.xml b/src/plugin/indexer-opensearch-1x/plugin.xml
index ee0d45dc2..5623f7bc3 100644
--- a/src/plugin/indexer-opensearch-1x/plugin.xml
+++ b/src/plugin/indexer-opensearch-1x/plugin.xml
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
-<!--
+<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
diff --git a/src/plugin/indexer-rabbit/README.md b/src/plugin/indexer-rabbit/README.md
index a91c19e4b..deef6b564 100644
--- a/src/plugin/indexer-rabbit/README.md
+++ b/src/plugin/indexer-rabbit/README.md
@@ -49,13 +49,13 @@ Parameter Name | Description | Default value
--|--|--
server.uri | URI with connection parameters in the form `amqp://<hostname>:<port>/<virtualHost>` or `amqp://<username>:<password>@<hostname>:<port>/<virtualHost>`<br>Where:<ul><li>`<username>` is the username for RabbitMQ server.</li><li>`<password>` is the password for RabbitMQ server.</li><li>`<hostname>` is where the RabbitMQ server is running.</li><li>`<port>` is where the RabbitMQ server is listening.</li><li>`<virtualHost>` is where the exchange is and the user has access.</li></ul>A typical local RabbitMQ broker uses the well-known `guest`/`guest` account; include `username:password@` in the URI when required. | amqp://localhost:5672/
binding | Whether the relationship between an exchange and a queue is created automatically.<br>**NOTE:** Binding between exchanges is not supported. | false
-binding.arguments | Arguments used in binding. It must have the form `key1=value1,key2=value2`. This value is only used when the exchange's type is headers and the value of binding property is **true**. In other cases is ignored. |
-exchange.name | Name for the exchange where the messages will be sent. |
+binding.arguments | Arguments used in binding. It must have the form `key1=value1,key2=value2`. This value is only used when the exchange's type is headers and the value of binding property is **true**. In other cases is ignored. |
+exchange.name | Name for the exchange where the messages will be sent. |
exchange.options | Options used when the exchange is created. Only used when the value of `binding` property is **true**. It must have the form `type=<type>,durable=<durable>`<br>Where:<ul><li>`<type>` is **direct**, **topic**, **headers** or **fanout**</li><li>`<durable>` is **true** or **false** | type=direct,durable=true</li></ul>
queue.name | Name of the queue used to create the binding. Only used when the value of `binding` property is **true**. | nutch.queue
queue.options | Options used when the queue is created. Only used when the value of `binding` property is **true**. It must have the form `durable=<durable>,exclusive=<exclusive>,auto-delete=<auto-delete>,arguments=<arguments>`<br>Where:<ul><li>`<durable>` is **true** or **false**</li><li>`<exclusive>` is **true** or **false**</li><li>`<auto-delete>` is **true** or **false**</li><li>`<arguments>` must be the form `key1:value1;key2:value2` | durable=true,exclusive=false,auto-delete=false</li></ul>
routingkey | The routing key used to route messages in the exchange. It only makes sense when the exchange type is **topic** or **direct**. | Value of `queue.name` property
commit.mode | **single** if a message contains only one document. In this case, a header with the action (write, update or delete) will be added. **multiple** if a message contains all documents. | multiple
commit.size | Amount of documents to send into each message if the value of `commit.mode` property is **multiple**. In **single** mode this value represents the amount of messages to be sent. | 250
-headers.static | Headers to add to each message. It must have the form `key1=value1,key2=value2`. |
-headers.dynamic | Document's fields to add as headers to each message. It must have the form `field1,field2`. Only used when the value of `commit.mode` property is **single**. |
+headers.static | Headers to add to each message. It must have the form `key1=value1,key2=value2`. |
+headers.dynamic | Document's fields to add as headers to each message. It must have the form `field1,field2`. Only used when the value of `commit.mode` property is **single**. |
diff --git a/src/plugin/indexer-rabbit/ivy.xml b/src/plugin/indexer-rabbit/ivy.xml
index 54930331c..7e462660e 100644
--- a/src/plugin/indexer-rabbit/ivy.xml
+++ b/src/plugin/indexer-rabbit/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/indexer-rabbit/plugin.xml b/src/plugin/indexer-rabbit/plugin.xml
index 3848b26e8..958ca0299 100644
--- a/src/plugin/indexer-rabbit/plugin.xml
+++ b/src/plugin/indexer-rabbit/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
diff --git a/src/plugin/indexer-solr/README.md b/src/plugin/indexer-solr/README.md
index 3a27e4116..9b8560f8c 100644
--- a/src/plugin/indexer-solr/README.md
+++ b/src/plugin/indexer-solr/README.md
@@ -15,7 +15,7 @@
limitations under the License.
-->
-indexer-solr plugin for Nutch
+indexer-solr plugin for Nutch
=============================
**indexer-solr plugin** is used for sending documents from one or more segments to a Solr server. The configuration for the index writers is on **conf/index-writers.xml** file, included in the official Nutch distribution and it's as follow:
@@ -49,9 +49,9 @@ Parameter Name | Description | Default value
--|--|--
type | Specifies the [SolrClient](https://lucene.apache.org/solr/5_5_0/solr-solrj/org/apache/solr/client/solrj/SolrClient.html) implementation to use. This is a string value of one of the following **cloud** or **http**. The values represent [CloudSolrServer](https://lucene.apache.org/solr/5_5_0/solr-solrj/org/apache/solr/client/solrj/impl/CloudSolrServer.html) or [HttpSolrServer](https://lucene.apache.org/solr/5_5_0/solr-solrj/org/apache/solr/client/solrj/impl/HttpSolrServer.html) respectively. | http
url | Defines the fully qualified URL of Solr into which data should be indexed. Multiple URL can be provided using comma as a delimiter. When the value of type property is **cloud**, the URL should not include any collections or cores; just the root Solr path. | http://localhost:8983/solr/nutch
-collection | The collection used in requests. Only used when the value of type property is **cloud**. |
-weight.field | Field's name where the weight of the documents will be written. If it is empty no field will be used. |
-commitSize | Defines the number of documents to send to Solr in a single update batch. Decrease when handling very large documents to prevent Nutch from running out of memory.<br>**Note**: It does not explicitly trigger a server side commit. | 1000
+collection | The collection used in requests. Only used when the value of type property is **cloud**. |
+weight.field | Field's name where the weight of the documents will be written. If it is empty no field will be used. |
+commitSize | Defines the number of documents to send to Solr in a single update batch. Decrease when handling very large documents to prevent Nutch from running out of memory.<br>**Note**: It does not explicitly trigger a server side commit. | 1000
auth | Whether to enable HTTP basic authentication for communicating with Solr. Use the `username` and `password` properties to configure your credentials. | false
username | The username of Solr server. | username
password | The password of Solr server. | password
diff --git a/src/plugin/indexer-solr/ivy.xml b/src/plugin/indexer-solr/ivy.xml
index 4d2120955..5b2642ad7 100644
--- a/src/plugin/indexer-solr/ivy.xml
+++ b/src/plugin/indexer-solr/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0" />
diff --git a/src/plugin/indexer-solr/schema.xml b/src/plugin/indexer-solr/schema.xml
index 17f77534c..cf7759d92 100644
--- a/src/plugin/indexer-solr/schema.xml
+++ b/src/plugin/indexer-solr/schema.xml
@@ -68,7 +68,7 @@
<!-- The format for this date field is of the form 1995-12-31T23:59:59Z, and
is a more restricted form of the canonical representation of dateTime
- http://www.w3.org/TR/xmlschema-2/#dateTime
+ http://www.w3.org/TR/xmlschema-2/#dateTime
The trailing "Z" designates UTC time and is mandatory.
Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z
All other components are mandatory.
@@ -83,15 +83,15 @@
NOW/DAY+6MONTHS+3DAYS
... 6 months and 3 days in the future from the start of
the current day
-
+
Consult the DateField javadocs for more information.
Note: For faster range queries, consider the tdate type
-->
<fieldType name="date" class="solr.TrieDateField" omitNorms="true" precisionStep="0" positionIncrementGap="0"/>
-
+
<fieldType name="location" class="solr.LatLonPointSpatialField"/>
-
+
<!-- A Trie based date field for faster date range queries and date faceting. -->
<fieldType name="tdate" class="solr.TrieDateField" omitNorms="true" precisionStep="6" positionIncrementGap="0"/>
<fieldType name="tdates" class="solr.TrieDateField" docValues="true" precisionStep="6" positionIncrementGap="0" multiValued="true"/>
@@ -260,7 +260,7 @@
<!--
The DelimitedPayloadTokenFilter can put payloads on tokens... for example,
a token of "foo|1.4" would be indexed as "foo" with a payload of 1.4f
- Attributes of the DelimitedPayloadTokenFilterFactory :
+ Attributes of the DelimitedPayloadTokenFilterFactory :
"delimiter" - a one character delimiter. Default is | (pipe)
"encoder" - how to encode the following value into a playload
float -> org.apache.lucene.analysis.payloads.FloatEncoder,
@@ -355,7 +355,7 @@
<!-- fields for index-geoip plugin -->
<!-- Common fields -->
<field name="ip" type="string" stored="true" indexed="true"/>
-
+
<!-- Database-specific network address fields -->
<field name="anonymousNetworkAddress" type="string" stored="true" indexed="true"/>
<field name="asnNetworkAddress" type="string" stored="true" indexed="true"/>
@@ -364,7 +364,7 @@
<field name="countryNetworkAddress" type="string" stored="true" indexed="true"/>
<field name="domainNetworkAddress" type="string" stored="true" indexed="true"/>
<field name="insightsNetworkAddress" type="string" stored="true" indexed="true"/>
-
+
<!-- City database fields -->
<field name="cityName" type="string" stored="true" indexed="true"/>
<field name="cityConfidence" type="pint" stored="true" indexed="true"/>
@@ -384,19 +384,19 @@
<field name="postalCode" type="string" stored="true" indexed="true"/>
<field name="postalConfidence" type="pint" stored="true" indexed="true"/>
<field name="countryType" type="string" stored="true" indexed="true"/>
-
+
<!-- Subdivision fields (most specific) -->
<field name="mostSpecificSubDivName" type="string" stored="true" indexed="true"/>
<field name="mostSpecificSubDivIsoCode" type="string" stored="true" indexed="true"/>
<field name="mostSpecificSubDivConfidence" type="pint" stored="true" indexed="true"/>
<field name="mostSpecificSubDivGeoNameId" type="pint" stored="true" indexed="true"/>
-
+
<!-- Subdivision fields (least specific) -->
<field name="leastSpecificSubDivName" type="string" stored="true" indexed="true"/>
<field name="leastSpecificSubDivIsoCode" type="string" stored="true" indexed="true"/>
<field name="leastSpecificSubDivConfidence" type="pint" stored="true" indexed="true"/>
<field name="leastSpecificSubDivGeoNameId" type="pint" stored="true" indexed="true"/>
-
+
<!-- ASN/ISP database fields -->
<field name="autonomousSystemNumber" type="plong" stored="true" indexed="true"/>
<field name="autonomousSystemOrganization" type="string" stored="true" indexed="true"/>
@@ -405,13 +405,13 @@
<field name="isp" type="string" stored="true" indexed="true"/>
<field name="org" type="string" stored="true" indexed="true"/>
<field name="organization" type="string" stored="true" indexed="true"/>
-
+
<!-- Domain database fields -->
<field name="domain" type="string" stored="true" indexed="true"/>
-
+
<!-- Connection Type database fields -->
<field name="connectionType" type="string" stored="true" indexed="true"/>
-
+
<!-- Anonymous IP / Traits fields -->
<field name="isAnonymous" type="boolean" stored="true" indexed="true"/>
<field name="isAnonymousVpn" type="boolean" stored="true" indexed="true"/>
@@ -422,14 +422,14 @@
<field name="isTorExitNode" type="boolean" stored="true" indexed="true"/>
<field name="isAnycast" type="boolean" stored="true" indexed="true"/>
<field name="isLegitimateProxy" type="boolean" stored="true" indexed="true"/>
-
+
<!-- Mobile/Network traits fields -->
<field name="mobileCountryCode" type="string" stored="true" indexed="true"/>
<field name="mobileNetworkCode" type="string" stored="true" indexed="true"/>
<field name="staticIpScore" type="pfloat" stored="true" indexed="true"/>
<field name="userCount" type="pint" stored="true" indexed="true"/>
<field name="userType" type="string" stored="true" indexed="true"/>
-
+
<!-- Spatial location field (derived from latLon via copyField) -->
<field name="location" type="location" stored="true" indexed="true"/>
@@ -468,7 +468,7 @@
<!-- fields for creativecommons plugin -->
<field name="cc" type="string" stored="true" indexed="true" multiValued="true"/>
- <!-- fields for tld plugin -->
+ <!-- fields for tld plugin -->
<field name="tld" type="string" stored="false" indexed="false"/>
<!-- field containing segment's raw binary content if indexed with -addBinaryContent -->
diff --git a/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrIndexWriter.java b/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrIndexWriter.java
index 09ec93acb..fc4b6a3a1 100644
--- a/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrIndexWriter.java
+++ b/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrIndexWriter.java
@@ -278,7 +278,7 @@ public class SolrIndexWriter implements IndexWriter {
try {
LOG.info("SolrIndexer: deleting {}/{} documents", deleteIds.size(),
totalDeletes);
-
+
UpdateRequest req = new UpdateRequest();
req.deleteById(deleteIds);
req.setAction(UpdateRequest.ACTION.OPTIMIZE, false, false);
diff --git a/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrUtils.java b/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrUtils.java
index d307edc59..ab1f1613c 100644
--- a/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrUtils.java
+++ b/src/plugin/indexer-solr/src/java/org/apache/nutch/indexwriter/solr/SolrUtils.java
@@ -60,17 +60,17 @@ public class SolrUtils {
/**
* Creates a new SolrClient, passing an Authorization header on the requests'
* HTTP Header:
- *
+ *
* <pre>
* Authorization: headerName headerValue
* </pre>
- *
+ *
* ie.
- *
+ *
* <pre>
* Authorization: Bearer XXXXXXXXXXX
* </pre>
- *
+ *
* @param url
* Sorl URL
* @param headerName
@@ -100,17 +100,17 @@ public class SolrUtils {
/**
* Creates a new SolrClient, passing an Authorization header on the requests'
* HTTP Header:
- *
+ *
* <pre>
* Authorization: headerName headerValue
* </pre>
- *
+ *
* ie.
- *
+ *
* <pre>
* Authorization: Bearer XXXXXXXXXXX
* </pre>
- *
+ *
* @param url
* Solr URL
* @param headerName
@@ -130,7 +130,7 @@ public class SolrUtils {
/**
* Creates a new SolrClient, using Basic Authentication.
- *
+ *
* @param url
* Solr URL
* @param username
diff --git a/src/plugin/language-identifier/ivy.xml b/src/plugin/language-identifier/ivy.xml
index b588b1979..f182a1176 100644
--- a/src/plugin/language-identifier/ivy.xml
+++ b/src/plugin/language-identifier/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -45,5 +45,5 @@
<!-- exclusions of dependencies provided in Nutch core (ivy/ivy.xml) -->
</dependency>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/LanguageIndexingFilter.java b/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/LanguageIndexingFilter.java
index c88f1f005..754b92c7b 100644
--- a/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/LanguageIndexingFilter.java
+++ b/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/LanguageIndexingFilter.java
@@ -34,7 +34,7 @@ import org.apache.hadoop.conf.Configuration;
/**
* An {@link org.apache.nutch.indexer.IndexingFilter} that add a
* <code>lang</code> (language) field to the document.
- *
+ *
* It tries to find the language of the document by:
* <ul>
* <li>First, checking if {@link HTMLLanguageParser} add some language
@@ -43,7 +43,7 @@ import org.apache.hadoop.conf.Configuration;
* found</li>
* <li>Finally by analyzing the document content</li>
* </ul>
- *
+ *
*/
public class LanguageIndexingFilter implements IndexingFilter {
@@ -77,7 +77,7 @@ public class LanguageIndexingFilter implements IndexingFilter {
if (!indexLangs.isEmpty() && !indexLangs.contains(lang)) {
return null;
}
-
+
doc.add("lang", lang);
return doc;
diff --git a/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/package-info.java b/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/package-info.java
index b14730b11..0384a7894 100644
--- a/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/package-info.java
+++ b/src/plugin/language-identifier/src/java/org/apache/nutch/analysis/lang/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* <p>Text document language identifier.</p>
* <p>Language profiles are based on material from
* <a href="http://www.homepages.inf.ed.ac.uk/pkoehn/publications/europarl.ps">
diff --git a/src/plugin/lib-htmlunit/build.xml b/src/plugin/lib-htmlunit/build.xml
index 14f5d8f57..c69cf5bac 100644
--- a/src/plugin/lib-htmlunit/build.xml
+++ b/src/plugin/lib-htmlunit/build.xml
@@ -20,7 +20,7 @@
<import file="../build-plugin.xml"/>
<!-- Add compilation dependencies to classpath -->
- <path id="plugin.deps">
+ <path id="plugin.deps">
<fileset dir="${nutch.root}/build">
<include name="**/lib-http/*.jar" />
</fileset>
diff --git a/src/plugin/lib-htmlunit/ivy.xml b/src/plugin/lib-htmlunit/ivy.xml
index 63ae1e5d6..3cf89052f 100644
--- a/src/plugin/lib-htmlunit/ivy.xml
+++ b/src/plugin/lib-htmlunit/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -42,5 +42,5 @@
<dependency org="org.seleniumhq.selenium" name="htmlunit-driver" rev="4.7.0" />
<!-- end selenium dependencies -->
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebDriver.java b/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebDriver.java
index 1b16c3b93..9b63a4fdd 100644
--- a/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebDriver.java
+++ b/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebDriver.java
@@ -41,11 +41,11 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
private static boolean enableRedirect;
private static long javascriptTimeout;
private static int maxRedirects;
-
+
public HtmlUnitWebDriver() {
super(enableJavascript);
}
-
+
@Override
protected WebClient modifyWebClient(WebClient client) {
client.getOptions().setJavaScriptEnabled(enableJavascript);
@@ -58,7 +58,7 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
client.addWebWindowListener(new HtmlUnitWebWindowListener(maxRedirects));
return client;
}
-
+
public static WebDriver getDriverForPage(String url, Configuration conf) {
long pageLoadTimout = conf.getLong("page.load.delay", 3);
enableJavascript = conf.getBoolean("htmlunit.enable.javascript", true);
@@ -67,9 +67,9 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
int redirects = Integer.parseInt(conf.get("http.redirect.max", "0"));
enableRedirect = redirects > 0;
maxRedirects = redirects;
-
+
WebDriver driver = null;
-
+
try {
driver = new HtmlUnitWebDriver();
driver.manage().timeouts().pageLoadTimeout(Duration.of(pageLoadTimout,
@@ -91,11 +91,11 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
try {
if (conf.getBoolean("take.screenshot", false))
takeScreenshot(driver, conf);
-
+
String innerHtml = "";
if(enableJavascript) {
WebElement body = driver.findElement(By.tagName("body"));
- innerHtml = (String)((JavascriptExecutor)driver).executeScript("return arguments[0].innerHTML;", body);
+ innerHtml = (String)((JavascriptExecutor)driver).executeScript("return arguments[0].innerHTML;", body);
}
else
innerHtml = driver.getPageSource().replaceAll("&amp;", "&");
@@ -104,7 +104,7 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
TemporaryFilesystem.getDefaultTmpFS().deleteTemporaryFiles();
cleanUpDriver(driver);
throw new RuntimeException(e);
- }
+ }
}
public static void cleanUpDriver(WebDriver driver) {
@@ -140,7 +140,7 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
String innerHtml = "";
if(enableJavascript) {
WebElement body = driver.findElement(By.tagName("body"));
- innerHtml = (String)((JavascriptExecutor)driver).executeScript("return arguments[0].innerHTML;", body);
+ innerHtml = (String)((JavascriptExecutor)driver).executeScript("return arguments[0].innerHTML;", body);
}
else
innerHtml = driver.getPageSource().replaceAll("&amp;", "&");
@@ -169,7 +169,7 @@ public class HtmlUnitWebDriver extends HtmlUnitDriver {
}
InputStream is = new BufferedInputStream(new FileInputStream(srcFile));
IOUtils.copyBytes(is, os, conf);
- LOG.debug("Screenshot for {} successfully saved to: {} {}", url, screenshotPath, srcFile.getName());
+ LOG.debug("Screenshot for {} successfully saved to: {} {}", url, screenshotPath, srcFile.getName());
} else {
LOG.warn("Screenshot for {} not saved to HDFS (subsequently discarded) as value for "
+ "'screenshot.location' is absent from nutch-site.xml.", url);
diff --git a/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebWindowListener.java b/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebWindowListener.java
index c2b88a67e..d79a704e7 100644
--- a/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebWindowListener.java
+++ b/src/plugin/lib-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/HtmlUnitWebWindowListener.java
@@ -23,18 +23,18 @@ public class HtmlUnitWebWindowListener implements WebWindowListener {
private Integer redirectCount = 0;
private Integer maxRedirects = 0;
-
+
public HtmlUnitWebWindowListener() {
-
+
}
-
+
public HtmlUnitWebWindowListener(int maxRedirects) {
this.maxRedirects = maxRedirects;
}
-
+
@Override
public void webWindowOpened(WebWindowEvent event) {
-
+
}
@Override
@@ -46,8 +46,8 @@ public class HtmlUnitWebWindowListener implements WebWindowListener {
@Override
public void webWindowClosed(WebWindowEvent event) {
-
+
}
-
+
}
diff --git a/src/plugin/lib-http/ivy.xml b/src/plugin/lib-http/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/lib-http/ivy.xml
+++ b/src/plugin/lib-http/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/lib-http/src/java/org/apache/nutch/protocol/http/api/package-info.java b/src/plugin/lib-http/src/java/org/apache/nutch/protocol/http/api/package-info.java
index 8cacc3eef..7e5745cb9 100644
--- a/src/plugin/lib-http/src/java/org/apache/nutch/protocol/http/api/package-info.java
+++ b/src/plugin/lib-http/src/java/org/apache/nutch/protocol/http/api/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* Common API used by HTTP plugins ({@link org.apache.nutch.protocol.http http},
* {@link org.apache.nutch.protocol.httpclient httpclient}, etc.)
*/
diff --git a/src/plugin/lib-nekohtml/ivy.xml b/src/plugin/lib-nekohtml/ivy.xml
index 1ca267c0e..9e928015e 100644
--- a/src/plugin/lib-nekohtml/ivy.xml
+++ b/src/plugin/lib-nekohtml/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<dependency org="net.sourceforge.nekohtml" name="nekohtml" rev="1.9.22" conf="*->master"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/lib-nekohtml/plugin.xml b/src/plugin/lib-nekohtml/plugin.xml
index 9337273fb..47536e03c 100644
--- a/src/plugin/lib-nekohtml/plugin.xml
+++ b/src/plugin/lib-nekohtml/plugin.xml
@@ -16,11 +16,11 @@
limitations under the License.
-->
<!--
- ! NekoHTML is a simple HTML scanner and tag balancer that enables
- ! application programmers to parse HTML documents and access the
+ ! NekoHTML is a simple HTML scanner and tag balancer that enables
+ ! application programmers to parse HTML documents and access the
! information using standard XML interfaces.
! (http://sourceforge.net/projects/nekohtml/)
- !
+ !
! License : https://nekohtml.svn.sourceforge.net/svnroot/nekohtml/trunk/LICENSE.txt
!-->
<plugin
diff --git a/src/plugin/lib-rabbitmq/ivy.xml b/src/plugin/lib-rabbitmq/ivy.xml
index fe5cedd23..9d3fd8c80 100644
--- a/src/plugin/lib-rabbitmq/ivy.xml
+++ b/src/plugin/lib-rabbitmq/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -42,5 +42,5 @@
</dependency>
<dependency org="com.google.code.gson" name="gson" rev="2.8.4"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/lib-regex-filter/ivy.xml b/src/plugin/lib-regex-filter/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/lib-regex-filter/ivy.xml
+++ b/src/plugin/lib-regex-filter/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/lib-regex-filter/src/java/org/apache/nutch/urlfilter/api/RegexRule.java b/src/plugin/lib-regex-filter/src/java/org/apache/nutch/urlfilter/api/RegexRule.java
index 2db2a5cd8..b49c20486 100644
--- a/src/plugin/lib-regex-filter/src/java/org/apache/nutch/urlfilter/api/RegexRule.java
+++ b/src/plugin/lib-regex-filter/src/java/org/apache/nutch/urlfilter/api/RegexRule.java
@@ -18,19 +18,19 @@ package org.apache.nutch.urlfilter.api;
/**
* A generic regular expression rule.
- *
+ *
*/
public abstract class RegexRule {
private final boolean sign;
-
+
private final String hostOrDomain;
-
+
private final String regex;
/**
* Constructs a new regular expression rule.
- *
+ *
* @param sign
* specifies if this rule must filter-in or filter-out. A
* <code>true</code> value means that any url matching this rule must
@@ -43,10 +43,10 @@ public abstract class RegexRule {
protected RegexRule(boolean sign, String regex) {
this(sign, regex, null);
}
-
+
/**
* Constructs a new regular expression rule.
- *
+ *
* @param sign
* specifies if this rule must filter-in or filter-out. A
* <code>true</code> value means that any url matching this rule must
@@ -66,7 +66,7 @@ public abstract class RegexRule {
/**
* Return if this rule is used for filtering-in or out.
- *
+ *
* @return <code>true</code> if any url matching this rule must be accepted,
* otherwise <code>false</code>.
*/
@@ -80,7 +80,7 @@ public abstract class RegexRule {
* @return host or domain this regex rule belongs to
*/
protected String hostOrDomain() { return hostOrDomain; }
-
+
/**
* Return if this rule's regex.
*
@@ -90,7 +90,7 @@ public abstract class RegexRule {
/**
* Checks if a url matches this rule.
- *
+ *
* @param url
* is the url to check.
* @return <code>true</code> if the specified url matches this rule, otherwise
diff --git a/src/plugin/lib-selenium/README.md b/src/plugin/lib-selenium/README.md
index 2d82fa752..a3f519950 100644
--- a/src/plugin/lib-selenium/README.md
+++ b/src/plugin/lib-selenium/README.md
@@ -18,7 +18,7 @@
# Updates
* The use of phantomjs has been deprecated. Check [Wikipedia](https://en.wikipedia.org/wiki/PhantomJS) for more info.
* The updated code for Safari webriver is under development as starting Safari 10 on OS X El Capitan and macOS Sierra, Safari comes bundled with a new driver implementation.
-* Opera is now based on ChromeDriver and has been adapted by Opera that enables programmatic automation of Chromium-based Opera products but hasn't been updated since April 5, 2017. We have suspended its support and removed from the code.([link](https://github.com/operasoftware/operachromiumdriver))
+* Opera is now based on ChromeDriver and has been adapted by Opera that enables programmatic automation of Chromium-based Opera products but hasn't been updated since April 5, 2017. We have suspended its support and removed from the code.([link](https://github.com/operasoftware/operachromiumdriver))
* Headless mode has been added for Chrome and Firefox. Set `selenium.enable.headless` to `true` in nutch-default.xml or nutch-site.xml to use it.
diff --git a/src/plugin/lib-selenium/build.xml b/src/plugin/lib-selenium/build.xml
index 7c6d98d6f..50e2e4a1f 100644
--- a/src/plugin/lib-selenium/build.xml
+++ b/src/plugin/lib-selenium/build.xml
@@ -20,7 +20,7 @@
<import file="../build-plugin.xml"/>
<!-- Add compilation dependencies to classpath -->
- <path id="plugin.deps">
+ <path id="plugin.deps">
<fileset dir="${nutch.root}/build">
<include name="**/lib-http/*.jar" />
</fileset>
diff --git a/src/plugin/lib-selenium/ivy.xml b/src/plugin/lib-selenium/ivy.xml
index 85f2e0d6d..1e2213ea7 100644
--- a/src/plugin/lib-selenium/ivy.xml
+++ b/src/plugin/lib-selenium/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/lib-selenium/src/java/org/apache/nutch/protocol/selenium/HttpWebClient.java b/src/plugin/lib-selenium/src/java/org/apache/nutch/protocol/selenium/HttpWebClient.java
index 0440e84b0..51334c1d5 100644
--- a/src/plugin/lib-selenium/src/java/org/apache/nutch/protocol/selenium/HttpWebClient.java
+++ b/src/plugin/lib-selenium/src/java/org/apache/nutch/protocol/selenium/HttpWebClient.java
@@ -217,7 +217,7 @@ public class HttpWebClient {
* webdriver</a> There are a number of configuration properties within
* <code>nutch-site.xml</code> which determine whether to take screenshots of
* the rendered pages and persist them as timestamped .png's into HDFS.
- *
+ *
* @param url
* the URL to fetch and render
* @param conf
diff --git a/src/plugin/lib-xml/ivy.xml b/src/plugin/lib-xml/ivy.xml
index be69c0896..c1918642e 100644
--- a/src/plugin/lib-xml/ivy.xml
+++ b/src/plugin/lib-xml/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -41,5 +41,5 @@
<dependency org="jaxen" name="jaxen" rev="2.0.6" conf="*->master"/>
<dependency org="xerces" name="xercesImpl" rev="2.12.2" conf="*->master"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/microformats-reltag/ivy.xml b/src/plugin/microformats-reltag/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/microformats-reltag/ivy.xml
+++ b/src/plugin/microformats-reltag/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/RelTagIndexingFilter.java b/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/RelTagIndexingFilter.java
index fe9c0f841..dbae278f5 100644
--- a/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/RelTagIndexingFilter.java
+++ b/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/RelTagIndexingFilter.java
@@ -29,7 +29,7 @@ import org.apache.hadoop.conf.Configuration;
/**
* An {@link org.apache.nutch.indexer.IndexingFilter} that add <code>tag</code>
* field(s) to the document.
- *
+ *
* @see <a href="http://www.microformats.org/wiki/rel-tag">
* http://www.microformats.org/wiki/rel-tag</a>
*/
diff --git a/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/package-info.java b/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/package-info.java
index 4a828bdc6..5c14b8d38 100644
--- a/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/package-info.java
+++ b/src/plugin/microformats-reltag/src/java/org/apache/nutch/microformats/reltag/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* A microformats <a href="http://www.microformats.org/wiki/Rel-Tag">Rel-Tag</a>
* Parser/Indexer/Querier plugin.
*/
diff --git a/src/plugin/mimetype-filter/ivy.xml b/src/plugin/mimetype-filter/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/mimetype-filter/ivy.xml
+++ b/src/plugin/mimetype-filter/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/nutch-extensionpoints/ivy.xml b/src/plugin/nutch-extensionpoints/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/nutch-extensionpoints/ivy.xml
+++ b/src/plugin/nutch-extensionpoints/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/nutch-extensionpoints/plugin.xml b/src/plugin/nutch-extensionpoints/plugin.xml
index 2ae815f59..c7ce6abdf 100644
--- a/src/plugin/nutch-extensionpoints/plugin.xml
+++ b/src/plugin/nutch-extensionpoints/plugin.xml
@@ -21,7 +21,7 @@
version="2.0.0"
provider-name="nutch.org">
- <!-- this file hosts all extension points nutch core code offers.
+ <!-- this file hosts all extension points nutch core code offers.
Please not that plugins can define extension points as well to be extendable.-->
<extension-point
@@ -39,7 +39,7 @@
<extension-point
id="org.apache.nutch.parse.Parser"
name="Nutch Content Parser"/>
-
+
<extension-point
id="org.apache.nutch.parse.HtmlParseFilter"
name="HTML Parse Filter"/>
diff --git a/src/plugin/parse-ext/ivy.xml b/src/plugin/parse-ext/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/parse-ext/ivy.xml
+++ b/src/plugin/parse-ext/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/parse-ext/src/test/org/apache/nutch/parse/ext/TestExtParser.java b/src/plugin/parse-ext/src/test/org/apache/nutch/parse/ext/TestExtParser.java
index 89538a14d..980221ce9 100644
--- a/src/plugin/parse-ext/src/test/org/apache/nutch/parse/ext/TestExtParser.java
+++ b/src/plugin/parse-ext/src/test/org/apache/nutch/parse/ext/TestExtParser.java
@@ -43,9 +43,9 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
* fetch and parse it using external command 'cat' and 'md5sum' alternately for
* 10 times. Doing so also does a light stress test for class CommandRunner.java
* (as used in ExtParser.java).
- *
+ *
* Warning: currently only do test on linux platform.
- *
+ *
*/
public class TestExtParser {
private File tempFile = null;
diff --git a/src/plugin/parse-html/ivy.xml b/src/plugin/parse-html/ivy.xml
index ec4bfb8a3..21bfabf0c 100644
--- a/src/plugin/parse-html/ivy.xml
+++ b/src/plugin/parse-html/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/DOMBuilder.java b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/DOMBuilder.java
index b80356130..5c2887357 100644
--- a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/DOMBuilder.java
+++ b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/DOMBuilder.java
@@ -61,7 +61,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* DOMBuilder instance constructor... it will add the DOM nodes to the
* document fragment.
- *
+ *
* @param doc
* Root document
* @param node
@@ -75,7 +75,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* DOMBuilder instance constructor... it will add the DOM nodes to the
* document fragment.
- *
+ *
* @param doc
* Root document
* @param docFrag
@@ -89,7 +89,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* DOMBuilder instance constructor... it will add the DOM nodes to the
* document.
- *
+ *
* @param doc
* Root document
*/
@@ -100,7 +100,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Get the root node of the DOM being created. This is either a Document or a
* DocumentFragment.
- *
+ *
* @return The root document or document fragment if not null
*/
public Node getRootNode() {
@@ -109,7 +109,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Get the node currently being processed.
- *
+ *
* @return the current node being processed
*/
public Node getCurrentNode() {
@@ -118,7 +118,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Return null since there is no Writer for this class.
- *
+ *
* @return null
*/
public java.io.Writer getWriter() {
@@ -127,10 +127,10 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Append a node to the current container.
- *
+ *
* @param newNode
* New node to append
- * @throws org.xml.sax.SAXException if text is found before
+ * @throws org.xml.sax.SAXException if text is found before
* the document element
*/
protected void append(Node newNode) throws org.xml.sax.SAXException {
@@ -170,14 +170,14 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive an object for locating the origin of SAX document events.
- *
+ *
* <p>
* SAX parsers are strongly encouraged (though not absolutely required) to
* supply a locator: if it does so, it must supply the locator to the
* application by invoking this method before invoking any of the other
* methods in the ContentHandler interface.
* </p>
- *
+ *
* <p>
* The locator allows the application to determine the end position of any
* document-related event, even if the parser is not reporting an error.
@@ -186,13 +186,13 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* business rules). The information returned by the locator is probably not
* sufficient for use with a search engine.
* </p>
- *
+ *
* <p>
* Note that the locator will return correct information only during the
* invocation of the events in this interface. The application should not
* attempt to use it at any other time.
* </p>
- *
+ *
* @param locator
* An object that can return the location of any SAX document event.
* @see org.xml.sax.Locator
@@ -204,7 +204,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of the beginning of a document.
- *
+ *
* <p>
* The SAX parser will invoke this method only once, before any other methods
* in this interface or in DTDHandler (except for setDocumentLocator).
@@ -217,7 +217,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of the end of a document.
- *
+ *
* <p>
* The SAX parser will invoke this method only once, and it will be the last
* method invoked during the parse. The parser shall not invoke this method
@@ -232,7 +232,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of the beginning of an element.
- *
+ *
* <p>
* The Parser will invoke this method at the beginning of every element in the
* XML document; there will be a corresponding endElement() event for every
@@ -240,15 +240,15 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* content will be reported, in order, before the corresponding endElement()
* event.
* </p>
- *
+ *
* <p>
* If the element name has a namespace prefix, the prefix will still be
* attached. Note that the attribute list provided will contain only
* attributes with explicit values (specified or defaulted): #IMPLIED
* attributes will be omitted.
* </p>
- *
- *
+ *
+ *
* @param ns
* The namespace of the node
* @param localName
@@ -321,23 +321,23 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
}
/**
- *
- *
- *
+ *
+ *
+ *
* Receive notification of the end of an element.
- *
+ *
* <p>
* The SAX parser will invoke this method at the end of every element in the
* XML document; there will be a corresponding startElement() event for every
* endElement() event (even when the element is empty).
* </p>
- *
+ *
* <p>
* If the element name has a namespace prefix, the prefix will still be
* attached to the name.
* </p>
- *
- *
+ *
+ *
* @param ns
* the namespace of the element
* @param localName
@@ -353,7 +353,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Set an ID string to node association in the ID table.
- *
+ *
* @param id
* The ID string.
* @param elem
@@ -366,7 +366,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of character data.
- *
+ *
* <p>
* The Parser will call this method to report each chunk of character data.
* SAX parsers may return all contiguous character data in a single chunk, or
@@ -374,18 +374,18 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* any single event must come from the same external entity, so that the
* Locator provides useful information.
* </p>
- *
+ *
* <p>
* The application must not attempt to read from the array outside of the
* specified range.
* </p>
- *
+ *
* <p>
* Note that some parsers will report whitespace using the
* ignorableWhitespace() method rather than this one (validating parsers must
* do so).
* </p>
- *
+ *
* @param ch
* The characters from the XML document.
* @param start
@@ -422,14 +422,14 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* If available, when the disable-output-escaping attribute is used, output
* raw text without escaping. A PI will be inserted in front of the node with
* the name "lotusxsl-next-is-raw" and a value of "formatter-to-dom".
- *
+ *
* @param ch
* Array containing the characters
* @param start
* Index to start of characters in the array
* @param length
* Number of characters in the array
- * @throws org.xml.sax.SAXException if text is found before
+ * @throws org.xml.sax.SAXException if text is found before
* the document element
*/
public void charactersRaw(char ch[], int start, int length)
@@ -447,11 +447,11 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the beginning of an entity.
- *
+ *
* The start and end of the document entity are not reported. The start and
* end of the external DTD subset are reported using the pseudo-name "[dtd]".
* All other events must be properly nested within start/end entity events.
- *
+ *
* @param name
* The name of the entity. If it is a parameter entity, the name will
* begin with '%'.
@@ -467,11 +467,11 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the end of an entity.
- *
+ *
* @param name
* The name of the entity that is ending.
* @see #startEntity
- * @throws org.xml.sax.SAXException if text is found before
+ * @throws org.xml.sax.SAXException if text is found before
* the document element
*/
public void endEntity(String name) throws org.xml.sax.SAXException {
@@ -479,10 +479,10 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notivication of a entityReference.
- *
+ *
* @param name
* name of the entity reference
- * @throws org.xml.sax.SAXException if text is found before
+ * @throws org.xml.sax.SAXException if text is found before
* the document element
*/
public void entityReference(String name) throws org.xml.sax.SAXException {
@@ -491,26 +491,26 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of ignorable whitespace in element content.
- *
+ *
* <p>
* Validating Parsers must use this method to report each chunk of ignorable
* whitespace (see the W3C XML 1.0 recommendation, section 2.10):
* non-validating parsers may also use this method if they are capable of
* parsing and using content models.
* </p>
- *
+ *
* <p>
* SAX parsers may return all contiguous whitespace in a single chunk, or they
* may split it into several chunks; however, all of the characters in any
* single event must come from the same external entity, so that the Locator
* provides useful information.
* </p>
- *
+ *
* <p>
* The application must not attempt to read from the array outside of the
* specified range.
* </p>
- *
+ *
* @param ch
* The characters from the XML document.
* @param start
@@ -531,7 +531,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Tell if the current node is outside the document element.
- *
+ *
* @return true if the current node is outside the document element.
*/
private boolean isOutsideDocElem() {
@@ -542,18 +542,18 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of a processing instruction.
- *
+ *
* <p>
* The Parser will invoke this method once for each processing instruction
* found: note that processing instructions may occur before or after the main
* document element.
* </p>
- *
+ *
* <p>
* A SAX parser should never report an XML declaration (XML 1.0, section 2.8)
* or a text declaration (XML 1.0, section 4.3.1) using this method.
* </p>
- *
+ *
* @param target
* The processing instruction target.
* @param data
@@ -566,10 +566,10 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report an XML comment anywhere in the document.
- *
+ *
* This callback will be used for comments inside or outside the document
* element, including comments in the external DTD subset (if read).
- *
+ *
* @param ch
* An array holding the characters in the comment.
* @param start
@@ -590,7 +590,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the start of a CDATA section.
- *
+ *
* @see #endCDATA
*/
public void startCDATA() throws org.xml.sax.SAXException {
@@ -600,7 +600,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the end of a CDATA section.
- *
+ *
* @see #startCDATA
*/
public void endCDATA() throws org.xml.sax.SAXException {
@@ -609,7 +609,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of cdata.
- *
+ *
* <p>
* The Parser will call this method to report each chunk of character data.
* SAX parsers may return all contiguous character data in a single chunk, or
@@ -617,18 +617,18 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* any single event must come from the same external entity, so that the
* Locator provides useful information.
* </p>
- *
+ *
* <p>
* The application must not attempt to read from the array outside of the
* specified range.
* </p>
- *
+ *
* <p>
* Note that some parsers will report whitespace using the
* ignorableWhitespace() method rather than this one (validating parsers must
* do so).
* </p>
- *
+ *
* @param ch
* The characters from the XML document.
* @param start
@@ -637,7 +637,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* The number of characters to read from the array.
* @see #ignorableWhitespace
* @see org.xml.sax.Locator
- * @throws org.xml.sax.SAXException if text is found before
+ * @throws org.xml.sax.SAXException if text is found before
* the document element
*/
public void cdata(char ch[], int start, int length)
@@ -658,10 +658,10 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the start of DTD declarations, if any.
- *
+ *
* Any declarations are assumed to be in the internal subset unless otherwise
* indicated.
- *
+ *
* @param name
* The document type name.
* @param publicId
@@ -681,7 +681,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Report the end of DTD declarations.
- *
+ *
* @see #startDTD
*/
public void endDTD() throws org.xml.sax.SAXException {
@@ -691,21 +691,21 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Begin the scope of a prefix-URI Namespace mapping.
- *
+ *
* <p>
* The information from this event is not necessary for normal Namespace
* processing: the SAX XML reader will automatically replace prefixes for
* element and attribute names when the http://xml.org/sax/features/namespaces
* feature is true (the default).
* </p>
- *
+ *
* <p>
* There are cases, however, when applications need to use prefixes in
* character data or in attribute values, where they cannot safely be expanded
* automatically; the start/endPrefixMapping event supplies the information to
* the application to expand prefixes in those contexts itself, if necessary.
* </p>
- *
+ *
* <p>
* Note that start/endPrefixMapping events are not guaranteed to be properly
* nested relative to each-other: all startPrefixMapping events will occur
@@ -713,7 +713,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* events will occur after the corresponding endElement event, but their order
* is not guaranteed.
* </p>
- *
+ *
* @param prefix
* The Namespace prefix being declared.
* @param uri
@@ -730,7 +730,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* Node.ELEMENT_NODE)) { String qname; if(((null != prefix) &&
* (prefix.length() == 0)) || (null == prefix)) qname = "xmlns"; else qname
* = "xmlns:"+prefix;
- *
+ *
* Element elem = (Element)m_currentNode; String val =
* elem.getAttribute(qname); // Obsolete, should be DOM2...? if(val == null)
* { elem.setAttributeNS("http://www.w3.org/XML/1998/namespace", qname,
@@ -740,13 +740,13 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* End the scope of a prefix-URI mapping.
- *
+ *
* <p>
* See startPrefixMapping for details. This event will always occur after the
* corresponding endElement event, but the order of endPrefixMapping events is
* not otherwise guaranteed.
* </p>
- *
+ *
* @param prefix
* The prefix that was being mapping.
* @see #startPrefixMapping
@@ -757,7 +757,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
/**
* Receive notification of a skipped entity.
- *
+ *
* <p>
* The Parser will invoke this method once for each entity skipped.
* Non-validating processors may skip entities if they have not seen the
@@ -766,7 +766,7 @@ public class DOMBuilder implements ContentHandler, LexicalHandler {
* values of the http://xml.org/sax/features/external-general-entities and the
* http://xml.org/sax/features/external-parameter-entities properties.
* </p>
- *
+ *
* @param name
* The name of the skipped entity. If it is a parameter entity, the
* name will begin with '%'.
diff --git a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/HtmlParser.java b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/HtmlParser.java
index 73d42d0dc..80512aa6a 100644
--- a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/HtmlParser.java
+++ b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/HtmlParser.java
@@ -88,7 +88,7 @@ public class HtmlParser implements Parser {
* http://www.w3.org/International/questions/qa-html-encoding-declarations,
* http://www.w3.org/TR/2011/WD-html5-diff-20110405/#character-encoding, and
* http://www.w3.org/TR/REC-xml/#sec-guessing
- *
+ *
* @param content
* <code>byte[]</code> representation of an html file
*/
diff --git a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/XMLCharacterRecognizer.java b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/XMLCharacterRecognizer.java
index 7361ac7dc..e0fb2b8b0 100644
--- a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/XMLCharacterRecognizer.java
+++ b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/XMLCharacterRecognizer.java
@@ -36,7 +36,7 @@ public class XMLCharacterRecognizer {
* definition of whitespace. Refer to <A
* href="http://www.w3.org/TR/1998/REC-xml-19980210#NT-S"> the definition of
* <CODE>S</CODE></A> for details.
- *
+ *
* @param ch
* Character to check as XML whitespace.
* @return =true if <var>ch</var> is XML whitespace; otherwise =false.
@@ -47,7 +47,7 @@ public class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param ch
* Character array to check as XML whitespace.
* @param start
@@ -71,7 +71,7 @@ public class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param buf
* StringBuffer to check as XML whitespace.
* @return True if characters in buffer are XML whitespace, false otherwise
@@ -90,7 +90,7 @@ public class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param s
* String to check as XML whitespace.
* @return True if characters in buffer are XML whitespace, false otherwise
diff --git a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/package-info.java b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/package-info.java
index c1b3c4643..84d77d80d 100644
--- a/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/package-info.java
+++ b/src/plugin/parse-html/src/java/org/apache/nutch/parse/html/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* <p>An HTML document parsing plugin.</p>
* <p>This package relies on <a href="https://github.com/codelibs/nekohtml">NekoHTML</a>.</p>
*/
diff --git a/src/plugin/parse-js/ivy.xml b/src/plugin/parse-js/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/parse-js/ivy.xml
+++ b/src/plugin/parse-js/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/parse-metatags/README.txt b/src/plugin/parse-metatags/README.txt
index 0d5b00997..5aa6f09e2 100644
--- a/src/plugin/parse-metatags/README.txt
+++ b/src/plugin/parse-metatags/README.txt
@@ -9,7 +9,7 @@ In order to extract the values of the metatags description and keywords, you mus
</property>
Prefixes the names with 'metatag.' in the parse-metadata. For instance to index description and keywords, you need to activate the plugin index-metadata and set the value of the parameter 'index.parse.md' to 'metatag.description;metatag.keywords'.
-
+
This code has been developed by DigitalPebble Ltd and offered to the community by ANT.com
diff --git a/src/plugin/parse-metatags/ivy.xml b/src/plugin/parse-metatags/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/parse-metatags/ivy.xml
+++ b/src/plugin/parse-metatags/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/parse-tika/build.xml b/src/plugin/parse-tika/build.xml
index af3e6107b..e4f45184e 100644
--- a/src/plugin/parse-tika/build.xml
+++ b/src/plugin/parse-tika/build.xml
@@ -18,7 +18,7 @@
<project name="parse-tika" default="jar-core">
<import file="../build-plugin.xml"/>
-
+
<!-- Deploy Unit test dependencies -->
<target name="deps-test">
<ant target="deploy" inheritall="false" dir="../nutch-extensionpoints"/>
@@ -39,6 +39,6 @@
<include name="*.xlsx"/>
</fileset>
</copy>
-
+
</project>
diff --git a/src/plugin/parse-tika/ivy.xml b/src/plugin/parse-tika/ivy.xml
index a81c37294..4de97794b 100644
--- a/src/plugin/parse-tika/ivy.xml
+++ b/src/plugin/parse-tika/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -47,5 +47,5 @@
<exclude org="org.slf4j" name="slf4j-api"/>
</dependency>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/parse-tika/sample/nutch.html b/src/plugin/parse-tika/sample/nutch.html
index 809853512..ec7a19691 100644
--- a/src/plugin/parse-tika/sample/nutch.html
+++ b/src/plugin/parse-tika/sample/nutch.html
@@ -65,7 +65,7 @@
+-->
<div class="searchbox">
<form action="http://search.lucidimagination.com/p:nutch" method="get" class="roundtopsmall">
-<input onFocus="getBlank (this, 'Search the site with Solr');" size="25" name="q" id="query" type="text" value="Search the site with Solr">&nbsp;
+<input onFocus="getBlank (this, 'Search the site with Solr');" size="25" name="q" id="query" type="text" value="Search the site with Solr">&nbsp;
<input name="Search" value="Search" type="submit">
</form>
<div style="position: relative; top: -5px; left: -10px">Powered by <a href="http://www.lucidimagination.com" style="color: #033268">Lucid Imagination</a>
@@ -272,16 +272,16 @@ document.write("Last Published: " + document.lastModified);
</ul>
</li>
</ul>
-</div>
+</div>
+
-
<a name="N1000D"></a><a name="News"></a>
<h2 class="h3">News</h2>
<div class="section">
<a name="N10013"></a><a name="14+August+2009+-+Lucene+at+US+ApacheCon"></a>
<h3 class="h4">14 August 2009 - Lucene at US ApacheCon</h3>
<p>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/" title="ApacheCon US 2009">
<img alt="ApacheCon Logo" class="float-right" src="http://www.apache.org/events/current-event-125x125.png">
</a>
@@ -296,91 +296,91 @@ document.write("Last Published: " + document.lastModified);
</p>
<p> Training:</p>
<ul>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/437">Lucene Boot Camp</a>
- A two day training session, Nov. 2nd &amp; 3rd
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/375">Solr Day</a>
- A one day training session, Nov. 2nd
</li>
-
+
</ul>
<p>Thursday, Nov. 5th</p>
<ul>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/428">Introduction to the Lucene Ecosystem
</a>
- Grant Ingersoll @ 9:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/461">Lucene Basics and New Features</a>
- Michael Busch @ 10:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/331">Apache Solr: Out of the Box</a>
- Chris Hostetter @ 14:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/427">Introduction to Nutch</a>
- Andrzej Bialecki @ 15:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/430">Lucene and Solr Performance Tuning</a>
- Mark Miller @ 16:30
</li>
-
+
</ul>
<p>Friday, Nov. 6th</p>
<ul>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/332">Implementing an Information Retrieval
Framework for an Organizational Repository</a>
- Sithu D Sudarsan @ 9:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/333">Apache Mahout - Going from raw data to
Information</a>
- Isabel Drost @ 10:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/334">MIME Magic with Apache Tika</a>
- Jukka Zitting @ 11:30
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/335">Building Intelligent Search Applications
with the Lucene Ecosystem</a>
- Ted Dunning @ 14:00
</li>
-
+
<li>
-
+
<a href="http://www.us.apachecon.com/c/acus2009/sessions/462">Realtime Search</a>
- Jason Rutherglen @ 15:00
</li>
-
+
</ul>
<a name="N10091"></a><a name="23+March+2009+-+Apache+Nutch+1.0+Released"></a>
<h3 class="h4">23 March 2009 - Apache Nutch 1.0 Released</h3>
@@ -408,35 +408,35 @@ document.write("Last Published: " + document.lastModified);
<a href="http://eu.apachecon.com/c/aceu2009/sessions/197">Lucene Boot Camp</a>
- A two day training session, March 23 &amp; 24th</li>
-
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/201">Solr Boot Camp</a> - A one day training session, March 24th</li>
-
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/136">Introducing Apache Mahout</a> - Grant Ingersoll. March 25th @ 10:30</li>
-
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/137">Lucene/Solr Case Studies</a> - Erik Hatcher. March 25th @ 11:30</li>
-
+
<li>
-<a href="http://eu.apachecon.com/c/aceu2009/sessions/138">Advanced Indexing Techniques with Apache Lucene</a> - Michael Busch. March 25th @ 14:00</li>
-
+<a href="http://eu.apachecon.com/c/aceu2009/sessions/138">Advanced Indexing Techniques with Apache Lucene</a> - Michael Busch. March 25th @ 14:00</li>
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/251">Apache Solr - A Case Study</a> - Uri Boness. March 26th @ 17:30</li>
-
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/250">Best of breed - httpd, forrest, solr and droids</a> - Thorsten Scherler. March 27th @ 17:30</li>
-
+
<li>
<a href="http://eu.apachecon.com/c/aceu2009/sessions/165">Apache Droids - an intelligent standalone robot framework</a> - Thorsten Scherler. March 26th @ 15:00</li>
-
+
</ul>
<a name="N100EF"></a><a name="2+April+2007%3A+Nutch+0.9+Released"></a>
<h3 class="h4">2 April 2007: Nutch 0.9 Released</h3>
<p>The 0.9 release of Nutch is now available. This is the second release of Nutch
based entirely on the underlying Hadoop platform. This release includes several critical
- bug fixes, as well as key speedups described in more detail at
+ bug fixes, as well as key speedups described in more detail at
<a href="http://blog.foofactory.fi/2007/03/twice-speed-half-size.html">Sami Siren's blog</a>.
See <a href="http://www.apache.org/dist/lucene/nutch/CHANGES-0.9.txt">
list of changes</a> made in this version. The release is available
@@ -467,9 +467,9 @@ document.write("Last Published: " + document.lastModified);
<a href="http://lucene.apache.org/nutch/release/">here</a>.</p>
<a name="N1014D"></a><a name="17+August+2005%3A+Nutch+0.7+Released"></a>
<h3 class="h4">17 August 2005: Nutch 0.7 Released</h3>
-<p>This is the first Nutch release as an Apache Lucene sub-project. See
+<p>This is the first Nutch release as an Apache Lucene sub-project. See
<a href="http://svn.apache.org/viewcvs.cgi/lucene/nutch/trunk/CHANGES.txt?rev=233150">
- CHANGES.txt</a> for details. The release is available
+ CHANGES.txt</a> for details. The release is available
<a href="http://lucene.apache.org/nutch/release/">here</a>.</p>
<a name="N1015F"></a><a name="June+2005%3A+Nutch+graduates+from+Incubator"></a>
<h3 class="h4">June 2005: Nutch graduates from Incubator</h3>
@@ -506,7 +506,7 @@ document.write("Last Published: " + document.lastModified);
Lab</a>.</p>
</div>
-
+
</div>
<!--+
|end content
diff --git a/src/plugin/parse-tika/sample/ootest.txt b/src/plugin/parse-tika/sample/ootest.txt
index 685f89a5f..0739c6dc8 100644
--- a/src/plugin/parse-tika/sample/ootest.txt
+++ b/src/plugin/parse-tika/sample/ootest.txt
@@ -27,4 +27,4 @@ TOTAL
TOTAL
TOTAL
-Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer a leo in lacus malesuada ornare. Mauris sagittis. Nam vestibulum. Nunc gravida vestibulum augue. Praesent sed lectus quis lectus adipiscing bibendum. Sed nulla. Duis posuere justo eget urna. Proin lorem orci, vestibulum ut, consequat molestie, eleifend a, nibh. Mauris sed lacus. Etiam blandit tincidunt neque. Cras ac sapien. Duis erat.
+Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Integer a leo in lacus malesuada ornare. Mauris sagittis. Nam vestibulum. Nunc gravida vestibulum augue. Praesent sed lectus quis lectus adipiscing bibendum. Sed nulla. Duis posuere justo eget urna. Proin lorem orci, vestibulum ut, consequat molestie, eleifend a, nibh. Mauris sed lacus. Etiam blandit tincidunt neque. Cras ac sapien. Duis erat.
diff --git a/src/plugin/parse-tika/sample/rsstest.rss b/src/plugin/parse-tika/sample/rsstest.rss
index 6c4ae488d..8fb241d62 100644
--- a/src/plugin/parse-tika/sample/rsstest.rss
+++ b/src/plugin/parse-tika/sample/rsstest.rss
@@ -18,10 +18,10 @@
<rss version="0.91">
<channel>
<title>TestChannel</title>
- <link>http://test.channel.com/</link>
- <description>Sample RSS File for Junit test</description>
+ <link>http://test.channel.com/</link>
+ <description>Sample RSS File for Junit test</description>
<language>en-us</language>
-
+
<item>
<title>Home Page of Chris Mattmann</title>
<link>http://www-scf.usc.edu/~mattmann/</link>
@@ -29,9 +29,9 @@
</item>
<item>
- <title>Awesome Open Source Search Engine</title>
- <link>http://www.nutch.org/</link>
- <description>Yup, that's what it is</description>
+ <title>Awesome Open Source Search Engine</title>
+ <link>http://www.nutch.org/</link>
+ <description>Yup, that's what it is</description>
</item>
</channel>
</rss>
diff --git a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/BoilerpipeExtractorRepository.java b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/BoilerpipeExtractorRepository.java
index 483009a87..5d65318b6 100644
--- a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/BoilerpipeExtractorRepository.java
+++ b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/BoilerpipeExtractorRepository.java
@@ -28,7 +28,7 @@ class BoilerpipeExtractorRepository {
private static final Logger LOG = LoggerFactory
.getLogger(MethodHandles.lookup().lookupClass());
public static final HashMap<String, BoilerpipeExtractor> extractorRepository = new HashMap<>();
-
+
/**
* Returns an instance of the specified extractor
*/
diff --git a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/HTMLMetaProcessor.java b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/HTMLMetaProcessor.java
index 1ca61e0a1..b2ba4992e 100644
--- a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/HTMLMetaProcessor.java
+++ b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/HTMLMetaProcessor.java
@@ -42,7 +42,7 @@ public class HTMLMetaProcessor {
/**
* Sets the indicators in <code>robotsMeta</code> to appropriate values, based
* on any META tags found under the given <code>node</code>.
- * @param metaTags a {@link HTMLMetaTags} to populate with tags discovered in the
+ * @param metaTags a {@link HTMLMetaTags} to populate with tags discovered in the
* given Node
* @param node a DOM {@link Node} to process and extract metadata from
* @param currURL the canonical URL associated with the metatags and Node
diff --git a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/XMLCharacterRecognizer.java b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/XMLCharacterRecognizer.java
index 06cb10f53..e233ef792 100644
--- a/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/XMLCharacterRecognizer.java
+++ b/src/plugin/parse-tika/src/java/org/apache/nutch/parse/tika/XMLCharacterRecognizer.java
@@ -36,7 +36,7 @@ class XMLCharacterRecognizer {
* definition of whitespace. Refer to <A
* href="http://www.w3.org/TR/1998/REC-xml-19980210#NT-S"> the definition of
* <CODE>S</CODE></A> for details.
- *
+ *
* @param ch
* Character to check as XML whitespace.
* @return =true if <var>ch</var> is XML whitespace; otherwise =false.
@@ -47,7 +47,7 @@ class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param ch
* Character array to check as XML whitespace.
* @param start
@@ -71,7 +71,7 @@ class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param buf
* StringBuffer to check as XML whitespace.
* @return True if characters in buffer are XML whitespace, false otherwise
@@ -90,7 +90,7 @@ class XMLCharacterRecognizer {
/**
* Tell if the string is whitespace.
- *
+ *
* @param s
* String to check as XML whitespace.
* @return True if characters in buffer are XML whitespace, false otherwise
diff --git a/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestEncodingDetection.java b/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestEncodingDetection.java
index 347d76a13..2f50f4793 100644
--- a/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestEncodingDetection.java
+++ b/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestEncodingDetection.java
@@ -52,10 +52,10 @@ public class TestEncodingDetection {
+ "<meta charset=\"utf-8\">"
+ "<title>UTF-8 Test</title></head>"
+ "<body>äöü ñ 中文</body></html>";
-
+
byte[] bytes = html.getBytes(StandardCharsets.UTF_8);
Parse parse = doParse(bytes);
-
+
assertEquals("UTF-8 Test", parse.getData().getTitle());
assertTrue(parse.getText().contains("äöü"));
assertTrue(parse.getText().contains("中文"));
@@ -67,10 +67,10 @@ public class TestEncodingDetection {
+ "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\">"
+ "<title>UTF-8 HTTP-Equiv</title></head>"
+ "<body>Special chars: äöü</body></html>";
-
+
byte[] bytes = html.getBytes(StandardCharsets.UTF_8);
Parse parse = doParse(bytes);
-
+
assertEquals("UTF-8 HTTP-Equiv", parse.getData().getTitle());
assertTrue(parse.getText().contains("äöü"));
}
@@ -80,16 +80,16 @@ public class TestEncodingDetection {
String html = "<!DOCTYPE html><html><head>"
+ "<title>BOM Test</title></head>"
+ "<body>Content with BOM</body></html>";
-
+
// UTF-8 BOM
byte[] bom = new byte[]{(byte)0xEF, (byte)0xBB, (byte)0xBF};
byte[] htmlBytes = html.getBytes(StandardCharsets.UTF_8);
byte[] withBom = new byte[bom.length + htmlBytes.length];
System.arraycopy(bom, 0, withBom, 0, bom.length);
System.arraycopy(htmlBytes, 0, withBom, bom.length, htmlBytes.length);
-
+
Parse parse = doParse(withBom);
-
+
assertEquals("BOM Test", parse.getData().getTitle());
assertTrue(parse.getText().contains("Content with BOM"));
}
@@ -100,12 +100,12 @@ public class TestEncodingDetection {
+ "<meta charset=\"iso-8859-1\">"
+ "<title>ISO-8859-1 Test</title></head>"
+ "<body>German: \u00e4\u00f6\u00fc</body></html>";
-
+
try {
Charset charset = Charset.forName("ISO-8859-1");
byte[] bytes = html.getBytes(charset);
Parse parse = doParse(bytes);
-
+
assertEquals("ISO-8859-1 Test", parse.getData().getTitle());
} catch (Exception e) {
// ISO-8859-1 might not be available on all systems
@@ -118,18 +118,18 @@ public class TestEncodingDetection {
String html = "<!DOCTYPE html><html><head>"
+ "<title>UTF-16BE Test</title></head>"
+ "<body>Content</body></html>";
-
+
// UTF-16BE doesn't add BOM automatically
byte[] bytes = html.getBytes(StandardCharsets.UTF_16BE);
-
+
// Add BOM manually for UTF-16BE
byte[] bom = new byte[]{(byte)0xFE, (byte)0xFF};
byte[] withBom = new byte[bom.length + bytes.length];
System.arraycopy(bom, 0, withBom, 0, bom.length);
System.arraycopy(bytes, 0, withBom, bom.length, bytes.length);
-
+
Parse parse = doParse(withBom);
-
+
assertNotNull(parse.getData().getTitle());
}
@@ -138,18 +138,18 @@ public class TestEncodingDetection {
String html = "<!DOCTYPE html><html><head>"
+ "<title>UTF-16LE Test</title></head>"
+ "<body>Content</body></html>";
-
+
// UTF-16LE doesn't add BOM automatically
byte[] bytes = html.getBytes(StandardCharsets.UTF_16LE);
-
+
// Add BOM manually for UTF-16LE
byte[] bom = new byte[]{(byte)0xFF, (byte)0xFE};
byte[] withBom = new byte[bom.length + bytes.length];
System.arraycopy(bom, 0, withBom, 0, bom.length);
System.arraycopy(bytes, 0, withBom, bom.length, bytes.length);
-
+
Parse parse = doParse(withBom);
-
+
assertNotNull(parse.getData().getTitle());
}
@@ -159,10 +159,10 @@ public class TestEncodingDetection {
String html = "<!DOCTYPE html><html><head>"
+ "<title>No Encoding</title></head>"
+ "<body>Plain ASCII content</body></html>";
-
+
byte[] bytes = html.getBytes(StandardCharsets.US_ASCII);
Parse parse = doParse(bytes);
-
+
assertEquals("No Encoding", parse.getData().getTitle());
assertTrue(parse.getText().contains("Plain ASCII content"));
}
@@ -173,14 +173,14 @@ public class TestEncodingDetection {
+ "<!DOCTYPE html><html xmlns=\"http://www.w3.org/1999/xhtml\">"
+ "<head><title>XHTML Test</title></head>"
+ "<body>Special: äöü</body></html>";
-
+
byte[] bytes = html.getBytes(StandardCharsets.UTF_8);
-
+
String url = "http://example.com/";
- Content content = new Content(url, url, bytes,
+ Content content = new Content(url, url, bytes,
"application/xhtml+xml", new Metadata(), conf);
Parse parse = parser.getParse(content).get(url);
-
+
assertNotNull(parse);
// Title extraction may vary for XHTML
}
diff --git a/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestFeedParser.java b/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestFeedParser.java
index 6350984ed..8c8538adc 100644
--- a/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestFeedParser.java
+++ b/src/plugin/parse-tika/src/test/org/apache/nutch/parse/tika/TestFeedParser.java
@@ -45,7 +45,7 @@ public class TestFeedParser extends TikaParserTest {
* <p>
* The test method: tests out the following 2 asserts:
* </p>
- *
+ *
* <ul>
* <li>There are 3 outlinks read from the sample rss file</li>
* <li>The 3 outlinks read are in fact the correct outlinks from the sample
diff --git a/src/plugin/parse-zip/ivy.xml b/src/plugin/parse-zip/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/parse-zip/ivy.xml
+++ b/src/plugin/parse-zip/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/parse-zip/plugin.xml b/src/plugin/parse-zip/plugin.xml
index 35ec0eb7f..bbb8961ca 100644
--- a/src/plugin/parse-zip/plugin.xml
+++ b/src/plugin/parse-zip/plugin.xml
@@ -32,15 +32,15 @@
</requires>
<extension id="org.apache.nutch.parse.zip"
- name="ZipParser"
+ name="ZipParser"
point="org.apache.nutch.parse.Parser">
- <implementation id="org.apache.nutch.parse.zip.ZipParser"
+ <implementation id="org.apache.nutch.parse.zip.ZipParser"
class="org.apache.nutch.parse.zip.ZipParser">
<parameter name="contentType" value="application/zip"/>
<parameter name="pathSuffix" value="zip"/>
</implementation>
-
+
</extension>
</plugin>
diff --git a/src/plugin/parse-zip/src/java/org/apache/nutch/parse/zip/ZipTextExtractor.java b/src/plugin/parse-zip/src/java/org/apache/nutch/parse/zip/ZipTextExtractor.java
index 6d1eb8149..476722001 100644
--- a/src/plugin/parse-zip/src/java/org/apache/nutch/parse/zip/ZipTextExtractor.java
+++ b/src/plugin/parse-zip/src/java/org/apache/nutch/parse/zip/ZipTextExtractor.java
@@ -40,7 +40,7 @@ import org.apache.nutch.protocol.Content;
import org.apache.tika.Tika;
/**
- *
+ *
*/
public class ZipTextExtractor {
diff --git a/src/plugin/parse-zip/src/test/org/apache/nutch/parse/zip/TestZipParser.java b/src/plugin/parse-zip/src/test/org/apache/nutch/parse/zip/TestZipParser.java
index d2752f02b..4a82a6681 100644
--- a/src/plugin/parse-zip/src/test/org/apache/nutch/parse/zip/TestZipParser.java
+++ b/src/plugin/parse-zip/src/test/org/apache/nutch/parse/zip/TestZipParser.java
@@ -33,7 +33,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
/**
* Based on Unit tests for MSWordParser by John Xing
- *
+ *
*/
public class TestZipParser {
diff --git a/src/plugin/parsefilter-debug/ivy.xml b/src/plugin/parsefilter-debug/ivy.xml
index 40fa475bd..1adffacd7 100644
--- a/src/plugin/parsefilter-debug/ivy.xml
+++ b/src/plugin/parsefilter-debug/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/parsefilter-debug/plugin.xml b/src/plugin/parsefilter-debug/plugin.xml
index 027d8fd6e..e27a23b00 100644
--- a/src/plugin/parsefilter-debug/plugin.xml
+++ b/src/plugin/parsefilter-debug/plugin.xml
@@ -33,7 +33,7 @@
<extension id="org.apache.nutch.htmlparsefilter.debug"
name="Nutch Debug Parser Filter" point="org.apache.nutch.parse.HtmlParseFilter">
- <implementation id="DebugParseFilter"
+ <implementation id="DebugParseFilter"
class="org.apache.nutch.parsefilter.debug.DebugParseFilter">
</implementation>
</extension>
diff --git a/src/plugin/parsefilter-naivebayes/ivy.xml b/src/plugin/parsefilter-naivebayes/ivy.xml
index bbe757be6..98cf2f282 100644
--- a/src/plugin/parsefilter-naivebayes/ivy.xml
+++ b/src/plugin/parsefilter-naivebayes/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/parsefilter-naivebayes/plugin.xml b/src/plugin/parsefilter-naivebayes/plugin.xml
index 32d7ce065..28bf805d4 100644
--- a/src/plugin/parsefilter-naivebayes/plugin.xml
+++ b/src/plugin/parsefilter-naivebayes/plugin.xml
@@ -33,7 +33,7 @@
<extension id="org.apache.nutch.htmlparsefilter.naivebayes"
name="Nutch NaiveBayes Parser Filter" point="org.apache.nutch.parse.HtmlParseFilter">
- <implementation id="NaiveBayesHTMLParseFilter"
+ <implementation id="NaiveBayesHTMLParseFilter"
class="org.apache.nutch.parsefilter.naivebayes.NaiveBayesParseFilter"/>
</extension>
diff --git a/src/plugin/parsefilter-regex/ivy.xml b/src/plugin/parsefilter-regex/ivy.xml
index e045f3595..1adffacd7 100644
--- a/src/plugin/parsefilter-regex/ivy.xml
+++ b/src/plugin/parsefilter-regex/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -34,5 +34,5 @@
<publications>
<!--get the artifact from our module name-->
<artifact conf="master"/>
- </publications>
+ </publications>
</ivy-module>
diff --git a/src/plugin/parsefilter-regex/plugin.xml b/src/plugin/parsefilter-regex/plugin.xml
index 0821d2d7c..3ae8e9942 100644
--- a/src/plugin/parsefilter-regex/plugin.xml
+++ b/src/plugin/parsefilter-regex/plugin.xml
@@ -33,7 +33,7 @@
<extension id="org.apache.nutch.htmlparsefilter.regex"
name="Nutch Regex Parser Filter" point="org.apache.nutch.parse.HtmlParseFilter">
- <implementation id="RegexParseFilter"
+ <implementation id="RegexParseFilter"
class="org.apache.nutch.parsefilter.regex.RegexParseFilter">
<parameter name="file" value="regex-parsefilter.txt"/>
</implementation>
diff --git a/src/plugin/parsefilter-regex/src/java/org/apache/nutch/parsefilter/regex/package-info.java b/src/plugin/parsefilter-regex/src/java/org/apache/nutch/parsefilter/regex/package-info.java
index f8f46ee46..08e3d603d 100644
--- a/src/plugin/parsefilter-regex/src/java/org/apache/nutch/parsefilter/regex/package-info.java
+++ b/src/plugin/parsefilter-regex/src/java/org/apache/nutch/parsefilter/regex/package-info.java
@@ -16,7 +16,7 @@
*/
/**
- * RegexParseFilter. If a regular expression matches either HTML or
+ * RegexParseFilter. If a regular expression matches either HTML or
* extracted text, a configurable field is set to true.
*/
package org.apache.nutch.parsefilter.regex;
diff --git a/src/plugin/plugin.dtd b/src/plugin/plugin.dtd
index 41b3fbb06..d31334d98 100644
--- a/src/plugin/plugin.dtd
+++ b/src/plugin/plugin.dtd
@@ -42,7 +42,7 @@
<!-- A user displayable name for the plug-in -->
<!ATTLIST plugin name CDATA #REQUIRED>
-<!--
+<!--
! A unique identifier for the plug-in.
! To minimize potential for naming collisions,
! the identifier should be derived from the internet domain id
@@ -69,7 +69,7 @@
<!ATTLIST plugin class CDATA #IMPLIED>
-<!--
+<!--
! The <requires> section of the manifest declares
! any dependencies on other plug-ins.
!-->
@@ -157,7 +157,7 @@
!-->
<!ELEMENT extension (implementation+)>
-<!--
+<!--
! A reference to an extension point being configured.
! The extension point can be one defined in this plug-in or another plug-in.
!-->
@@ -202,5 +202,5 @@
<!ATTLIST parameter name CDATA #REQUIRED>
<!-- The parameter's value -->
-<!ATTLIST parameter value CDATA #REQUIRED>
+<!ATTLIST parameter value CDATA #REQUIRED>
diff --git a/src/plugin/protocol-file/build.xml b/src/plugin/protocol-file/build.xml
index 121b1fe50..b1e670036 100644
--- a/src/plugin/protocol-file/build.xml
+++ b/src/plugin/protocol-file/build.xml
@@ -18,7 +18,7 @@
<project name="protocol-file" default="jar-core">
<import file="../build-plugin.xml"/>
-
+
<!-- for junit test -->
<mkdir dir="${build.test}/data"/>
<copy todir="${build.test}/data">
diff --git a/src/plugin/protocol-file/ivy.xml b/src/plugin/protocol-file/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/protocol-file/ivy.xml
+++ b/src/plugin/protocol-file/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-file/src/test/org/apache/nutch/protocol/file/TestProtocolFile.java b/src/plugin/protocol-file/src/test/org/apache/nutch/protocol/file/TestProtocolFile.java
index f0338f557..b60af70b1 100644
--- a/src/plugin/protocol-file/src/test/org/apache/nutch/protocol/file/TestProtocolFile.java
+++ b/src/plugin/protocol-file/src/test/org/apache/nutch/protocol/file/TestProtocolFile.java
@@ -37,7 +37,7 @@ import static org.junit.jupiter.api.Assertions.assertNotNull;
/**
* @version $Revision$
- *
+ *
* <p>
* Unit tests for the {@link File}Protocol.
* </p>
@@ -72,9 +72,9 @@ public class TestProtocolFile {
/**
* Tests the setting of the <code>Response.CONTENT_TYPE</code> metadata field.
- *
+ *
* @since NUTCH-384
- *
+ *
*/
public void setContentType(String testTextFile) throws ProtocolException {
String urlString = "file:" + sampleDir + fileSeparator + testTextFile;
diff --git a/src/plugin/protocol-foo/ivy.xml b/src/plugin/protocol-foo/ivy.xml
index 471b9dba9..0977d96fa 100755
--- a/src/plugin/protocol-foo/ivy.xml
+++ b/src/plugin/protocol-foo/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-foo/plugin.xml b/src/plugin/protocol-foo/plugin.xml
index 954a2d41a..6632187bc 100755
--- a/src/plugin/protocol-foo/plugin.xml
+++ b/src/plugin/protocol-foo/plugin.xml
@@ -41,7 +41,7 @@
<parameter name="protocolName" value="foo"/>
<parameter name="urlStreamHandler" value="org.apache.nutch.protocol.foo.Handler"/>
</implementation>
-
+
</extension>
</plugin>
diff --git a/src/plugin/protocol-ftp/ivy.xml b/src/plugin/protocol-ftp/ivy.xml
index b2326d174..7ea5190e5 100644
--- a/src/plugin/protocol-ftp/ivy.xml
+++ b/src/plugin/protocol-ftp/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -40,5 +40,5 @@
<dependency org="commons-net" name="commons-net" rev="3.9.0" conf="*->master"/>
<dependency org="org.mockftpserver" name="MockFtpServer" rev="3.2.0" conf="test->default"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-ftp/plugin.xml b/src/plugin/protocol-ftp/plugin.xml
index 1a4012c49..83ab6aacd 100644
--- a/src/plugin/protocol-ftp/plugin.xml
+++ b/src/plugin/protocol-ftp/plugin.xml
@@ -40,7 +40,7 @@
class="org.apache.nutch.protocol.ftp.Ftp">
<parameter name="protocolName" value="ftp"/>
</implementation>
-
+
</extension>
</plugin>
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpException.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpException.java
index da5d2d868..df4435a01 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpException.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpException.java
@@ -21,7 +21,7 @@ import org.apache.nutch.protocol.ProtocolException;
/***
* Superclass for important exceptions thrown during FTP talk, that must be
* handled with care.
- *
+ *
*/
public class FtpException extends ProtocolException {
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionBadSystResponse.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionBadSystResponse.java
index 86f66fa4f..ac5c88089 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionBadSystResponse.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionBadSystResponse.java
@@ -18,7 +18,7 @@ package org.apache.nutch.protocol.ftp;
/**
* Exception indicating bad reply of SYST command.
- *
+ *
*/
public class FtpExceptionBadSystResponse extends FtpException {
FtpExceptionBadSystResponse(String msg) {
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionCanNotHaveDataConnection.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionCanNotHaveDataConnection.java
index 32390be93..f14b050d8 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionCanNotHaveDataConnection.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionCanNotHaveDataConnection.java
@@ -18,7 +18,7 @@ package org.apache.nutch.protocol.ftp;
/**
* Exception indicating failure of opening data connection.
- *
+ *
*/
public class FtpExceptionCanNotHaveDataConnection extends FtpException {
FtpExceptionCanNotHaveDataConnection(String msg) {
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionControlClosedByForcedDataClose.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionControlClosedByForcedDataClose.java
index 3304bb488..a3b463b17 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionControlClosedByForcedDataClose.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionControlClosedByForcedDataClose.java
@@ -19,7 +19,7 @@ package org.apache.nutch.protocol.ftp;
/**
* Exception indicating control channel is closed by server end, due to forced
* closure of data channel at client (our) end.
- *
+ *
*/
public class FtpExceptionControlClosedByForcedDataClose extends FtpException {
FtpExceptionControlClosedByForcedDataClose(String msg) {
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionUnknownForcedDataClose.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionUnknownForcedDataClose.java
index 612eedc7f..590db4b38 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionUnknownForcedDataClose.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/FtpExceptionUnknownForcedDataClose.java
@@ -19,7 +19,7 @@ package org.apache.nutch.protocol.ftp;
/**
* Exception indicating unrecognizable reply from server after forced closure of
* data channel by client (our) side.
- *
+ *
*/
public class FtpExceptionUnknownForcedDataClose extends FtpException {
FtpExceptionUnknownForcedDataClose(String msg) {
diff --git a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/PrintCommandListener.java b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/PrintCommandListener.java
index e0a70d763..599f83513 100644
--- a/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/PrintCommandListener.java
+++ b/src/plugin/protocol-ftp/src/java/org/apache/nutch/protocol/ftp/PrintCommandListener.java
@@ -27,7 +27,7 @@ import org.apache.commons.net.ProtocolCommandListener;
/***
* This is a support class for logging all ftp command/reply traffic.
- *
+ *
***/
public class PrintCommandListener implements ProtocolCommandListener {
private Logger __logger;
diff --git a/src/plugin/protocol-htmlunit/ivy.xml b/src/plugin/protocol-htmlunit/ivy.xml
index 4186d33ba..4ee876d12 100644
--- a/src/plugin/protocol-htmlunit/ivy.xml
+++ b/src/plugin/protocol-htmlunit/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/protocol-htmlunit/plugin.xml b/src/plugin/protocol-htmlunit/plugin.xml
index e39618fc7..a56a7bd0d 100644
--- a/src/plugin/protocol-htmlunit/plugin.xml
+++ b/src/plugin/protocol-htmlunit/plugin.xml
@@ -41,7 +41,7 @@
class="org.apache.nutch.protocol.htmlunit.Http">
<parameter name="protocolName" value="http"/>
</implementation>
-
+
<implementation id="org.apache.nutch.protocol.htmlunit.Http"
class="org.apache.nutch.protocol.htmlunit.Http">
<parameter name="protocolName" value="https"/>
diff --git a/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/DummyX509TrustManager.java b/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/DummyX509TrustManager.java
index fbd670a9a..dbe391b96 100644
--- a/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/DummyX509TrustManager.java
+++ b/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/DummyX509TrustManager.java
@@ -38,7 +38,7 @@ public class DummyX509TrustManager implements X509TrustManager {
* @throws NoSuchAlgorithmException if there is a fatal error obtaining a
* {@link javax.net.ssl.TrustManagerFactory} for the default algorithm.
* @see TrustManagerFactory#getDefaultAlgorithm()
- * @throws KeyStoreException if there is a fatal error initializing the
+ * @throws KeyStoreException if there is a fatal error initializing the
* {@link javax.net.ssl.TrustManagerFactory} with the provided keystore.
*/
public DummyX509TrustManager(KeyStore keystore)
diff --git a/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/Http.java b/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/Http.java
index 40a694125..584b7f072 100644
--- a/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/Http.java
+++ b/src/plugin/protocol-htmlunit/src/java/org/apache/nutch/protocol/htmlunit/Http.java
@@ -45,7 +45,7 @@ public class Http extends HttpBase {
/**
* Set the {@link org.apache.hadoop.conf.Configuration} object.
- *
+ *
* @param conf a popultaed {@link Configuration}
*/
@Override
@@ -58,7 +58,7 @@ public class Http extends HttpBase {
http.setConf(NutchConfiguration.create());
main(http, args);
}
-
+
@Override
protected Response getResponse(URL url, CrawlDatum datum, boolean redirect)
throws ProtocolException, IOException {
diff --git a/src/plugin/protocol-http/ivy.xml b/src/plugin/protocol-http/ivy.xml
index 29871da12..4adf1feea 100644
--- a/src/plugin/protocol-http/ivy.xml
+++ b/src/plugin/protocol-http/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
- <ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+ <ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -40,5 +40,5 @@
<dependency org="org.littleshoot" name="littleproxy" rev="1.1.2" />
<dependency org="com.google.guava" name="guava" rev="20.0" force="true" />
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-http/plugin.xml b/src/plugin/protocol-http/plugin.xml
index 8770b1028..56ff84da9 100755
--- a/src/plugin/protocol-http/plugin.xml
+++ b/src/plugin/protocol-http/plugin.xml
@@ -40,7 +40,7 @@
class="org.apache.nutch.protocol.http.Http">
<parameter name="protocolName" value="http"/>
</implementation>
-
+
<implementation id="org.apache.nutch.protocol.http.Http"
class="org.apache.nutch.protocol.http.Http">
<parameter name="protocolName" value="https"/>
diff --git a/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/DummyX509TrustManager.java b/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/DummyX509TrustManager.java
index 28a64a8ab..991c2034b 100644
--- a/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/DummyX509TrustManager.java
+++ b/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/DummyX509TrustManager.java
@@ -45,7 +45,7 @@ public class DummyX509TrustManager implements X509TrustManager {
* @throws NoSuchAlgorithmException if there is a fatal error obtaining a
* {@link javax.net.ssl.TrustManagerFactory} for the default algorithm.
* @see TrustManagerFactory#getDefaultAlgorithm()
- * @throws KeyStoreException if there is a fatal error initializing the
+ * @throws KeyStoreException if there is a fatal error initializing the
* {@link javax.net.ssl.TrustManagerFactory} with the provided keystore.
*/
public DummyX509TrustManager(KeyStore keystore)
diff --git a/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/Http.java b/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/Http.java
index cc1022149..a264f2ad2 100644
--- a/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/Http.java
+++ b/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/Http.java
@@ -45,7 +45,7 @@ public class Http extends HttpBase {
/**
* Set the {@link org.apache.hadoop.conf.Configuration} object.
- *
+ *
* @param conf a populated {@link Configuration}
*/
@Override
diff --git a/src/plugin/protocol-http/src/test/org/apache/nutch/protocol/http/TestProtocolHttpByProxy.java b/src/plugin/protocol-http/src/test/org/apache/nutch/protocol/http/TestProtocolHttpByProxy.java
index 8a6b08faa..4dc326dff 100644
--- a/src/plugin/protocol-http/src/test/org/apache/nutch/protocol/http/TestProtocolHttpByProxy.java
+++ b/src/plugin/protocol-http/src/test/org/apache/nutch/protocol/http/TestProtocolHttpByProxy.java
@@ -44,7 +44,7 @@ public class TestProtocolHttpByProxy extends AbstractHttpProtocolPluginTest {
public static final String TARGET_HOST = "www.baidu.com";
public static final Integer TARGET_PORT = 443;
-
+
private HttpProxyServer server;
@BeforeEach
@@ -58,13 +58,13 @@ public class TestProtocolHttpByProxy extends AbstractHttpProtocolPluginTest {
server = DefaultHttpProxyServer.bootstrap()
.withPort(proxyPort).start();
}
-
+
private Integer findOpenPort() throws IOException {
try (ServerSocket socket = new ServerSocket(0)) {
return socket.getLocalPort();
}
}
-
+
@AfterEach
public void tearDown() {
server.stop();
diff --git a/src/plugin/protocol-httpclient/ivy.xml b/src/plugin/protocol-httpclient/ivy.xml
index e5987074b..0b53aed24 100644
--- a/src/plugin/protocol-httpclient/ivy.xml
+++ b/src/plugin/protocol-httpclient/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -40,5 +40,5 @@
<dependency org="org.jsoup" name="jsoup" rev="1.8.1" />
<dependency org="com.github.tomakehurst" name="wiremock-standalone" rev="3.0.1" conf="test->default"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-httpclient/plugin.xml b/src/plugin/protocol-httpclient/plugin.xml
index 453ddca4e..69f1370b0 100644
--- a/src/plugin/protocol-httpclient/plugin.xml
+++ b/src/plugin/protocol-httpclient/plugin.xml
@@ -6,9 +6,9 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -20,33 +20,33 @@
name="Http / Https Protocol Plug-in"
version="1.0.0"
provider-name="nutch.org">
-
+
<runtime>
<library name="protocol-httpclient.jar">
<export name="*"/>
</library>
<library name="jsoup-1.8.1.jar"/>
</runtime>
-
+
<requires>
<import plugin="nutch-extensionpoints"/>
<import plugin="lib-http"/>
</requires>
-
+
<extension id="org.apache.nutch.protocol.httpclient"
name="HttpClientProtocol"
point="org.apache.nutch.protocol.Protocol">
-
+
<implementation id="org.apache.nutch.protocol.httpclient.Http"
class="org.apache.nutch.protocol.httpclient.Http">
<parameter name="protocolName" value="http"/>
</implementation>
-
+
<implementation id="org.apache.nutch.protocol.httpclient.Http"
class="org.apache.nutch.protocol.httpclient.Http">
<parameter name="protocolName" value="https"/>
</implementation>
-
+
</extension>
-
+
</plugin>
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummySSLProtocolSocketFactory.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummySSLProtocolSocketFactory.java
index e0412206a..c1338fe64 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummySSLProtocolSocketFactory.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummySSLProtocolSocketFactory.java
@@ -97,7 +97,7 @@ public class DummySSLProtocolSocketFactory implements
* does not return until the timeout expires, the controller terminates and
* throws an {@link ConnectTimeoutException}
* </p>
- *
+ *
* @param host
* the host name/IP
* @param port
@@ -108,9 +108,9 @@ public class DummySSLProtocolSocketFactory implements
* the port on the local machine
* @param params
* {@link HttpConnectionParams Http connection parameters}
- *
+ *
* @return Socket a new socket
- *
+ *
* @throws IOException
* if an I/O error occurs while creating the socket
* @throws UnknownHostException
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummyX509TrustManager.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummyX509TrustManager.java
index 859dfff52..211b0b657 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummyX509TrustManager.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/DummyX509TrustManager.java
@@ -38,7 +38,7 @@ public class DummyX509TrustManager implements X509TrustManager {
* @throws NoSuchAlgorithmException if there is a fatal error obtaining a
* {@link javax.net.ssl.TrustManagerFactory} for the default algorithm.
* @see TrustManagerFactory#getDefaultAlgorithm()
- * @throws KeyStoreException if there is a fatal error initializing the
+ * @throws KeyStoreException if there is a fatal error initializing the
* {@link javax.net.ssl.TrustManagerFactory} with the provided keystore.
*/
public DummyX509TrustManager(KeyStore keystore)
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/Http.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/Http.java
index 7048236ce..d5522c204 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/Http.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/Http.java
@@ -75,7 +75,7 @@ import org.apache.nutch.util.XmlUtil;
* HttpPostAuthentication development is documented at the
* <a href="https://issues.apache.org/jira/browse/NUTCH-827">NUTCH-827</a> Jira
* issue.
- *
+ *
*/
public class Http extends HttpBase {
@@ -106,7 +106,7 @@ public class Http extends HttpBase {
/**
* Returns the configured HTTP client.
- *
+ *
* @return HTTP client
*/
static synchronized HttpClient getClient() {
@@ -123,7 +123,7 @@ public class Http extends HttpBase {
/**
* Reads the configuration from the Nutch configuration files and sets the
* configuration.
- *
+ *
* @param conf
* Configuration
*/
@@ -148,7 +148,7 @@ public class Http extends HttpBase {
/**
* Main method.
- *
+ *
* @param args
* Command line arguments
* @throws Exception if a fatal error is encountered whilst running
@@ -163,7 +163,7 @@ public class Http extends HttpBase {
/**
* Fetches the <code>url</code> with a configured HTTP client and gets the
* response.
- *
+ *
* @param url
* URL to be fetched
* @param datum
@@ -257,7 +257,7 @@ public class Http extends HttpBase {
* Reads authentication configuration file (defined as 'http.auth.file' in
* Nutch configuration file) and sets the credentials for the configured
* authentication scopes in the HTTP client object.
- *
+ *
* @throws ParserConfigurationException
* If a document builder can not be created.
* @throws SAXException
@@ -483,7 +483,7 @@ public class Http extends HttpBase {
* sets the default credentials to fetch the specified <code>url</code>. If
* credentials are found for the authentication scope, the method returns
* without altering the client.
- *
+ *
* @param url
* URL to be fetched
*/
@@ -540,7 +540,7 @@ public class Http extends HttpBase {
/**
* Returns an authentication scope for the specified <code>host</code>,
* <code>port</code>, <code>realm</code> and <code>scheme</code>.
- *
+ *
* @param host
* Host name or address.
* @param port
@@ -571,7 +571,7 @@ public class Http extends HttpBase {
/**
* Returns an authentication scope for the specified <code>host</code>,
* <code>port</code> and <code>realm</code>.
- *
+ *
* @param host
* Host name or address.
* @param port
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthentication.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthentication.java
index d0a258f7c..cac15cbe8 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthentication.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthentication.java
@@ -20,23 +20,23 @@ import java.util.List;
/**
* The base level of services required for Http Authentication
- *
+ *
* @see HttpAuthenticationFactory
- *
+ *
*/
public interface HttpAuthentication {
/**
* Gets the credentials generated by the HttpAuthentication object. May return
* null.
- *
+ *
* @return The credentials value
*/
public List<String> getCredentials();
/**
* Gets the realm used by the HttpAuthentication object during creation.
- *
+ *
* @return The realm value
*/
public String getRealm();
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationException.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationException.java
index 2f5b5c2bb..77d932242 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationException.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationException.java
@@ -21,7 +21,7 @@ package org.apache.nutch.protocol.httpclient;
* In the future it may be used as a method of collecting authentication
* failures during Http protocol transfer in order to present the user with
* credentials required during a future fetch.
- *
+ *
*/
public class HttpAuthenticationException extends Exception {
@@ -34,7 +34,7 @@ public class HttpAuthenticationException extends Exception {
/**
* Constructs a new exception with the specified detail message.
- *
+ *
* @param message
* the detail message. The detail message is saved for later
* retrieval by the {@link Throwable#getMessage()} method.
@@ -45,7 +45,7 @@ public class HttpAuthenticationException extends Exception {
/**
* Constructs a new exception with the specified message and cause.
- *
+ *
* @param message
* the detail message. The detail message is saved for later
* retrieval by the {@link Throwable#getMessage()} method.
@@ -59,7 +59,7 @@ public class HttpAuthenticationException extends Exception {
/**
* Constructs a new exception with the specified cause and detail message from
* given clause if it is not null.
- *
+ *
* @param cause
* the cause (use {@link #getCause()} to retrieve the cause)
*/
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationFactory.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationFactory.java
index 2a89e8b6a..edea0bcd4 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationFactory.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpAuthenticationFactory.java
@@ -32,11 +32,11 @@ import org.apache.nutch.metadata.Metadata;
* Provides the Http protocol implementation with the ability to authenticate
* when prompted. The goal is to provide multiple authentication types but for
* now just the {@link HttpBasicAuthentication} authentication type is provided.
- *
+ *
* @see HttpBasicAuthentication
* @see Http
* @see HttpResponse
- *
+ *
*/
public class HttpAuthenticationFactory implements Configurable {
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpFormAuthentication.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpFormAuthentication.java
index a960094ca..c97ab154a 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpFormAuthentication.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpFormAuthentication.java
@@ -146,13 +146,13 @@ public class HttpFormAuthentication {
/**
* NUTCH-2280 Set the cookie policy value from httpclient-auth.xml for the
* Post httpClient action.
- *
+ *
* @param fromConfigurer
* - the httpclient-auth.xml values
- *
+ *
* @param params
* - the HttpMethodParams from the current httpclient instance
- *
+ *
* @throws NoSuchFieldException
* @throws SecurityException
* @throws IllegalArgumentException
diff --git a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
index 6d7343f28..d0c6b274f 100644
--- a/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
+++ b/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
@@ -40,7 +40,7 @@ import org.apache.hadoop.io.Text;
/**
* An HTTP response.
- *
+ *
*/
public class HttpResponse implements Response {
@@ -51,7 +51,7 @@ public class HttpResponse implements Response {
/**
* Fetches the given <code>url</code> and prepares HTTP response.
- *
+ *
* @param http
* An instance of the implementation class of this plugin
* @param url
@@ -98,23 +98,23 @@ public class HttpResponse implements Response {
// XXX the request body was sent the method is not retried, so there is
// XXX little danger in retrying...
// params.setParameter(HttpMethodParams.RETRY_HANDLER, null);
-
+
if (http.isCookieEnabled()) {
String cookie = null;
-
+
if (datum.getMetaData().containsKey(http.COOKIE)) {
cookie = ((Text)datum.getMetaData().get(http.COOKIE)).toString();
}
-
+
if (cookie == null) {
cookie = http.getCookie(url);
}
-
+
if (cookie != null) {
get.addRequestHeader("Cookie", cookie);
}
}
-
+
try {
HttpClient client = Http.getClient();
client.getParams().setParameter("http.useragent", http.getUserAgent()); // NUTCH-1941
diff --git a/src/plugin/protocol-interactiveselenium/ivy.xml b/src/plugin/protocol-interactiveselenium/ivy.xml
index e20576828..d71f666dd 100644
--- a/src/plugin/protocol-interactiveselenium/ivy.xml
+++ b/src/plugin/protocol-interactiveselenium/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<!-- Note: only dependencies which are not contained in lib-selenium have to be listed here! -->
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/DummyX509TrustManager.java b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/DummyX509TrustManager.java
index 8f9d69be9..576f1e089 100644
--- a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/DummyX509TrustManager.java
+++ b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/DummyX509TrustManager.java
@@ -38,7 +38,7 @@ public class DummyX509TrustManager implements X509TrustManager {
* @throws NoSuchAlgorithmException if there is a fatal error obtaining a
* {@link javax.net.ssl.TrustManagerFactory} for the default algorithm.
* @see TrustManagerFactory#getDefaultAlgorithm()
- * @throws KeyStoreException if there is a fatal error initializing the
+ * @throws KeyStoreException if there is a fatal error initializing the
* {@link javax.net.ssl.TrustManagerFactory} with the provided keystore.
*/
public DummyX509TrustManager(KeyStore keystore)
diff --git a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefalultMultiInteractionHandler.java b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefalultMultiInteractionHandler.java
index 831bab63e..9c4820d5e 100644
--- a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefalultMultiInteractionHandler.java
+++ b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefalultMultiInteractionHandler.java
@@ -25,9 +25,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
- * This is a placeholder/example of a technique or use case where we do multiple
- * interaction with the web driver and need data from each such interaction in the end. This code shows that after you have
- * done multiple interactions and accumulated data you can in the end append that to the driver.
+ * This is a placeholder/example of a technique or use case where we do multiple
+ * interaction with the web driver and need data from each such interaction in the end. This code shows that after you have
+ * done multiple interactions and accumulated data you can in the end append that to the driver.
*/
public class DefalultMultiInteractionHandler implements
InteractiveSeleniumHandler {
@@ -39,7 +39,7 @@ public class DefalultMultiInteractionHandler implements
// loop and get multiple pages in this string
String accumulatedData = "";
try {
-
+
// append the string to the last page's driver
JavascriptExecutor jsx = (JavascriptExecutor) driver;
jsx.executeScript("document.body.innerHTML=document.body.innerHTML "
diff --git a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefaultClickAllAjaxLinksHandler.java b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefaultClickAllAjaxLinksHandler.java
index 178c804b1..95909c769 100644
--- a/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefaultClickAllAjaxLinksHandler.java
+++ b/src/plugin/protocol-interactiveselenium/src/java/org/apache/nutch/protocol/interactiveselenium/handlers/DefaultClickAllAjaxLinksHandler.java
@@ -33,8 +33,8 @@ import org.slf4j.LoggerFactory;
/**
* This handler clicks all the <code><a href="javascript:void(null);"></a></code> tags
- * because it considers them as not usual links but ajax links/interactions. This uses the same logic of
- * DefalultMultiInteractionHandler.
+ * because it considers them as not usual links but ajax links/interactions. This uses the same logic of
+ * DefalultMultiInteractionHandler.
*/
public class DefaultClickAllAjaxLinksHandler implements InteractiveSeleniumHandler {
private static final Logger LOG = LoggerFactory
@@ -42,10 +42,10 @@ public class DefaultClickAllAjaxLinksHandler implements InteractiveSeleniumHandl
@Override
public String processDriver(WebDriver driver) {
-
+
String accumulatedData = "";
try {
-
+
driver.findElement(By.tagName("body")).getAttribute("innerHTML");
Configuration conf = NutchConfiguration.create();
diff --git a/src/plugin/protocol-okhttp/ivy.xml b/src/plugin/protocol-okhttp/ivy.xml
index a90932e4f..6f9be01c8 100644
--- a/src/plugin/protocol-okhttp/ivy.xml
+++ b/src/plugin/protocol-okhttp/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/protocol-okhttp/src/java/org/apache/nutch/protocol/okhttp/OkHttp.java b/src/plugin/protocol-okhttp/src/java/org/apache/nutch/protocol/okhttp/OkHttp.java
index be26886fe..cf3b2a12d 100644
--- a/src/plugin/protocol-okhttp/src/java/org/apache/nutch/protocol/okhttp/OkHttp.java
+++ b/src/plugin/protocol-okhttp/src/java/org/apache/nutch/protocol/okhttp/OkHttp.java
@@ -424,7 +424,7 @@ public class OkHttp extends HttpBase {
/**
* Distribute hosts over clients by host name
- *
+ *
* @param url
* URL to fetch
* @return client responsible to fetch the given URL
diff --git a/src/plugin/protocol-selenium/ivy.xml b/src/plugin/protocol-selenium/ivy.xml
index e20576828..d71f666dd 100644
--- a/src/plugin/protocol-selenium/ivy.xml
+++ b/src/plugin/protocol-selenium/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<!-- Note: only dependencies which are not contained in lib-selenium have to be listed here! -->
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/protocol-selenium/src/java/org/apache/nutch/protocol/selenium/DummyX509TrustManager.java b/src/plugin/protocol-selenium/src/java/org/apache/nutch/protocol/selenium/DummyX509TrustManager.java
index 48bfe22fc..e84a8385b 100644
--- a/src/plugin/protocol-selenium/src/java/org/apache/nutch/protocol/selenium/DummyX509TrustManager.java
+++ b/src/plugin/protocol-selenium/src/java/org/apache/nutch/protocol/selenium/DummyX509TrustManager.java
@@ -38,7 +38,7 @@ public class DummyX509TrustManager implements X509TrustManager {
* @throws NoSuchAlgorithmException if there is a fatal error obtaining a
* {@link javax.net.ssl.TrustManagerFactory} for the default algorithm.
* @see TrustManagerFactory#getDefaultAlgorithm()
- * @throws KeyStoreException if there is a fatal error initializing the
+ * @throws KeyStoreException if there is a fatal error initializing the
* {@link javax.net.ssl.TrustManagerFactory} with the provided keystore.
*/
public DummyX509TrustManager(KeyStore keystore)
diff --git a/src/plugin/publish-rabbitmq/ivy.xml b/src/plugin/publish-rabbitmq/ivy.xml
index 1990dca9b..d12108e33 100644
--- a/src/plugin/publish-rabbitmq/ivy.xml
+++ b/src/plugin/publish-rabbitmq/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
diff --git a/src/plugin/publish-rabbitmq/plugin.xml b/src/plugin/publish-rabbitmq/plugin.xml
index d78473cc0..64b78a382 100644
--- a/src/plugin/publish-rabbitmq/plugin.xml
+++ b/src/plugin/publish-rabbitmq/plugin.xml
@@ -31,7 +31,7 @@
<import plugin="nutch-extensionpoints"/>
<import plugin="lib-rabbitmq"/>
</requires>
-
+
<extension id="org.apache.nutch.publisher.rabbitmq"
name="RabbitMQPublisherImpl"
point="org.apache.nutch.publisher.NutchPublisher">
diff --git a/src/plugin/scoring-depth/ivy.xml b/src/plugin/scoring-depth/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/scoring-depth/ivy.xml
+++ b/src/plugin/scoring-depth/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-link/ivy.xml b/src/plugin/scoring-link/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/scoring-link/ivy.xml
+++ b/src/plugin/scoring-link/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-metadata/ivy.xml b/src/plugin/scoring-metadata/ivy.xml
index 0c1496ba9..9104bc327 100644
--- a/src/plugin/scoring-metadata/ivy.xml
+++ b/src/plugin/scoring-metadata/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/MetadataScoringFilter.java b/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/MetadataScoringFilter.java
index b984492c3..6dca2ab88 100644
--- a/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/MetadataScoringFilter.java
+++ b/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/MetadataScoringFilter.java
@@ -33,7 +33,7 @@ import org.apache.nutch.scoring.ScoringFilterException;
/**
* For documentation:
- *
+ *
* {@link org.apache.nutch.scoring.metadata}
*/
public class MetadataScoringFilter extends AbstractScoringFilter {
@@ -50,7 +50,7 @@ public class MetadataScoringFilter extends AbstractScoringFilter {
* property, and looks for them inside the parseData object. If they exist,
* this will be propagated into your 'targets' Collection's ["outlinks"]
* attributes.
- *
+ *
* @see ScoringFilter#distributeScoreToOutlinks
*/
@Override
@@ -82,7 +82,7 @@ public class MetadataScoringFilter extends AbstractScoringFilter {
* Takes the metadata, specified in your "scoring.db.md" property, from the
* datum object and injects it into the content. This is transferred to the
* parseData object.
- *
+ *
* @see ScoringFilter#passScoreBeforeParsing
* @see MetadataScoringFilter#passScoreAfterParsing
*/
@@ -105,7 +105,7 @@ public class MetadataScoringFilter extends AbstractScoringFilter {
/**
* Takes the metadata, which was lumped inside the content, and replicates it
* within your parse data.
- *
+ *
* @see MetadataScoringFilter#passScoreBeforeParsing
* @see ScoringFilter#passScoreAfterParsing
*/
diff --git a/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/package-info.java b/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/package-info.java
index b3ddbd1f0..e38c33f3a 100644
--- a/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/package-info.java
+++ b/src/plugin/scoring-metadata/src/java/org/apache/nutch/scoring/metadata/package-info.java
@@ -17,16 +17,16 @@
/**
* <p>Metadata Scoring Plugin</p>
- * <p>Propagates Metadata from an injected or outlink url in the crawldb
- * to the url's different procecssed objects. In moving any metadata
+ * <p>Propagates Metadata from an injected or outlink url in the crawldb
+ * to the url's different procecssed objects. In moving any metadata
* item, you need to copy metadata in three steps:</p>
* <ul>
* <li>Crawldb to content: Copy a metadata entry stored in the crawldb record of the url to the url's fetched content object. You need to specify the entry in the <b>scoring.db.md</b> property</li>
* <li>Content to parsedData: Copy a metadata entry stored in the Content object of a crawled url to its parsedData. You need to specify the entry in the <b>scoring.content.md</b> property</li>
* <li>ParsedData to outlink objects: Copy a metadata entry stored in the parsedData of a crawl item to the crawldb records of the url's outlinks. You need to specify the entry in the <b>scoring.parse.md</b> property</li>
* </ul>
- * <p>Note that you can not move data directly from a crawldb record to
- * parseData or outlink objects. The sequence of moving the metadata
+ * <p>Note that you can not move data directly from a crawldb record to
+ * parseData or outlink objects. The sequence of moving the metadata
* should be crawldb -&gt; content -&gt; parsedData -&gt; outlink objects.</p>
*/
package org.apache.nutch.scoring.metadata;
diff --git a/src/plugin/scoring-opic/ivy.xml b/src/plugin/scoring-opic/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/scoring-opic/ivy.xml
+++ b/src/plugin/scoring-opic/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-opic/src/java/org/apache/nutch/scoring/opic/OPICScoringFilter.java b/src/plugin/scoring-opic/src/java/org/apache/nutch/scoring/opic/OPICScoringFilter.java
index 2c698ad72..03a114fd5 100644
--- a/src/plugin/scoring-opic/src/java/org/apache/nutch/scoring/opic/OPICScoringFilter.java
+++ b/src/plugin/scoring-opic/src/java/org/apache/nutch/scoring/opic/OPICScoringFilter.java
@@ -43,7 +43,7 @@ import org.apache.nutch.scoring.ScoringFilterException;
* (OPIC) score, described in this <a href="https://www2003.org/cdrom/papers/refereed/p007/p7-abiteboul.html">paper</a>:
* Abiteboul, Serge and Preda, Mihai and Cobena, Gregory (2003), Adaptive
* On-Line Page Importance Computation.
- *
+ *
*/
public class OPICScoringFilter implements ScoringFilter {
diff --git a/src/plugin/scoring-orphan/ivy.xml b/src/plugin/scoring-orphan/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/scoring-orphan/ivy.xml
+++ b/src/plugin/scoring-orphan/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-similarity/ivy.xml b/src/plugin/scoring-similarity/ivy.xml
index f96fecf30..aedfc1705 100644
--- a/src/plugin/scoring-similarity/ivy.xml
+++ b/src/plugin/scoring-similarity/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<dependency org="org.apache.lucene" name="lucene-analyzers-common" rev="8.11.2" conf="*->default"/>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/scoring-similarity/plugin.xml b/src/plugin/scoring-similarity/plugin.xml
index 4ed059266..b8b520af7 100644
--- a/src/plugin/scoring-similarity/plugin.xml
+++ b/src/plugin/scoring-similarity/plugin.xml
@@ -33,7 +33,7 @@
<requires>
<import plugin="nutch-extensionpoints"/>
</requires>
-
+
<extension id="org.apache.nutch.scoring.similarity"
name="SimilarityScoring"
point="org.apache.nutch.scoring.ScoringFilter">
diff --git a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/SimilarityModel.java b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/SimilarityModel.java
index 57f73c5fd..1247b6bca 100644
--- a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/SimilarityModel.java
+++ b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/SimilarityModel.java
@@ -29,9 +29,9 @@ import org.apache.nutch.protocol.Content;
public interface SimilarityModel {
public void setConf(Configuration conf);
-
+
public float setURLScoreAfterParsing(Text url, Content content, Parse parse);
-
+
public CrawlDatum distributeScoreToOutlinks(Text fromUrl,
ParseData parseData, Collection<Entry<Text, CrawlDatum>> targets,
CrawlDatum adjust, int allCount);
diff --git a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/DocVector.java b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/DocVector.java
index 2d57fd7a6..39b0477e2 100644
--- a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/DocVector.java
+++ b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/DocVector.java
@@ -31,11 +31,11 @@ public class DocVector {
public void setTermFreqVector(HashMap<String, Integer> termFreqVector) {
this.termFreqVector = termFreqVector;
}
-
+
public void setVectorEntry(int pos, long freq) {
termVector.put(pos, freq);
}
-
+
public float dotProduct(DocVector docVector) {
float product = 0;
for(Map.Entry<String, Integer> entry : termFreqVector.entrySet()) {
@@ -45,7 +45,7 @@ public class DocVector {
}
return product;
}
-
+
public float getL2Norm() {
float sum = 0;
for(Map.Entry<String, Integer> entry : termFreqVector.entrySet()) {
diff --git a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/Model.java b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/Model.java
index 32278eead..82ac5e2ce 100644
--- a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/Model.java
+++ b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/Model.java
@@ -34,7 +34,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
- * This class creates a model used to store Document vector representation of the corpus.
+ * This class creates a model used to store Document vector representation of the corpus.
*
*/
public class Model {
@@ -69,7 +69,7 @@ public class Model {
int maxgram = ngramArr[1];
LOG.info("Value of mingram: {} maxgram: {}", mingram, maxgram);
- // TODO : Allow for corpus of documents to be provided as gold standard.
+ // TODO : Allow for corpus of documents to be provided as gold standard.
String line;
StringBuilder sb = new StringBuilder();
BufferedReader br = new BufferedReader(conf.getConfResourceAsReader((conf.get("cosine.goldstandard.file"))));
@@ -83,7 +83,7 @@ public class Model {
throw new Exception("Could not create DocVector for goldstandard");
}
} catch (Exception e) {
- LOG.warn("Failed to add {} to model : {}",conf.get("cosine.goldstandard.file","goldstandard.txt.template"),
+ LOG.warn("Failed to add {} to model : {}",conf.get("cosine.goldstandard.file","goldstandard.txt.template"),
StringUtils.stringifyException(e));
}
if(docVectors.size()>0) {
@@ -95,7 +95,7 @@ public class Model {
}
/**
- * Used to create a DocVector from given String text. Used during the parse stage of the crawl
+ * Used to create a DocVector from given String text. Used during the parse stage of the crawl
* cycle to create a DocVector of the currently parsed page from the parseText attribute value
* @param content The text to tokenize
* @param mingram Value of mingram for tokenizing
@@ -114,11 +114,11 @@ public class Model {
tokenizer = new LuceneTokenizer(content, TokenizerType.STANDARD, StemFilterType.PORTERSTEM_FILTER, mingram, maxgram);
}
else if(stopWords!=null) {
- tokenizer = new LuceneTokenizer(content, TokenizerType.STANDARD, stopWords, true,
+ tokenizer = new LuceneTokenizer(content, TokenizerType.STANDARD, stopWords, true,
StemFilterType.PORTERSTEM_FILTER);
}
else {
- tokenizer = new LuceneTokenizer(content, TokenizerType.STANDARD, true,
+ tokenizer = new LuceneTokenizer(content, TokenizerType.STANDARD, true,
StemFilterType.PORTERSTEM_FILTER);
}
TokenStream tStream = tokenizer.getTokenStream();
diff --git a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneAnalyzerUtil.java b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneAnalyzerUtil.java
index 0c1e5fc62..397c9774f 100644
--- a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneAnalyzerUtil.java
+++ b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneAnalyzerUtil.java
@@ -33,22 +33,22 @@ import org.apache.lucene.analysis.CharArraySet;
* Creates a custom analyzer based on user provided inputs
*
*/
-public class LuceneAnalyzerUtil extends Analyzer{
-
+public class LuceneAnalyzerUtil extends Analyzer{
+
public static enum StemFilterType { PORTERSTEM_FILTER, ENGLISHMINIMALSTEM_FILTER, NONE }
-
+
private static StemFilterType stemFilterType;
private static CharArraySet stopSet;
-
-
+
+
/**
- * Creates an analyzer instance based on Lucene default stopword
+ * Creates an analyzer instance based on Lucene default stopword
* set if the param useStopFilter is set to true
* @param stemFilterType a preferred {@link StemFilterType} to use. Can be one
* of {@link LuceneAnalyzerUtil.StemFilterType#PORTERSTEM_FILTER},
* {@link LuceneAnalyzerUtil.StemFilterType#ENGLISHMINIMALSTEM_FILTER}, or
* {@link LuceneAnalyzerUtil.StemFilterType#NONE}
- * @param useStopFilter if true use the default Lucene stopword set,
+ * @param useStopFilter if true use the default Lucene stopword set,
* false otherwise
*/
public LuceneAnalyzerUtil(StemFilterType stemFilterType, boolean useStopFilter) {
@@ -60,10 +60,10 @@ public class LuceneAnalyzerUtil extends Analyzer{
stopSet = null;
}
}
-
+
/**
- * Creates an analyzer instance based on user provided stop words. If the
- * param addToDefault is set to true, then
+ * Creates an analyzer instance based on user provided stop words. If the
+ * param addToDefault is set to true, then
* user provided stop words will be added to the Lucene default stopset.
* @param stemFilterType a preferred {@link StemFilterType} to use. Can be one
* of {@link LuceneAnalyzerUtil.StemFilterType#PORTERSTEM_FILTER},
@@ -71,7 +71,7 @@ public class LuceneAnalyzerUtil extends Analyzer{
* {@link LuceneAnalyzerUtil.StemFilterType#NONE}
* @param stopWords a {@link List} of stop word Strings
* @param addToDefault if true the provided stop words will be added to the
- * default Lucene stopword set,
+ * default Lucene stopword set,
* false otherwise
*/
public LuceneAnalyzerUtil(StemFilterType stemFilterType, List<String> stopWords, boolean addToDefault) {
@@ -83,7 +83,7 @@ public class LuceneAnalyzerUtil extends Analyzer{
stopSet = StopFilter.makeStopSet(stopWords);
}
}
-
+
@Override
protected TokenStreamComponents createComponents(String fieldName) {
Tokenizer source = new ClassicTokenizer();
@@ -91,7 +91,7 @@ public class LuceneAnalyzerUtil extends Analyzer{
if(stopSet != null) {
filter = new StopFilter(filter, stopSet);
}
-
+
switch(stemFilterType){
case PORTERSTEM_FILTER:
filter = new PorterStemFilter(filter);
@@ -100,7 +100,7 @@ public class LuceneAnalyzerUtil extends Analyzer{
filter = new EnglishMinimalStemFilter(filter);
break;
default:
- break;
+ break;
}
return new TokenStreamComponents(source, filter);
}
diff --git a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneTokenizer.java b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneTokenizer.java
index 8567a39b2..8b637e304 100644
--- a/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneTokenizer.java
+++ b/src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/util/LuceneTokenizer.java
@@ -34,7 +34,7 @@ import org.apache.nutch.scoring.similarity.util.LuceneAnalyzerUtil.StemFilterTyp
public class LuceneTokenizer {
- private TokenStream tokenStream;
+ private TokenStream tokenStream;
private TokenizerType tokenizer;
private StemFilterType stemFilterType;
private CharArraySet stopSet = null;
@@ -44,14 +44,14 @@ public class LuceneTokenizer {
/**
* Creates a tokenizer based on param values
* @param content - The text to tokenize
- * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
- * @param useStopFilter - if set to true the token stream will be filtered using default Lucene stopset
+ * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
+ * @param useStopFilter - if set to true the token stream will be filtered using default Lucene stopset
* @param stemFilterType a preferred {@link StemFilterType} to use. Can be one
* of {@link LuceneAnalyzerUtil.StemFilterType#PORTERSTEM_FILTER},
* {@link LuceneAnalyzerUtil.StemFilterType#ENGLISHMINIMALSTEM_FILTER}, or
* {@link LuceneAnalyzerUtil.StemFilterType#NONE}
*/
- public LuceneTokenizer(String content, TokenizerType tokenizer, boolean useStopFilter,
+ public LuceneTokenizer(String content, TokenizerType tokenizer, boolean useStopFilter,
StemFilterType stemFilterType) {
this.tokenizer = tokenizer;
this.stemFilterType = stemFilterType;
@@ -64,7 +64,7 @@ public class LuceneTokenizer {
/**
* Creates a tokenizer based on param values
* @param content - The text to tokenize
- * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
+ * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
* @param stopWords - Provide a set of user defined stop words
* @param addToDefault - If set to true, the stopSet words will be added to the Lucene default stop set.
* If false, then only the user provided words will be used as the stop set
@@ -73,7 +73,7 @@ public class LuceneTokenizer {
* {@link LuceneAnalyzerUtil.StemFilterType#ENGLISHMINIMALSTEM_FILTER}, or
* {@link LuceneAnalyzerUtil.StemFilterType#NONE}
*/
- public LuceneTokenizer(String content, TokenizerType tokenizer, List<String> stopWords,
+ public LuceneTokenizer(String content, TokenizerType tokenizer, List<String> stopWords,
boolean addToDefault, StemFilterType stemFilterType) {
this.tokenizer = tokenizer;
this.stemFilterType = stemFilterType;
@@ -97,11 +97,11 @@ public class LuceneTokenizer {
public TokenStream getTokenStream() {
return tokenStream;
}
-
+
/**
* Creates a tokenizer for the ngram model based on param values
* @param content - The text to tokenize
- * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
+ * @param tokenizer - the type of tokenizer to use CLASSIC or DEFAULT
* @param stemFilterType - Type of stemming to perform
* @param mingram - Value of mingram for tokenizing
* @param maxgram - Value of maxgram for tokenizing
@@ -111,7 +111,7 @@ public class LuceneTokenizer {
this.stemFilterType = stemFilterType;
tokenStream = createNGramTokenStream(content, mingram, maxgram);
}
-
+
private TokenStream createTokenStream(String content) {
tokenStream = generateTokenStreamFromText(content, tokenizer);
tokenStream = new LowerCaseFilter(tokenStream);
@@ -153,7 +153,7 @@ public class LuceneTokenizer {
}
private TokenStream applyStopFilter(CharArraySet stopWords) {
- tokenStream = new StopFilter(tokenStream, stopWords);
+ tokenStream = new StopFilter(tokenStream, stopWords);
return tokenStream;
}
@@ -169,6 +169,6 @@ public class LuceneTokenizer {
break;
}
- return tokenStream;
+ return tokenStream;
}
}
diff --git a/src/plugin/subcollection/README.txt b/src/plugin/subcollection/README.txt
index 6b79d1634..900812c77 100644
--- a/src/plugin/subcollection/README.txt
+++ b/src/plugin/subcollection/README.txt
@@ -5,6 +5,6 @@ Basically:
You need to enable this during indexing and during searching
After indexing you can limit your searches to certain
-subcollection with keyword subcollection, eg.
+subcollection with keyword subcollection, eg.
"subcollection:nutch hadoop"
diff --git a/src/plugin/subcollection/ivy.xml b/src/plugin/subcollection/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/subcollection/ivy.xml
+++ b/src/plugin/subcollection/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/subcollection/plugin.xml b/src/plugin/subcollection/plugin.xml
index ca2cf2f99..87e23d615 100644
--- a/src/plugin/subcollection/plugin.xml
+++ b/src/plugin/subcollection/plugin.xml
@@ -26,7 +26,7 @@
<export name="*"/>
</library>
</runtime>
-
+
<requires>
<import plugin="nutch-extensionpoints"/>
</requires>
@@ -36,6 +36,6 @@
point="org.apache.nutch.indexer.IndexingFilter">
<implementation id="SubcollectionIndexingFilter"
class="org.apache.nutch.indexer.subcollection.SubcollectionIndexingFilter"/>
-
+
</extension>
</plugin>
diff --git a/src/plugin/subcollection/src/java/org/apache/nutch/collection/CollectionManager.java b/src/plugin/subcollection/src/java/org/apache/nutch/collection/CollectionManager.java
index 3dc9f8c27..aa399fa8e 100644
--- a/src/plugin/subcollection/src/java/org/apache/nutch/collection/CollectionManager.java
+++ b/src/plugin/subcollection/src/java/org/apache/nutch/collection/CollectionManager.java
@@ -120,7 +120,7 @@ public class CollectionManager extends Configured {
/**
* Get the named subcollection
- *
+ *
* @param id the id of a subcollection to retrieve
* @return Named SubCollection (or null if not existing)
*/
@@ -130,7 +130,7 @@ public class CollectionManager extends Configured {
/**
* Delete named subcollection
- *
+ *
* @param id
* Id of SubCollection to delete
* @throws IOException If there is an error retrieving and deleting
@@ -145,7 +145,7 @@ public class CollectionManager extends Configured {
/**
* Create a new subcollection.
- *
+ *
* @param id
* Id of SubCollection to create
* @param name
@@ -165,7 +165,7 @@ public class CollectionManager extends Configured {
/**
* Return names of collections url is part of
- *
+ *
* @param url
* The url to test against Collections
* @return A {@link List} of {@link Subcollection}'s
@@ -189,7 +189,7 @@ public class CollectionManager extends Configured {
/**
* Returns all collections
- *
+ *
* @return All collections CollectionManager knows about
*/
public Collection<Subcollection> getAll() {
@@ -198,11 +198,11 @@ public class CollectionManager extends Configured {
/**
* Save collections into file
- *
- * @throws IOException If there is a fatal error flushing or
- * closing the {@link FileOutputStream} associated with the save
+ *
+ * @throws IOException If there is a fatal error flushing or
+ * closing the {@link FileOutputStream} associated with the save
* process.
- *
+ *
*/
public void save() throws IOException {
try {
diff --git a/src/plugin/subcollection/src/java/org/apache/nutch/collection/Subcollection.java b/src/plugin/subcollection/src/java/org/apache/nutch/collection/Subcollection.java
index 869fb1032..98e69cc9b 100644
--- a/src/plugin/subcollection/src/java/org/apache/nutch/collection/Subcollection.java
+++ b/src/plugin/subcollection/src/java/org/apache/nutch/collection/Subcollection.java
@@ -70,7 +70,7 @@ public class Subcollection extends Configured implements URLFilter {
* SubCollection blacklist as String
*/
String blString;
-
+
/**
* Whether the white and black lists are case sensitive
*/
@@ -78,7 +78,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* public Constructor
- *
+ *
* @param id
* Id of SubCollection
* @param name
@@ -91,7 +91,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* public Constructor
- *
+ *
* @param id
* Id of SubCollection
* @param name
@@ -135,7 +135,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Returns whitelist
- *
+ *
* @return Whitelist entries
*/
public List<String> getWhiteList() {
@@ -144,7 +144,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Returns whitelist String
- *
+ *
* @return Whitelist String
*/
public String getWhiteListString() {
@@ -153,7 +153,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Returns blacklist String
- *
+ *
* @return Blacklist String
*/
public String getBlackListString() {
@@ -170,14 +170,14 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Simple "indexOf" currentFilter for matching patterns.
- *
+ *
* <pre>
* rules for evaluation are as follows:
* 1. if pattern matches in blacklist then url is rejected
* 2. if pattern matches in whitelist then url is allowed
* 3. url is rejected
* </pre>
- *
+ *
* @see org.apache.nutch.net.URLFilter#filter(java.lang.String)
*/
@Override
@@ -202,8 +202,8 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Initialize Subcollection from dom element
- *
- * @param collection A DOM {@link org.w3c.dom.Element} for use
+ *
+ * @param collection A DOM {@link org.w3c.dom.Element} for use
* in creating the {@link Subcollection}
*/
public void initialize(Element collection) {
@@ -231,9 +231,9 @@ public class Subcollection extends Configured implements URLFilter {
}
/**
- * Create a list of patterns from a chunk of text, patterns are separated
+ * Create a list of patterns from a chunk of text, patterns are separated
* with a newline
- *
+ *
* @param list An initialized {@link List} to insert String patterns.
* @param text A chunk of text (hopefully) containing patterns.
*/
@@ -256,7 +256,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Set contents of blacklist from String
- *
+ *
* @param list
* the blacklist contents
*/
@@ -267,7 +267,7 @@ public class Subcollection extends Configured implements URLFilter {
/**
* Set contents of whitelist from String
- *
+ *
* @param list
* the whitelist contents
*/
diff --git a/src/plugin/subcollection/src/java/org/apache/nutch/collection/package-info.java b/src/plugin/subcollection/src/java/org/apache/nutch/collection/package-info.java
index 055cb457a..990c4224a 100644
--- a/src/plugin/subcollection/src/java/org/apache/nutch/collection/package-info.java
+++ b/src/plugin/subcollection/src/java/org/apache/nutch/collection/package-info.java
@@ -16,17 +16,17 @@
*/
/**
- * <p>Subcollection is a subset of an index. Subcollections are
- * defined by urlpatterns in form of white/blacklist. So to get the
- * page into subcollection it must match the whitelist and not
+ * <p>Subcollection is a subset of an index. Subcollections are
+ * defined by urlpatterns in form of white/blacklist. So to get the
+ * page into subcollection it must match the whitelist and not
* the blacklist.</p>
- * <p> Subcollection definitions are read from a file
- * <code>subcollections.xml</code> and the format is as follows
- * (imagine here that you are crawling all the virtualhosts from
- * apache.org and you want to tag pages with url pattern
- * "https://nutch.apache.org" and
- * "https://cwiki.apache.org/confluence/display/nutch" to be part of
- * subcollection "nutch", this allows you to later search specifically
+ * <p> Subcollection definitions are read from a file
+ * <code>subcollections.xml</code> and the format is as follows
+ * (imagine here that you are crawling all the virtualhosts from
+ * apache.org and you want to tag pages with url pattern
+ * "https://nutch.apache.org" and
+ * "https://cwiki.apache.org/confluence/display/nutch" to be part of
+ * subcollection "nutch", this allows you to later search specifically
* from this subcollection)</p>
* <pre>
* {@code
@@ -42,8 +42,8 @@
* </subcollections>
* }
* </pre>
- * <p>Despite of this configuration you still can crawl any urls
- * as long as they pass through your global url filters. (note that
+ * <p>Despite of this configuration you still can crawl any urls
+ * as long as they pass through your global url filters. (note that
* you must also seed your urls in normal nutch way)</p>
*/
package org.apache.nutch.collection;
diff --git a/src/plugin/tld/ivy.xml b/src/plugin/tld/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/tld/ivy.xml
+++ b/src/plugin/tld/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/tld/src/java/org/apache/nutch/indexer/tld/TLDIndexingFilter.java b/src/plugin/tld/src/java/org/apache/nutch/indexer/tld/TLDIndexingFilter.java
index 0637e9136..9be0bb74d 100644
--- a/src/plugin/tld/src/java/org/apache/nutch/indexer/tld/TLDIndexingFilter.java
+++ b/src/plugin/tld/src/java/org/apache/nutch/indexer/tld/TLDIndexingFilter.java
@@ -34,7 +34,7 @@ import org.apache.nutch.util.URLUtil;
/**
* Adds the public suffix (aka. effective top-level domain) to the index using
* the field name "tld".
- *
+ *
* <p>
* For the URL <code>https://www.example.co.uk/</code> the public suffix is
* <code>co.uk</code>. See also {@link URLUtil#getDomainSuffix(URL)}.
diff --git a/src/plugin/urlfilter-automaton/ivy.xml b/src/plugin/urlfilter-automaton/ivy.xml
index 9a175a025..4732cc4c9 100644
--- a/src/plugin/urlfilter-automaton/ivy.xml
+++ b/src/plugin/urlfilter-automaton/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -39,5 +39,5 @@
<dependencies>
<dependency org="dk.brics" name="automaton" rev="1.12-4" conf="*->default" />
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/AutomatonURLFilter.java b/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/AutomatonURLFilter.java
index cc7188ecd..0875ea4a3 100644
--- a/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/AutomatonURLFilter.java
+++ b/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/AutomatonURLFilter.java
@@ -35,7 +35,7 @@ import org.slf4j.LoggerFactory;
* RegexURLFilterBase implementation based on the <a
* href="https://www.brics.dk/automaton/">dk.brics.automaton</a> Finite-State
* Automata for Java<sup>TM</sup>.
- *
+ *
* @see <a href="https://www.brics.dk/automaton/">dk.brics.automaton</a>
*/
public class AutomatonURLFilter extends RegexURLFilterBase {
@@ -82,7 +82,7 @@ public class AutomatonURLFilter extends RegexURLFilterBase {
protected RegexRule createRule(boolean sign, String regex) {
return new Rule(sign, regex);
}
-
+
@Override
protected RegexRule createRule(boolean sign, String regex, String hostOrDomain) {
return new Rule(sign, regex, hostOrDomain);
@@ -105,7 +105,7 @@ public class AutomatonURLFilter extends RegexURLFilterBase {
super(sign, regex);
automaton = new RunAutomaton(new RegExp(regex, RegExp.ALL).toAutomaton());
}
-
+
Rule(boolean sign, String regex, String hostOrDomain) {
super(sign, regex, hostOrDomain);
automaton = new RunAutomaton(new RegExp(regex, RegExp.ALL).toAutomaton());
diff --git a/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/package-info.java b/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/package-info.java
index 41743a32a..6af705fe4 100644
--- a/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/package-info.java
+++ b/src/plugin/urlfilter-automaton/src/java/org/apache/nutch/urlfilter/automaton/package-info.java
@@ -15,9 +15,9 @@
* limitations under the License.
*/
-/**
- * URL filter plugin based on
- * <a href="https://www.brics.dk/automaton/">dk.brics.automaton</a> Finite-State
+/**
+ * URL filter plugin based on
+ * <a href="https://www.brics.dk/automaton/">dk.brics.automaton</a> Finite-State
* Automata for Java<sup>TM</sup>.
*/
package org.apache.nutch.urlfilter.automaton;
diff --git a/src/plugin/urlfilter-automaton/src/test/org/apache/nutch/urlfilter/automaton/TestAutomatonURLFilter.java b/src/plugin/urlfilter-automaton/src/test/org/apache/nutch/urlfilter/automaton/TestAutomatonURLFilter.java
index 92071aa42..266663eae 100644
--- a/src/plugin/urlfilter-automaton/src/test/org/apache/nutch/urlfilter/automaton/TestAutomatonURLFilter.java
+++ b/src/plugin/urlfilter-automaton/src/test/org/apache/nutch/urlfilter/automaton/TestAutomatonURLFilter.java
@@ -29,7 +29,7 @@ import static org.junit.jupiter.api.Assertions.fail;
/**
* JUnit based test of class <code>AutomatonURLFilter</code>.
- *
+ *
*/
public class TestAutomatonURLFilter extends RegexURLFilterBaseTest {
diff --git a/src/plugin/urlfilter-domain/ivy.xml b/src/plugin/urlfilter-domain/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-domain/ivy.xml
+++ b/src/plugin/urlfilter-domain/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-domain/src/test/org/apache/nutch/urlfilter/domain/TestDomainURLFilter.java b/src/plugin/urlfilter-domain/src/test/org/apache/nutch/urlfilter/domain/TestDomainURLFilter.java
index aa829bfba..a9e249e63 100644
--- a/src/plugin/urlfilter-domain/src/test/org/apache/nutch/urlfilter/domain/TestDomainURLFilter.java
+++ b/src/plugin/urlfilter-domain/src/test/org/apache/nutch/urlfilter/domain/TestDomainURLFilter.java
@@ -47,7 +47,7 @@ public class TestDomainURLFilter {
assertNotNull(domainFilter.filter("http://www.foobar.be"));
assertNull(domainFilter.filter("http://www.adobe.com"));
}
-
+
@Test
public void testNoFilter() throws Exception {
// https://issues.apache.org/jira/browse/NUTCH-2189
diff --git a/src/plugin/urlfilter-domaindenylist/ivy.xml b/src/plugin/urlfilter-domaindenylist/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/urlfilter-domaindenylist/ivy.xml
+++ b/src/plugin/urlfilter-domaindenylist/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-fast/README.md b/src/plugin/urlfilter-fast/README.md
index b4b0dfcd9..7b6955f07 100644
--- a/src/plugin/urlfilter-fast/README.md
+++ b/src/plugin/urlfilter-fast/README.md
@@ -75,7 +75,7 @@ The rules file is defined via the property `urlfilter.fast.file`,
the default name is `fast-urlfilter.txt`.
In addition to this, the filter checks that the length of the path element of the URL and its query
-done not exceed the values set in the properties `urlfilter.fast.url.path.max.length` and
-`urlfilter.fast.url.query.max.length` if set. The overall length of the URL can also be used for
+done not exceed the values set in the properties `urlfilter.fast.url.path.max.length` and
+`urlfilter.fast.url.query.max.length` if set. The overall length of the URL can also be used for
filtering through the config `urlfilter.fast.url.max.length`.
diff --git a/src/plugin/urlfilter-fast/ivy.xml b/src/plugin/urlfilter-fast/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-fast/ivy.xml
+++ b/src/plugin/urlfilter-fast/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-ignoreexempt/README.md b/src/plugin/urlfilter-ignoreexempt/README.md
index 374b29abd..a4b9b58b4 100644
--- a/src/plugin/urlfilter-ignoreexempt/README.md
+++ b/src/plugin/urlfilter-ignoreexempt/README.md
@@ -50,7 +50,7 @@ To exempt urls ending with image extensions, use this rule
## Testing the Rules :
After enabling the plugin and adding your rules to `conf/db-ignore-external-exemptions.txt`, run:
-
+
`bin/nutch plugin urlfilter-ignoreexempt org.apache.nutch.urlfilter.ignoreexempt.ExemptionUrlFilter http://yoururl.here`
This should print `true` for urls which are accepted by configured rules.
\ No newline at end of file
diff --git a/src/plugin/urlfilter-ignoreexempt/ivy.xml b/src/plugin/urlfilter-ignoreexempt/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-ignoreexempt/ivy.xml
+++ b/src/plugin/urlfilter-ignoreexempt/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-ignoreexempt/src/java/org/apache/nutch/urlfilter/ignoreexempt/ExemptionUrlFilter.java b/src/plugin/urlfilter-ignoreexempt/src/java/org/apache/nutch/urlfilter/ignoreexempt/ExemptionUrlFilter.java
index 8028e3672..6df7614a6 100644
--- a/src/plugin/urlfilter-ignoreexempt/src/java/org/apache/nutch/urlfilter/ignoreexempt/ExemptionUrlFilter.java
+++ b/src/plugin/urlfilter-ignoreexempt/src/java/org/apache/nutch/urlfilter/ignoreexempt/ExemptionUrlFilter.java
@@ -26,19 +26,19 @@ import java.util.regex.Pattern;
import java.util.List;
/**
- * This implementation of {@link org.apache.nutch.net.URLExemptionFilter}
- * uses regex configuration to check if URL is eligible for exemption from
+ * This implementation of {@link org.apache.nutch.net.URLExemptionFilter}
+ * uses regex configuration to check if URL is eligible for exemption from
* the <code>db.ignore.external.links</code> configuration property.
- * When this filter is enabled, the external urls will be checked
+ * When this filter is enabled, the external urls will be checked
* against configured sequence of regex rules.
*<p>
- * The exemption rule file defaults to
- * <code>db-ignore-external-exemptions.txt</code> in the classpath but
- * can be overridden using the configuration property
+ * The exemption rule file defaults to
+ * <code>db-ignore-external-exemptions.txt</code> in the classpath but
+ * can be overridden using the configuration property
* <code>db.ignore.external.exemptions.file</code>.
*</p>
*
- * The exemption rules are specified in plain text file where each line
+ * The exemption rules are specified in plain text file where each line
* is a rule.
* The format is same same as <code>regex-urlfilter.txt</code>.
* Each non-comment, non-blank line contains a regular expression
diff --git a/src/plugin/urlfilter-prefix/ivy.xml b/src/plugin/urlfilter-prefix/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-prefix/ivy.xml
+++ b/src/plugin/urlfilter-prefix/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-regex/ivy.xml b/src/plugin/urlfilter-regex/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-regex/ivy.xml
+++ b/src/plugin/urlfilter-regex/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/RegexURLFilter.java b/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/RegexURLFilter.java
index 5b283b76f..8a76b3260 100644
--- a/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/RegexURLFilter.java
+++ b/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/RegexURLFilter.java
@@ -77,13 +77,13 @@ public class RegexURLFilter extends RegexURLFilterBase {
protected RegexRule createRule(boolean sign, String regex) {
return new Rule(sign, regex);
}
-
+
@Override
protected RegexRule createRule(boolean sign, String regex, String hostOrDomain) {
return new Rule(sign, regex, hostOrDomain);
}
-
-
+
+
public static void main(String args[]) throws IOException {
RegexURLFilter filter = new RegexURLFilter();
@@ -98,7 +98,7 @@ public class RegexURLFilter extends RegexURLFilterBase {
Rule(boolean sign, String regex) {
this(sign, regex, null);
}
-
+
Rule(boolean sign, String regex, String hostOrDomain) {
super(sign, regex, hostOrDomain);
pattern = Pattern.compile(regex);
diff --git a/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/package-info.java b/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/package-info.java
index 8cb3afacb..dd48cf58d 100644
--- a/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/package-info.java
+++ b/src/plugin/urlfilter-regex/src/java/org/apache/nutch/urlfilter/regex/package-info.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-/**
+/**
* URL filter plugin to include and/or exclude URLs matching Java regular expressions.
*/
package org.apache.nutch.urlfilter.regex;
diff --git a/src/plugin/urlfilter-regex/src/test/org/apache/nutch/urlfilter/regex/TestRegexURLFilter.java b/src/plugin/urlfilter-regex/src/test/org/apache/nutch/urlfilter/regex/TestRegexURLFilter.java
index ec8b6b5a6..4323eca25 100644
--- a/src/plugin/urlfilter-regex/src/test/org/apache/nutch/urlfilter/regex/TestRegexURLFilter.java
+++ b/src/plugin/urlfilter-regex/src/test/org/apache/nutch/urlfilter/regex/TestRegexURLFilter.java
@@ -29,7 +29,7 @@ import static org.junit.jupiter.api.Assertions.fail;
/**
* JUnit based test of class <code>RegexURLFilter</code>.
- *
+ *
*/
public class TestRegexURLFilter extends RegexURLFilterBaseTest {
@@ -53,7 +53,7 @@ public class TestRegexURLFilter extends RegexURLFilterBaseTest {
bench(400, "Benchmarks");
bench(800, "Benchmarks");
}
-
+
@Test
public void test1838() {
test("nutch1838");
diff --git a/src/plugin/urlfilter-suffix/ivy.xml b/src/plugin/urlfilter-suffix/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-suffix/ivy.xml
+++ b/src/plugin/urlfilter-suffix/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-suffix/src/test/org/apache/nutch/urlfilter/suffix/TestSuffixURLFilter.java b/src/plugin/urlfilter-suffix/src/test/org/apache/nutch/urlfilter/suffix/TestSuffixURLFilter.java
index d900a691d..7303dd797 100644
--- a/src/plugin/urlfilter-suffix/src/test/org/apache/nutch/urlfilter/suffix/TestSuffixURLFilter.java
+++ b/src/plugin/urlfilter-suffix/src/test/org/apache/nutch/urlfilter/suffix/TestSuffixURLFilter.java
@@ -27,7 +27,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
/**
* JUnit test for <code>SuffixURLFilter</code>.
- *
+ *
*/
public class TestSuffixURLFilter {
private static final String suffixes = "# this is a comment\n" + "\n"
diff --git a/src/plugin/urlfilter-validator/ivy.xml b/src/plugin/urlfilter-validator/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlfilter-validator/ivy.xml
+++ b/src/plugin/urlfilter-validator/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlfilter-validator/src/java/org/apache/nutch/urlfilter/validator/UrlValidator.java b/src/plugin/urlfilter-validator/src/java/org/apache/nutch/urlfilter/validator/UrlValidator.java
index 14fed8a77..122180933 100644
--- a/src/plugin/urlfilter-validator/src/java/org/apache/nutch/urlfilter/validator/UrlValidator.java
+++ b/src/plugin/urlfilter-validator/src/java/org/apache/nutch/urlfilter/validator/UrlValidator.java
@@ -26,13 +26,13 @@ import org.apache.nutch.net.URLFilter;
* <p>
* Validates URLs.
* </p>
- *
+ *
* <p>
* Originally based in on php script by Debbie Dyer, validation.php v1.2b, Date:
* 03/07/02, http://javascript.internet.com. However, this validation now bears
* little resemblance to the php original.
* </p>
- *
+ *
* <pre>
* Example of usage:
* UrlValidator urlValidator = UrlValidator.get();
@@ -41,17 +41,17 @@ import org.apache.nutch.net.URLFilter;
* } else {
* System.out.println("url is invalid");
* }
- *
+ *
* prints out "url is valid"
* </pre>
- *
+ *
* <p>
* Based on UrlValidator code from Apache commons-validator.
* </p>
- *
+ *
* @see <a href='https://www.ietf.org/rfc/rfc2396.txt' > Uniform Resource
* Identifiers (URI): Generic Syntax </a>
- *
+ *
*/
public class UrlValidator implements URLFilter {
@@ -151,7 +151,7 @@ public class UrlValidator implements URLFilter {
* <p>
* Checks if a field has a valid url address.
* </p>
- *
+ *
* @param value
* The value validation is being performed on. A <code>null</code>
* value is considered invalid.
@@ -195,7 +195,7 @@ public class UrlValidator implements URLFilter {
* Validate scheme. If schemes[] was initialized to a non null, then only
* those scheme's are allowed. Note this is slightly different than for the
* constructor.
- *
+ *
* @param scheme
* The scheme to validate. A <code>null</code> value is considered
* invalid.
@@ -213,7 +213,7 @@ public class UrlValidator implements URLFilter {
* Returns true if the authority is properly formatted. An authority is the
* combination of hostname and port. A <code>null</code> authority value is
* considered invalid.
- *
+ *
* @param authority
* Authority value to validate.
* @return true if authority (hostname and port) is valid.
@@ -315,7 +315,7 @@ public class UrlValidator implements URLFilter {
* Checks if the field isn't null and length of the field is greater than zero
* not including whitespace.
* </p>
- *
+ *
* @param value
* The value validation is being performed on.
* @return true if blank or null.
@@ -327,7 +327,7 @@ public class UrlValidator implements URLFilter {
/**
* Returns true if the path is valid. A <code>null</code> value is considered
* invalid.
- *
+ *
* @param path
* Path value to validate.
* @return true if path is valid.
@@ -351,7 +351,7 @@ public class UrlValidator implements URLFilter {
/**
* Returns true if the query is null or it's a properly formatted query
* string.
- *
+ *
* @param query
* Query value to validate.
* @return true if query is valid.
@@ -366,7 +366,7 @@ public class UrlValidator implements URLFilter {
/**
* Returns the number of times the token appears in the target.
- *
+ *
* @param token
* Token value to be counted.
* @param target
diff --git a/src/plugin/urlfilter-validator/src/test/org/apache/nutch/urlfilter/validator/TestUrlValidator.java b/src/plugin/urlfilter-validator/src/test/org/apache/nutch/urlfilter/validator/TestUrlValidator.java
index b4cf129aa..f7d89f531 100644
--- a/src/plugin/urlfilter-validator/src/test/org/apache/nutch/urlfilter/validator/TestUrlValidator.java
+++ b/src/plugin/urlfilter-validator/src/test/org/apache/nutch/urlfilter/validator/TestUrlValidator.java
@@ -25,8 +25,8 @@ import static org.junit.jupiter.api.Assertions.assertNull;
* JUnit test case which tests 1. that valid urls are not filtered while invalid
* ones are filtered. 2. that Urls' scheme, authority, path and query are
* validated.
- *
- *
+ *
+ *
*/
public class TestUrlValidator {
diff --git a/src/plugin/urlmeta/ivy.xml b/src/plugin/urlmeta/ivy.xml
index 76f85f5ee..6910e7d02 100644
--- a/src/plugin/urlmeta/ivy.xml
+++ b/src/plugin/urlmeta/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/URLMetaIndexingFilter.java b/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/URLMetaIndexingFilter.java
index 557b8eb66..6259af70c 100644
--- a/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/URLMetaIndexingFilter.java
+++ b/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/URLMetaIndexingFilter.java
@@ -32,35 +32,35 @@ import org.apache.nutch.parse.Parse;
* Crawl URLs. 2. When you index your URLs, the meta tags that you specified
* with your URLs will be indexed alongside those URLs--and can be directly
* queried, assuming you have done everything else correctly.
- *
+ *
* The flat-file of URLs you are injecting should, per NUTCH-655, be
* tab-delimited in the form of:
- *
+ *
* [www.url.com]\t[key1]=[value1]\t[key2]=[value2]...[keyN]=[valueN]
- *
+ *
* Be aware that if you collide with keywords that are already in use (such as
* nutch.score/nutch.fetchInterval) then you are in for some unpredictable
* behavior.
- *
+ *
* Furthermore, in your nutch-site.xml config, you must specify that this plugin
* is to be used (1), as well as what (2) Meta Tags it should actively look for.
* This does not mean that you must use these tags for every URL, but it does
* mean that you must list _all_ of meta tags that you have specified. If you
* want them to be propagated and indexed, that is.
- *
+ *
* 1. As of Nutch 1.2, the property "plugin.includes" looks as follows:
* &lt;value&gt;protocol-http|urlfilter-regex|parse-(text|html|js|tika|rss)|index
* -(basic|anchor)|query-(basic|site|url)|response-(json|xml)|summary-basic
* |scoring-opic|urlnormalizer-(pass|regex|basic)&lt;/value&gt; You must change
* "index-(basic|anchor)" to "index-(basic|anchor|urlmeta)", in order to call
* this plugin.
- *
+ *
* 2. You must also specify the property "urlmeta.tags", who's values are
* comma-delimited &lt;value&gt;key1, key2, key3&lt;/value&gt;
- *
+ *
* TODO: It may be ideal to offer two separate properties, to specify what gets
* indexed versus merely propagated.
- *
+ *
*/
public class URLMetaIndexingFilter implements IndexingFilter {
@@ -72,7 +72,7 @@ public class URLMetaIndexingFilter implements IndexingFilter {
* This will take the metatags that you have listed in your "urlmeta.tags"
* property, and looks for them inside the CrawlDatum object. If they exist,
* this will add it as an attribute inside the NutchDocument.
- *
+ *
* @see IndexingFilter#filter
*/
@Override
diff --git a/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/package-info.java b/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/package-info.java
index 1a1239b41..3b6762225 100644
--- a/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/package-info.java
+++ b/src/plugin/urlmeta/src/java/org/apache/nutch/indexer/urlmeta/package-info.java
@@ -17,11 +17,11 @@
/**
* <p>URL Meta Tag Indexing Plugin</p>
- * <p>Takes Meta Tags, injected alongside a URL
- * (see <A href="https://issues.apache.org/jira/browse/NUTCH-655">NUTCH-655</a>)
- * and specified in the "urlmeta.tags" property, and inserts them into
- * the document--which is then sent to the Indexer. If you specify
- * these fields in the Nutch schema (as well as the Indexer's), you
+ * <p>Takes Meta Tags, injected alongside a URL
+ * (see <A href="https://issues.apache.org/jira/browse/NUTCH-655">NUTCH-655</a>)
+ * and specified in the "urlmeta.tags" property, and inserts them into
+ * the document--which is then sent to the Indexer. If you specify
+ * these fields in the Nutch schema (as well as the Indexer's), you
* can reasonably assume that they will be indexed.</p>
*/
package org.apache.nutch.indexer.urlmeta;
diff --git a/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/URLMetaScoringFilter.java b/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/URLMetaScoringFilter.java
index 0b70a0d5f..26f05b273 100644
--- a/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/URLMetaScoringFilter.java
+++ b/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/URLMetaScoringFilter.java
@@ -32,7 +32,7 @@ import org.apache.nutch.scoring.ScoringFilterException;
/**
* For documentation:
- *
+ *
* {@link org.apache.nutch.scoring.urlmeta}
*/
public class URLMetaScoringFilter extends AbstractScoringFilter {
@@ -45,7 +45,7 @@ public class URLMetaScoringFilter extends AbstractScoringFilter {
* property, and looks for them inside the parseData object. If they exist,
* this will be propagated into your 'targets' Collection's ["outlinks"]
* attributes.
- *
+ *
* @see ScoringFilter#distributeScoreToOutlinks
*/
@Override
@@ -77,7 +77,7 @@ public class URLMetaScoringFilter extends AbstractScoringFilter {
* Takes the metadata, specified in your "urlmeta.tags" property, from the
* datum object and injects it into the content. This is transferred to the
* parseData object.
- *
+ *
* @see ScoringFilter#passScoreBeforeParsing
* @see URLMetaScoringFilter#passScoreAfterParsing
*/
@@ -99,7 +99,7 @@ public class URLMetaScoringFilter extends AbstractScoringFilter {
/**
* Takes the metadata, which was lumped inside the content, and replicates it
* within your parse data.
- *
+ *
* @see URLMetaScoringFilter#passScoreBeforeParsing
* @see ScoringFilter#passScoreAfterParsing
*/
diff --git a/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/package-info.java b/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/package-info.java
index df182c43d..bdd39163a 100644
--- a/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/package-info.java
+++ b/src/plugin/urlmeta/src/java/org/apache/nutch/scoring/urlmeta/package-info.java
@@ -17,9 +17,9 @@
/**
* <p>URL Meta Tag Scoring Plugin</p>
- * <p>Propagates Meta Tags, injected alongside a URL
- * (see <a href="https://issues.apache.org/jira/browse/NUTCH-655">NUTCH-655</a>)
- * and specified in the "urlmeta.tags" property, along to their outlinks.
+ * <p>Propagates Meta Tags, injected alongside a URL
+ * (see <a href="https://issues.apache.org/jira/browse/NUTCH-655">NUTCH-655</a>)
+ * and specified in the "urlmeta.tags" property, along to their outlinks.
* This does not actually perform scoring.</p>
*/
package org.apache.nutch.scoring.urlmeta;
diff --git a/src/plugin/urlnormalizer-ajax/ivy.xml b/src/plugin/urlnormalizer-ajax/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlnormalizer-ajax/ivy.xml
+++ b/src/plugin/urlnormalizer-ajax/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-ajax/src/test/org/apache/nutch/net/urlnormalizer/ajax/TestAjaxURLNormalizer.java b/src/plugin/urlnormalizer-ajax/src/test/org/apache/nutch/net/urlnormalizer/ajax/TestAjaxURLNormalizer.java
index 310761e37..4b361b546 100644
--- a/src/plugin/urlnormalizer-ajax/src/test/org/apache/nutch/net/urlnormalizer/ajax/TestAjaxURLNormalizer.java
+++ b/src/plugin/urlnormalizer-ajax/src/test/org/apache/nutch/net/urlnormalizer/ajax/TestAjaxURLNormalizer.java
@@ -27,7 +27,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
public class TestAjaxURLNormalizer {
private AjaxURLNormalizer normalizer;
private Configuration conf;
-
+
public TestAjaxURLNormalizer() {
normalizer = new AjaxURLNormalizer();
conf = NutchConfiguration.create();
@@ -58,7 +58,7 @@ public class TestAjaxURLNormalizer {
assertEquals(normal,
normalizer.normalize(weird, URLNormalizers.SCOPE_DEFAULT));
}
-
+
private void normalizeTest(String weird, String normal, String scope) throws Exception {
assertEquals(normal, normalizer.normalize(weird, scope));
}
diff --git a/src/plugin/urlnormalizer-basic/ivy.xml b/src/plugin/urlnormalizer-basic/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlnormalizer-basic/ivy.xml
+++ b/src/plugin/urlnormalizer-basic/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/BasicURLNormalizer.java b/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/BasicURLNormalizer.java
index 4ff9fc64a..c9d9c269a 100644
--- a/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/BasicURLNormalizer.java
+++ b/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/BasicURLNormalizer.java
@@ -74,7 +74,7 @@ public class BasicURLNormalizer implements URLNormalizer {
*/
private final static Pattern unescapeRulePattern = Pattern
.compile("%([0-9A-Fa-f]{2})");
-
+
// charset used for encoding URLs before escaping
private final static Charset UTF_8 = StandardCharsets.UTF_8;
@@ -168,7 +168,7 @@ public class BasicURLNormalizer implements URLNormalizer {
@Override
public String normalize(String urlString, String scope)
throws MalformedURLException {
-
+
if ("".equals(urlString)) // permit empty
return urlString;
@@ -311,7 +311,7 @@ public class BasicURLNormalizer implements URLNormalizer {
return file;
}
-
+
/**
* Remove % encoding from path segment in URL for characters which should be
* unescaped according to <a
@@ -319,9 +319,9 @@ public class BasicURLNormalizer implements URLNormalizer {
*/
private String unescapePath(String path) {
StringBuilder sb = new StringBuilder();
-
+
Matcher matcher = unescapeRulePattern.matcher(path);
-
+
int end = -1;
int letter;
@@ -329,7 +329,7 @@ public class BasicURLNormalizer implements URLNormalizer {
while (matcher.find()) {
// Append everything up to this group
sb.append(path.substring(end + 1, matcher.start()));
-
+
// Get the integer representation of this hexadecimal encoded character
letter = Integer.valueOf(matcher.group().substring(1), 16);
@@ -340,12 +340,12 @@ public class BasicURLNormalizer implements URLNormalizer {
// Append the encoded character as uppercase
sb.append(matcher.group().toUpperCase(Locale.ROOT));
}
-
+
end = matcher.start() + 2;
}
-
+
letter = path.length();
-
+
// Append the rest if there's anything
if (end <= letter - 1) {
sb.append(path.substring(end + 1, letter));
@@ -369,12 +369,12 @@ public class BasicURLNormalizer implements URLNormalizer {
byte b = bytes[i];
// Is this a control character?
if (b < 0 || escapedCharacters[b]) {
- // Start escape sequence
+ // Start escape sequence
sb.append('%');
-
- // Get this byte's hexadecimal representation
+
+ // Get this byte's hexadecimal representation
String hex = Integer.toHexString(b & 0xFF).toUpperCase(Locale.ROOT);
-
+
// Do we need to prepend a zero?
if (hex.length() % 2 != 0 ) {
sb.append('0');
@@ -406,7 +406,7 @@ public class BasicURLNormalizer implements URLNormalizer {
sb.append((char) b);
}
}
-
+
return sb.toString();
}
diff --git a/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/package-info.java b/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/package-info.java
index 63cee1404..08799dd56 100644
--- a/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/package-info.java
+++ b/src/plugin/urlnormalizer-basic/src/java/org/apache/nutch/net/urlnormalizer/basic/package-info.java
@@ -23,11 +23,11 @@
* <li>remove anchors</li>
* <li>use percent-encoding (only) where needed</li>
* </ul>
- *
+ *
* E.g.,
* <code>https://www.example.org/a/../b//./select%2Dlang.php?lang=español#anchor</code>
* is normalized to <code>https://www.example.org/b/select-lang.php?lang=espa%C3%B1ol</code>
- *
+ *
* Optional and configurable normalizations are:
* <ul>
* <li>convert Internationalized Domain Names (IDNs) uniquely either to the
diff --git a/src/plugin/urlnormalizer-basic/src/test/org/apache/nutch/net/urlnormalizer/basic/TestBasicURLNormalizer.java b/src/plugin/urlnormalizer-basic/src/test/org/apache/nutch/net/urlnormalizer/basic/TestBasicURLNormalizer.java
index 090c25f2d..4b152e276 100644
--- a/src/plugin/urlnormalizer-basic/src/test/org/apache/nutch/net/urlnormalizer/basic/TestBasicURLNormalizer.java
+++ b/src/plugin/urlnormalizer-basic/src/test/org/apache/nutch/net/urlnormalizer/basic/TestBasicURLNormalizer.java
@@ -39,7 +39,7 @@ public class TestBasicURLNormalizer {
conf = NutchConfiguration.create();
normalizer.setConf(conf);
}
-
+
@Test
public void testNUTCH1098() throws Exception {
// check that % encoding is normalized
@@ -51,7 +51,7 @@ public class TestBasicURLNormalizer {
// check that % decoder do not overlap strings
normalizeTest("http://foo.com/%66oo.ht%6d%6c", "http://foo.com/foo.html");
-
+
// check that % decoder leaves high bit chars alone
normalizeTest("http://foo.com/%66oo.htm%C0", "http://foo.com/foo.htm%C0");
@@ -82,7 +82,7 @@ public class TestBasicURLNormalizer {
// check encoding of Spanish chars
normalizeTest("http://mydomain.com/en Espa\u00F1ol.aspx", "http://mydomain.com/en%20Espa%C3%B1ol.aspx");
}
-
+
@Test
public void testNUTCH2064() throws Exception {
// Ampersand and colon and other punctuation characters are not to be unescaped
@@ -244,7 +244,7 @@ public class TestBasicURLNormalizer {
normalizeTest("https://user@[2600:1f18:200d:fb00:2b74:867c:ab0c:150a]/path/../to/index.html",
"https://[2600:1f18:200d:fb00:2b74:867c:ab0c:150a]/to/index.html");
}
-
+
@Test
public void testCurlyBraces() throws Exception {
// check whether curly braces are properly escaped
diff --git a/src/plugin/urlnormalizer-host/ivy.xml b/src/plugin/urlnormalizer-host/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/urlnormalizer-host/ivy.xml
+++ b/src/plugin/urlnormalizer-host/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-pass/ivy.xml b/src/plugin/urlnormalizer-pass/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlnormalizer-pass/ivy.xml
+++ b/src/plugin/urlnormalizer-pass/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-pass/src/java/org/apache/nutch/net/urlnormalizer/pass/PassURLNormalizer.java b/src/plugin/urlnormalizer-pass/src/java/org/apache/nutch/net/urlnormalizer/pass/PassURLNormalizer.java
index fd5385bb5..6a5cdb5be 100644
--- a/src/plugin/urlnormalizer-pass/src/java/org/apache/nutch/net/urlnormalizer/pass/PassURLNormalizer.java
+++ b/src/plugin/urlnormalizer-pass/src/java/org/apache/nutch/net/urlnormalizer/pass/PassURLNormalizer.java
@@ -25,7 +25,7 @@ import org.apache.nutch.net.URLNormalizer;
* This URLNormalizer doesn't change urls. It is sometimes useful if for a given
* scope at least one normalizer must be defined but no transformations are
* required.
- *
+ *
*/
public class PassURLNormalizer implements URLNormalizer {
diff --git a/src/plugin/urlnormalizer-protocol/ivy.xml b/src/plugin/urlnormalizer-protocol/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/urlnormalizer-protocol/ivy.xml
+++ b/src/plugin/urlnormalizer-protocol/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-protocol/src/java/org/apache/nutch/net/urlnormalizer/protocol/package-info.java b/src/plugin/urlnormalizer-protocol/src/java/org/apache/nutch/net/urlnormalizer/protocol/package-info.java
index 57120f90a..5954bb65e 100644
--- a/src/plugin/urlnormalizer-protocol/src/java/org/apache/nutch/net/urlnormalizer/protocol/package-info.java
+++ b/src/plugin/urlnormalizer-protocol/src/java/org/apache/nutch/net/urlnormalizer/protocol/package-info.java
@@ -18,25 +18,25 @@
/**
* URL normalizer to normalize the protocol for all URLs of a given host or
* domain.
- *
+ *
* E.g., normalize <code>http://nutch.apache.org/path/</code> to
* <code>https://www.apache.org/path/</code> if it's known that the host
* <code>nutch.apache.org</code> supports https and http-URLs either cause
* duplicate content or are redirected to https.
*
* The configuration of rules follows the schema:
- *
+ *
* <pre>
* &lt;host&gt; \t &lt;protocol&gt;
* </pre>
- *
+ *
* for example
- *
+ *
* <pre>
* nutch.apache.org \t https
* *.example.com \t http
* </pre>
- *
+ *
* These rules will normalize all URLs of the host <code>nutch.apache.org</code>
* to use https while every URL from <code>example.com</code> and its subdomains
* is normalized to be based on http.
@@ -44,7 +44,7 @@
* A "host" pattern which starts with <code>*.</code> will match all hosts
* (subdomains) of the given domain, or more generally matches domain suffixes
* separated by a dot.
- *
+ *
* Rules are usually configured via the configuration file "protocols.txt". The
* filename is specified by the property
* <code>urlnormalizer.protocols.file</code>. Alternatively, if the property
diff --git a/src/plugin/urlnormalizer-protocol/src/test/org/apache/nutch/net/urlnormalizer/protocol/TestProtocolURLNormalizer.java b/src/plugin/urlnormalizer-protocol/src/test/org/apache/nutch/net/urlnormalizer/protocol/TestProtocolURLNormalizer.java
index 91e1fb70b..990a1db9e 100644
--- a/src/plugin/urlnormalizer-protocol/src/test/org/apache/nutch/net/urlnormalizer/protocol/TestProtocolURLNormalizer.java
+++ b/src/plugin/urlnormalizer-protocol/src/test/org/apache/nutch/net/urlnormalizer/protocol/TestProtocolURLNormalizer.java
@@ -55,7 +55,7 @@ class TestProtocolURLNormalizer {
.normalize("https://example.io/", URLNormalizers.SCOPE_DEFAULT));
assertEquals("https://example.nl/", normalizer
.normalize("https://example.nl/", URLNormalizers.SCOPE_DEFAULT));
-
+
// http to https
assertEquals("https://example.io/", normalizer
.normalize("http://example.io/", URLNormalizers.SCOPE_DEFAULT));
diff --git a/src/plugin/urlnormalizer-querystring/ivy.xml b/src/plugin/urlnormalizer-querystring/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/urlnormalizer-querystring/ivy.xml
+++ b/src/plugin/urlnormalizer-querystring/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-querystring/src/java/org/apache/nutch/net/urlnormalizer/querystring/QuerystringURLNormalizer.java b/src/plugin/urlnormalizer-querystring/src/java/org/apache/nutch/net/urlnormalizer/querystring/QuerystringURLNormalizer.java
index 115376bfc..fb5e010de 100644
--- a/src/plugin/urlnormalizer-querystring/src/java/org/apache/nutch/net/urlnormalizer/querystring/QuerystringURLNormalizer.java
+++ b/src/plugin/urlnormalizer-querystring/src/java/org/apache/nutch/net/urlnormalizer/querystring/QuerystringURLNormalizer.java
@@ -30,7 +30,7 @@ import org.apache.nutch.net.URLNormalizer;
* URL normalizer plugin for normalizing query strings but sorting query string
* parameters. Not sorting query strings can lead to large amounts of duplicate
* URL's such as ?a=x&amp;b=y vs b=y&amp;a=x.
- *
+ *
*/
public class QuerystringURLNormalizer implements URLNormalizer {
diff --git a/src/plugin/urlnormalizer-regex/ivy.xml b/src/plugin/urlnormalizer-regex/ivy.xml
index cd9a434a0..42b7a76e6 100644
--- a/src/plugin/urlnormalizer-regex/ivy.xml
+++ b/src/plugin/urlnormalizer-regex/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-regex/sample/regex-normalize-default.xml b/src/plugin/urlnormalizer-regex/sample/regex-normalize-default.xml
index 3d1f7186c..c953f5cb3 100644
--- a/src/plugin/urlnormalizer-regex/sample/regex-normalize-default.xml
+++ b/src/plugin/urlnormalizer-regex/sample/regex-normalize-default.xml
@@ -24,7 +24,7 @@
<!-- WATCH OUT: an xml parser reads this file an ampersands must be
expanded to &amp; -->
-<!-- The following rules show how to strip out session IDs, default pages,
+<!-- The following rules show how to strip out session IDs, default pages,
interpage anchors, etc. Order does matter! -->
<regex-normalize>
@@ -39,7 +39,7 @@
<regex>
<pattern>/((?i)index|default)\.((?i)js[pf]{1}?[afx]?|cgi|cfm|asp[x]?|[psx]?htm[l]?|php[3456]?)(\?|&amp;|#|$)</pattern>
<substitution>/$3</substitution>
-</regex>
+</regex>
<!-- removes interpage href anchors such as site.com#location -->
<regex>
diff --git a/src/plugin/urlnormalizer-slash/ivy.xml b/src/plugin/urlnormalizer-slash/ivy.xml
index 1fc37bf88..9ca4e2815 100644
--- a/src/plugin/urlnormalizer-slash/ivy.xml
+++ b/src/plugin/urlnormalizer-slash/ivy.xml
@@ -16,8 +16,8 @@
limitations under the License.
-->
-<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
+<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:ns0="http://ant.apache.org/ivy/maven" version="2.0">
<info organisation="org.apache.nutch" module="${ant.project.name}">
<license name="Apache 2.0"/>
@@ -38,5 +38,5 @@
<dependencies>
</dependencies>
-
+
</ivy-module>
diff --git a/src/plugin/urlnormalizer-slash/src/test/org/apache/nutch/net/urlnormalizer/slash/TestSlashURLNormalizer.java b/src/plugin/urlnormalizer-slash/src/test/org/apache/nutch/net/urlnormalizer/slash/TestSlashURLNormalizer.java
index 6e2e5d115..61157062a 100644
--- a/src/plugin/urlnormalizer-slash/src/test/org/apache/nutch/net/urlnormalizer/slash/TestSlashURLNormalizer.java
+++ b/src/plugin/urlnormalizer-slash/src/test/org/apache/nutch/net/urlnormalizer/slash/TestSlashURLNormalizer.java
@@ -42,7 +42,7 @@ class TestSlashURLNormalizer {
normalizer.normalize("http://example.org/", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://example.net/",
normalizer.normalize("http://example.net/", URLNormalizers.SCOPE_DEFAULT));
-
+
// Don't touch base URL's
assertEquals("http://example.org",
normalizer.normalize("http://example.org", URLNormalizers.SCOPE_DEFAULT));
@@ -52,29 +52,29 @@ class TestSlashURLNormalizer {
normalizer.normalize("http://example.org/", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://example.net/",
normalizer.normalize("http://example.net/", URLNormalizers.SCOPE_DEFAULT));
-
+
// Change
assertEquals("http://www.example.org/page/",
normalizer.normalize("http://www.example.org/page", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://www.example.net/path/to/something", normalizer.normalize("http://www.example.net/path/to/something/", URLNormalizers.SCOPE_DEFAULT));
-
+
// No change
assertEquals("http://example.org/buh/",
normalizer.normalize("http://example.org/buh/", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://example.net/blaat",
normalizer.normalize("http://example.net/blaat", URLNormalizers.SCOPE_DEFAULT));
-
+
// No change
assertEquals("http://example.nl/buh/",
normalizer.normalize("http://example.nl/buh/", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://example.de/blaat",
normalizer.normalize("http://example.de/blaat", URLNormalizers.SCOPE_DEFAULT));
-
+
// Change
assertEquals("http://www.example.org/page/?a=b&c=d", normalizer.normalize("http://www.example.org/page?a=b&c=d", URLNormalizers.SCOPE_DEFAULT));
assertEquals("http://www.example.net/path/to/something?a=b&c=d",
normalizer.normalize("http://www.example.net/path/to/something/?a=b&c=d", URLNormalizers.SCOPE_DEFAULT));
-
+
// No change
assertEquals("http://www.example.org/noise.mp3",
normalizer.normalize("http://www.example.org/noise.mp3", URLNormalizers.SCOPE_DEFAULT));
diff --git a/src/test/crawl-tests.xml b/src/test/crawl-tests.xml
index b1e38ad3a..c8d74bca5 100644
--- a/src/test/crawl-tests.xml
+++ b/src/test/crawl-tests.xml
@@ -35,7 +35,7 @@
<property>
<name>fetcher.server.delay</name>
<value>0.2</value>
- <description>The number of seconds the fetcher will delay between
+ <description>The number of seconds the fetcher will delay between
successive requests to the same server.</description>
</property>
@@ -54,14 +54,14 @@
<value>true</value>
</property>
-<property>
- <name>http.robots.agents</name>
- <value>test-nutch,*</value>
- <description>The agent strings we'll look for in robots.txt files,
- comma-separated, in decreasing order of precedence. You should
- put the value of http.agent.name as the first agent name, and keep the
- default * at the end of the list. E.g.: BlurflDev,Blurfl,*
- </description>
+<property>
+ <name>http.robots.agents</name>
+ <value>test-nutch,*</value>
+ <description>The agent strings we'll look for in robots.txt files,
+ comma-separated, in decreasing order of precedence. You should
+ put the value of http.agent.name as the first agent name, and keep the
+ default * at the end of the list. E.g.: BlurflDev,Blurfl,*
+ </description>
</property>
<property>
diff --git a/src/test/org/apache/nutch/crawl/ContinuousCrawlTestUtil.java b/src/test/org/apache/nutch/crawl/ContinuousCrawlTestUtil.java
index f0971c2e1..4b473ee87 100644
--- a/src/test/org/apache/nutch/crawl/ContinuousCrawlTestUtil.java
+++ b/src/test/org/apache/nutch/crawl/ContinuousCrawlTestUtil.java
@@ -35,7 +35,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
* Emulate a continuous crawl for one URL.
- *
+ *
*/
public class ContinuousCrawlTestUtil {
@@ -106,7 +106,7 @@ public class ContinuousCrawlTestUtil {
/**
* default fetch action: set status and time
- *
+ *
* @param datum
* CrawlDatum to fetch
* @param currentTime
@@ -140,7 +140,7 @@ public class ContinuousCrawlTestUtil {
/**
* default parse action: add signature if successfully fetched
- *
+ *
* @param fetchDatum
* fetch datum
* @return list of all datums resulting from parse (status: signature, linked,
@@ -158,7 +158,7 @@ public class ContinuousCrawlTestUtil {
/**
* default implementation to check the result state
- *
+ *
* @param datum
* the CrawlDatum to be checked
* @return true if the check succeeds
@@ -174,7 +174,7 @@ public class ContinuousCrawlTestUtil {
* <p>
* A loop emulates a continuous crawl launched in regular intervals (see
* {@link #setInterval(int)} over a longer period ({@link #setDuraction(int)}.
- *
+ *
* <ul>
* <li>every "round" emulates
* <ul>
@@ -185,13 +185,13 @@ public class ContinuousCrawlTestUtil {
* <li>and is checked whether it is correct (see {@link #check(CrawlDatum)})
* </ul>
* </p>
- *
+ *
* @param maxErrors
* (if > 0) continue crawl even if the checked CrawlDatum is not
* correct, but stop after max. number of errors
- *
+ *
* @return false if a check of CrawlDatum failed, true otherwise
- * @throws IOException
+ * @throws IOException
*/
protected boolean run(int maxErrors) throws IOException {
diff --git a/src/test/org/apache/nutch/crawl/CrawlDbUpdateUtil.java b/src/test/org/apache/nutch/crawl/CrawlDbUpdateUtil.java
index 0555e8367..60a71b800 100644
--- a/src/test/org/apache/nutch/crawl/CrawlDbUpdateUtil.java
+++ b/src/test/org/apache/nutch/crawl/CrawlDbUpdateUtil.java
@@ -67,7 +67,7 @@ public class CrawlDbUpdateUtil <T extends Reducer<Text, CrawlDatum, Text, CrawlD
/** {@link Context} to collect all values in a {@link List} */
private class DummyContext extends Reducer<Text, CrawlDatum, Text, CrawlDatum>.Context {
-
+
private DummyContext() {
reducer.super();
}
@@ -127,7 +127,7 @@ public class CrawlDbUpdateUtil <T extends Reducer<Text, CrawlDatum, Text, CrawlD
public float getProgress() {
return 1f;
}
-
+
@Override
public OutputCommitter getOutputCommitter() {
throw new UnsupportedOperationException("Dummy context without committer");
@@ -144,7 +144,7 @@ public class CrawlDbUpdateUtil <T extends Reducer<Text, CrawlDatum, Text, CrawlD
}
@Override
- public TaskAttemptID getTaskAttemptID() throws UnsupportedOperationException {
+ public TaskAttemptID getTaskAttemptID() throws UnsupportedOperationException {
throw new UnsupportedOperationException("Dummy context without TaskAttemptID");
}
@@ -345,7 +345,7 @@ public class CrawlDbUpdateUtil <T extends Reducer<Text, CrawlDatum, Text, CrawlD
* run
* {@link CrawlDbReducer#reduce(Text, Iterator, OutputCollector, Reporter)}
* and return the CrawlDatum(s) which would have been written into CrawlDb
- *
+ *
* @param values
* list of input CrawlDatums
* @return list of resulting CrawlDatum(s) in CrawlDb
@@ -371,7 +371,7 @@ public class CrawlDbUpdateUtil <T extends Reducer<Text, CrawlDatum, Text, CrawlD
* run
* {@link CrawlDbReducer#reduce(Text, Iterator, OutputCollector, Reporter)}
* and return the CrawlDatum(s) which would have been written into CrawlDb
- *
+ *
* @param dbDatum
* previous CrawlDatum in CrawlDb
* @param fetchDatum
diff --git a/src/test/org/apache/nutch/crawl/TestAdaptiveFetchSchedule.java b/src/test/org/apache/nutch/crawl/TestAdaptiveFetchSchedule.java
index c06ae3007..2f4382cb6 100644
--- a/src/test/org/apache/nutch/crawl/TestAdaptiveFetchSchedule.java
+++ b/src/test/org/apache/nutch/crawl/TestAdaptiveFetchSchedule.java
@@ -33,7 +33,7 @@ import java.util.Properties;
/**
* Test cases for AdaptiveFetchSchedule.
- *
+ *
*/
public class TestAdaptiveFetchSchedule {
@@ -54,7 +54,7 @@ public class TestAdaptiveFetchSchedule {
/**
* Test the core functionality of AdaptiveFetchSchedule.
- *
+ *
*/
@Test
@@ -86,7 +86,7 @@ public class TestAdaptiveFetchSchedule {
/**
* Prepare a CrawlDatum (STATUS_DB_UNFETCHED) to Test AdaptiveFetchSchedule.
- *
+ *
* @return properly initialized CrawlDatum
*/
public CrawlDatum prepareCrawlDatum() {
@@ -99,9 +99,9 @@ public class TestAdaptiveFetchSchedule {
}
/**
- *
+ *
* The Method validates interval values according to changed parameter.
- *
+ *
* @param changed
* status value to check calculated interval value.
* @param getInterval
@@ -123,7 +123,7 @@ public class TestAdaptiveFetchSchedule {
}
}
-
+
/**
* Test https://issues.apache.org/jira/browse/NUTCH-1564
*/
@@ -163,7 +163,7 @@ public class TestAdaptiveFetchSchedule {
doTestSetFetchSchedule(0.3, 2, 1, 10, 10, 3, 180);
}
- private void doTestSetFetchSchedule(double deltaRate, int intervalDefaultDays,
+ private void doTestSetFetchSchedule(double deltaRate, int intervalDefaultDays,
int minIntervalDays, int maxIntervalDays, int intervalMaxDays,
int previousFetchTimeDays, int modifiedTimeDays) {
// need to properly override defaults
@@ -175,17 +175,17 @@ public class TestAdaptiveFetchSchedule {
props.setProperty("db.fetch.schedule.adaptive.min_interval", String.valueOf(FetchSchedule.SECONDS_PER_DAY * minIntervalDays));
props.setProperty("db.fetch.schedule.adaptive.max_interval", String.valueOf(FetchSchedule.SECONDS_PER_DAY * maxIntervalDays));
props.setProperty("db.fetch.interval.max", String.valueOf(FetchSchedule.SECONDS_PER_DAY * intervalMaxDays));
-
+
conf = NutchConfiguration.create(true, props);
inc_rate = conf.getFloat("db.fetch.schedule.adaptive.inc_rate", 0.2f); // default
dec_rate = conf.getFloat("db.fetch.schedule.adaptive.dec_rate", 0.2f); // default
// ignore adaptive-host-specific-intervals.txt
Text url = new Text("http://www.example2.com");
-
+
AdaptiveFetchSchedule fs = new AdaptiveFetchSchedule();
fs.setConf(conf);
-
+
CrawlDatum datum = prepareCrawlDatum();
Date fetchTime = Date.from(Instant.now());
Date previousFetchTime = Date.from(Instant.now().minus(Duration.ofDays(previousFetchTimeDays)));
@@ -193,16 +193,16 @@ public class TestAdaptiveFetchSchedule {
datum.setStatus(CrawlDatum.STATUS_FETCH_SUCCESS);
datum.setRetriesSinceFetch(0);
datum.setModifiedTime(modifiedTime.getTime());
- datum.setFetchTime(fetchTime.getTime());
-
+ datum.setFetchTime(fetchTime.getTime());
+
System.out.println("CrawlDatum fetchTime: " + fetchTime + "; modifiedTime: " + modifiedTime);
-
- fs.setFetchSchedule(url, datum, previousFetchTime.getTime(), modifiedTime.getTime(),
+
+ fs.setFetchSchedule(url, datum, previousFetchTime.getTime(), modifiedTime.getTime(),
fetchTime.getTime(), modifiedTime.getTime(), CrawlDatum.STATUS_DB_NOTMODIFIED);
-
+
Date nextFetchTime = new Date(datum.getFetchTime());
System.out.println("CrawlDatum next fetchTime: " + nextFetchTime);
-
+
assertTrue(nextFetchTime.after(fetchTime));
// adapt milliseconds to seconds
long fetchTimeDiff = (nextFetchTime.getTime() - fetchTime.getTime()) / 1000L ;
diff --git a/src/test/org/apache/nutch/crawl/TestCrawlDbFilter.java b/src/test/org/apache/nutch/crawl/TestCrawlDbFilter.java
index 84008a820..735c74392 100644
--- a/src/test/org/apache/nutch/crawl/TestCrawlDbFilter.java
+++ b/src/test/org/apache/nutch/crawl/TestCrawlDbFilter.java
@@ -41,7 +41,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
* CrawlDbFiltering test which tests for correct, error free url normalization
* when the CrawlDB includes urls with <code>DB GONE</code> status and
* <code>CRAWLDB_PURGE_404</code> is set to true.
- *
+ *
*/
public class TestCrawlDbFilter {
Configuration conf;
@@ -71,7 +71,7 @@ public class TestCrawlDbFilter {
/**
* Test url404Purging
- *
+ *
* @throws Exception
*/
@Test
@@ -119,7 +119,7 @@ public class TestCrawlDbFilter {
/**
* Read contents of fetchlist.
- *
+ *
* @param fetchlist
* path to Generated fetchlist
* @return Generated {@link URLCrawlDatum} objects
diff --git a/src/test/org/apache/nutch/crawl/TestCrawlDbMerger.java b/src/test/org/apache/nutch/crawl/TestCrawlDbMerger.java
index 48892e49e..d6efb93af 100644
--- a/src/test/org/apache/nutch/crawl/TestCrawlDbMerger.java
+++ b/src/test/org/apache/nutch/crawl/TestCrawlDbMerger.java
@@ -102,13 +102,13 @@ public class TestCrawlDbMerger {
/**
* Test creates two sample {@link org.apache.nutch.crawl.CrawlDb}'s
- * populating entries for keys as {@link org.apache.hadoop.io.Text} e.g. URLs
- * and values as {@link org.apache.nutch.crawl.CrawlDatum} e.g. record data.
+ * populating entries for keys as {@link org.apache.hadoop.io.Text} e.g. URLs
+ * and values as {@link org.apache.nutch.crawl.CrawlDatum} e.g. record data.
* It then simulates a merge process for the two CrawlDb's via the {@link org.apache.nutch.crawl.CrawlDbMerger}
* tool. The merged CrawlDb is then written to an arbitrary output location and the results
- * read using the {@link org.apache.nutch.crawl.CrawlDbReader} tool.
+ * read using the {@link org.apache.nutch.crawl.CrawlDbReader} tool.
* Test assertions include comparing expected CrawlDb key, value (URL, CrawlDatum) values
- * with actual results based on the merge process.
+ * with actual results based on the merge process.
* @throws Exception
*/
@Test
@@ -146,10 +146,10 @@ public class TestCrawlDbMerger {
TreeSet<String> init, CrawlDatum cd) throws Exception {
LOG.debug("* creating crawldb: {}", crawldb);
Path dir = new Path(crawldb, CrawlDb.CURRENT_NAME);
-
+
Option wKeyOpt = MapFile.Writer.keyClass(Text.class);
org.apache.hadoop.io.SequenceFile.Writer.Option wValueOpt = SequenceFile.Writer.valueClass(CrawlDatum.class);
-
+
MapFile.Writer writer = new MapFile.Writer(config, new Path(dir,
"part-r-00000"), wKeyOpt, wValueOpt);
Iterator<String> it = init.iterator();
diff --git a/src/test/org/apache/nutch/crawl/TestGenerator.java b/src/test/org/apache/nutch/crawl/TestGenerator.java
index cf4fa4955..7502bcf96 100644
--- a/src/test/org/apache/nutch/crawl/TestGenerator.java
+++ b/src/test/org/apache/nutch/crawl/TestGenerator.java
@@ -39,7 +39,7 @@ import static org.junit.jupiter.api.Assertions.assertNull;
* Basic generator test. 1. Insert entries in crawldb 2. Generates entries to
* fetch 3. Verifies that number of generated urls match 4. Verifies that
* highest scoring urls are generated
- *
+ *
*/
public class TestGenerator {
@@ -74,7 +74,7 @@ public class TestGenerator {
/**
* Test that generator generates fetchlish ordered by score (desc).
- *
+ *
* @throws Exception
*/
@Test
@@ -135,7 +135,7 @@ public class TestGenerator {
/**
* Test that generator obeys the property "generate.max.count".
- *
+ *
* @throws Exception
*/
@Test
@@ -200,7 +200,7 @@ public class TestGenerator {
/**
* Test that generator obeys the property "generate.max.count" and
* "generate.count.mode".
- *
+ *
* @throws Exception
*/
@Test
@@ -267,7 +267,7 @@ public class TestGenerator {
/**
* Test generator obeys the filter setting.
- *
+ *
* @throws Exception
* @throws IOException
*/
@@ -305,7 +305,7 @@ public class TestGenerator {
/**
* Test that Generator can process URLs without a host part.
- *
+ *
* @throws Exception
* @throws IOException
*/
@@ -355,7 +355,7 @@ public class TestGenerator {
/**
* Read contents of fetchlist.
- *
+ *
* @param fetchlist
* path to Generated fetchlist
* @return Generated {@link URLCrawlDatum} objects
@@ -384,15 +384,15 @@ public class TestGenerator {
/**
* Generate Fetchlist.
- *
+ *
* @param numResults
* number of results to generate
* @param config
* Configuration to use
* @return path to generated segment
* @throws IOException
- * @throws InterruptedException
- * @throws ClassNotFoundException
+ * @throws InterruptedException
+ * @throws ClassNotFoundException
*/
private Path generateFetchlist(int numResults, Configuration config,
boolean filter) throws IOException, ClassNotFoundException, InterruptedException {
@@ -407,7 +407,7 @@ public class TestGenerator {
/**
* Creates CrawlDB.
- *
+ *
* @param list
* database contents. The list must be lexicographically sorted by
* URL.
@@ -427,7 +427,7 @@ public class TestGenerator {
/**
* Constructs new {@link URLCrawlDatum} from submitted parameters.
- *
+ *
* @param url
* url to use
* @param fetchInterval
diff --git a/src/test/org/apache/nutch/crawl/TestInjector.java b/src/test/org/apache/nutch/crawl/TestInjector.java
index 74ccc44d0..0d2659cca 100644
--- a/src/test/org/apache/nutch/crawl/TestInjector.java
+++ b/src/test/org/apache/nutch/crawl/TestInjector.java
@@ -36,7 +36,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
* Basic injector test: 1. Creates a text file with urls 2. Injects them into
* crawldb 3. Reads crawldb entries and verifies contents 4. Injects more urls
* into webdb 5. Reads crawldb entries and verifies contents
- *
+ *
*/
public class TestInjector {
diff --git a/src/test/org/apache/nutch/crawl/TestLinkDbMerger.java b/src/test/org/apache/nutch/crawl/TestLinkDbMerger.java
index 837090909..d9897faf5 100644
--- a/src/test/org/apache/nutch/crawl/TestLinkDbMerger.java
+++ b/src/test/org/apache/nutch/crawl/TestLinkDbMerger.java
@@ -142,7 +142,7 @@ public class TestLinkDbMerger {
TreeMap<String, String[]> init) throws Exception {
LOG.debug("* creating linkdb: {}", linkdb);
Path dir = new Path(linkdb, LinkDb.CURRENT_NAME);
-
+
Option wKeyOpt = MapFile.Writer.keyClass(Text.class);
org.apache.hadoop.io.SequenceFile.Writer.Option wValueOpt = SequenceFile.Writer.valueClass(Inlinks.class);
MapFile.Writer writer = new MapFile.Writer(config, new Path(dir,
diff --git a/src/test/org/apache/nutch/indexer/TestIndexingFilters.java b/src/test/org/apache/nutch/indexer/TestIndexingFilters.java
index f4a1b2cf7..62a95ce64 100644
--- a/src/test/org/apache/nutch/indexer/TestIndexingFilters.java
+++ b/src/test/org/apache/nutch/indexer/TestIndexingFilters.java
@@ -35,7 +35,7 @@ public class TestIndexingFilters {
/**
* Test behaviour when defined filter does not exist.
- *
+ *
* @throws IndexingException
*/
@Test
@@ -74,7 +74,7 @@ public class TestIndexingFilters {
/**
* Test behaviour when reset the index filter order will not take effect
- *
+ *
* @throws IndexingException
*/
@Test
diff --git a/src/test/org/apache/nutch/metadata/TestMetadata.java b/src/test/org/apache/nutch/metadata/TestMetadata.java
index 9c7791c72..f73fd6cb9 100644
--- a/src/test/org/apache/nutch/metadata/TestMetadata.java
+++ b/src/test/org/apache/nutch/metadata/TestMetadata.java
@@ -37,9 +37,9 @@ public class TestMetadata {
/**
* Test to ensure that only non-null values get written when the
* {@link Metadata} object is written using a Writeable.
- *
+ *
* @since NUTCH-406
- *
+ *
*/
@Test
public void testWriteNonNull() {
diff --git a/src/test/org/apache/nutch/metadata/TestSpellCheckedMetadata.java b/src/test/org/apache/nutch/metadata/TestSpellCheckedMetadata.java
index bc451942a..c36f02139 100644
--- a/src/test/org/apache/nutch/metadata/TestSpellCheckedMetadata.java
+++ b/src/test/org/apache/nutch/metadata/TestSpellCheckedMetadata.java
@@ -31,7 +31,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
* JUnit based tests of class
* {@link org.apache.nutch.metadata.SpellCheckedMetadata}.
- *
+ *
*/
public class TestSpellCheckedMetadata {
@@ -186,7 +186,7 @@ public class TestSpellCheckedMetadata {
meta.add("a-name", "value-1");
assertEquals("value-1", meta.get("a-name"));
-
+
assertNotNull(meta.get("a-NamE"));
assertEquals("value-1", meta.get("a-NamE"));
}
@@ -327,7 +327,7 @@ public class TestSpellCheckedMetadata {
assertEquals("text/html", result.get(Metadata.CONTENT_TYPE));
}
- /**
+ /**
* Mock class to test backward compatibility of SpellCheckedMetadata
* after changing the internal storage to be case insensitive.
*/
diff --git a/src/test/org/apache/nutch/metrics/TestErrorTracker.java b/src/test/org/apache/nutch/metrics/TestErrorTracker.java
index 5caa3e3a7..ccf579481 100644
--- a/src/test/org/apache/nutch/metrics/TestErrorTracker.java
+++ b/src/test/org/apache/nutch/metrics/TestErrorTracker.java
@@ -72,17 +72,17 @@ public class TestErrorTracker {
@Test
public void testCategorizeNetworkErrors() {
// Test IOException
- assertEquals(ErrorType.NETWORK,
+ assertEquals(ErrorType.NETWORK,
ErrorTracker.categorize(new IOException("Connection failed")));
-
+
// Test SocketException
- assertEquals(ErrorType.NETWORK,
+ assertEquals(ErrorType.NETWORK,
ErrorTracker.categorize(new SocketException("Socket closed")));
-
+
// Test UnknownHostException
- assertEquals(ErrorType.NETWORK,
+ assertEquals(ErrorType.NETWORK,
ErrorTracker.categorize(new UnknownHostException("example.com")));
-
+
// Test ConnectException
assertEquals(ErrorType.NETWORK,
ErrorTracker.categorize(new ConnectException("Connection refused")));
@@ -95,7 +95,7 @@ public class TestErrorTracker {
@Test
public void testCategorizeTimeoutErrors() {
// Test SocketTimeoutException
- assertEquals(ErrorType.TIMEOUT,
+ assertEquals(ErrorType.TIMEOUT,
ErrorTracker.categorize(new SocketTimeoutException("Read timed out")));
}
@@ -121,9 +121,9 @@ public class TestErrorTracker {
@Test
public void testCategorizeUrlErrors() {
// Test MalformedURLException
- assertEquals(ErrorType.URL,
+ assertEquals(ErrorType.URL,
ErrorTracker.categorize(new MalformedURLException("Invalid URL")));
-
+
// Test URISyntaxException
assertEquals(ErrorType.URL,
ErrorTracker.categorize(new URISyntaxException("bad uri", "Invalid syntax")));
@@ -145,7 +145,7 @@ public class TestErrorTracker {
// Test ProtocolException (Nutch-specific)
assertEquals(ErrorType.PROTOCOL,
ErrorTracker.categorize(new ProtocolException("Protocol error")));
-
+
// Test ProtocolNotFound (Nutch-specific)
assertEquals(ErrorType.PROTOCOL,
ErrorTracker.categorize(new ProtocolNotFound("ftp")));
@@ -160,11 +160,11 @@ public class TestErrorTracker {
// Test ParseException (Nutch-specific)
assertEquals(ErrorType.PARSING,
ErrorTracker.categorize(new ParseException("Parse failed")));
-
+
// Test ParserNotFound (Nutch-specific)
assertEquals(ErrorType.PARSING,
ErrorTracker.categorize(new ParserNotFound("text/unknown")));
-
+
// Test SAXException
assertEquals(ErrorType.PARSING,
ErrorTracker.categorize(new SAXException("XML parse error")));
@@ -205,11 +205,11 @@ public class TestErrorTracker {
@Test
public void testCategorizeGenericException() {
// Generic Exception should return OTHER
- assertEquals(ErrorType.OTHER,
+ assertEquals(ErrorType.OTHER,
ErrorTracker.categorize(new Exception("Generic error")));
-
+
// RuntimeException should return OTHER
- assertEquals(ErrorType.OTHER,
+ assertEquals(ErrorType.OTHER,
ErrorTracker.categorize(new RuntimeException("Runtime error")));
}
@@ -223,7 +223,7 @@ public class TestErrorTracker {
IOException cause = new IOException("Root cause");
Exception wrapper = new Exception("Wrapper", cause);
assertEquals(ErrorType.NETWORK, ErrorTracker.categorize(wrapper));
-
+
// Exception with a timeout cause should be categorized as TIMEOUT
SocketTimeoutException timeoutCause = new SocketTimeoutException("Timeout");
Exception timeoutWrapper = new Exception("Wrapper", timeoutCause);
@@ -237,7 +237,7 @@ public class TestErrorTracker {
Exception middleWrapper = new Exception("Middle", rootCause);
RuntimeException outerWrapper = new RuntimeException("Outer", middleWrapper);
assertEquals(ErrorType.NETWORK, ErrorTracker.categorize(outerWrapper));
-
+
// Deep nested with Nutch-specific exception
ScoringFilterException scoringCause = new ScoringFilterException("Scoring error");
Exception wrapper1 = new Exception("Wrapper 1", scoringCause);
@@ -252,22 +252,22 @@ public class TestErrorTracker {
@Test
public void testRecordErrorByType() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Initially all counts should be 0
assertEquals(0, tracker.getTotalCount());
assertEquals(0, tracker.getCount(ErrorType.NETWORK));
-
+
// Record a NETWORK error
tracker.recordError(ErrorType.NETWORK);
assertEquals(1, tracker.getTotalCount());
assertEquals(1, tracker.getCount(ErrorType.NETWORK));
assertEquals(0, tracker.getCount(ErrorType.TIMEOUT));
-
+
// Record another NETWORK error
tracker.recordError(ErrorType.NETWORK);
assertEquals(2, tracker.getTotalCount());
assertEquals(2, tracker.getCount(ErrorType.NETWORK));
-
+
// Record a TIMEOUT error
tracker.recordError(ErrorType.TIMEOUT);
assertEquals(3, tracker.getTotalCount());
@@ -278,17 +278,17 @@ public class TestErrorTracker {
@Test
public void testRecordErrorByThrowable() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Record an IOException (should be categorized as NETWORK)
tracker.recordError(new IOException("Test"));
assertEquals(1, tracker.getTotalCount());
assertEquals(1, tracker.getCount(ErrorType.NETWORK));
-
+
// Record a SocketTimeoutException (should be categorized as TIMEOUT)
tracker.recordError(new SocketTimeoutException("Test"));
assertEquals(2, tracker.getTotalCount());
assertEquals(1, tracker.getCount(ErrorType.TIMEOUT));
-
+
// Record a MalformedURLException (should be categorized as URL)
tracker.recordError(new MalformedURLException("Test"));
assertEquals(3, tracker.getTotalCount());
@@ -302,36 +302,36 @@ public class TestErrorTracker {
@Test
public void testGetCounterName() {
// Test counter name mapping
- assertEquals(NutchMetrics.ERROR_NETWORK_TOTAL,
+ assertEquals(NutchMetrics.ERROR_NETWORK_TOTAL,
ErrorTracker.getCounterName(ErrorType.NETWORK));
- assertEquals(NutchMetrics.ERROR_PROTOCOL_TOTAL,
+ assertEquals(NutchMetrics.ERROR_PROTOCOL_TOTAL,
ErrorTracker.getCounterName(ErrorType.PROTOCOL));
- assertEquals(NutchMetrics.ERROR_PARSING_TOTAL,
+ assertEquals(NutchMetrics.ERROR_PARSING_TOTAL,
ErrorTracker.getCounterName(ErrorType.PARSING));
- assertEquals(NutchMetrics.ERROR_URL_TOTAL,
+ assertEquals(NutchMetrics.ERROR_URL_TOTAL,
ErrorTracker.getCounterName(ErrorType.URL));
- assertEquals(NutchMetrics.ERROR_SCORING_TOTAL,
+ assertEquals(NutchMetrics.ERROR_SCORING_TOTAL,
ErrorTracker.getCounterName(ErrorType.SCORING));
- assertEquals(NutchMetrics.ERROR_INDEXING_TOTAL,
+ assertEquals(NutchMetrics.ERROR_INDEXING_TOTAL,
ErrorTracker.getCounterName(ErrorType.INDEXING));
- assertEquals(NutchMetrics.ERROR_TIMEOUT_TOTAL,
+ assertEquals(NutchMetrics.ERROR_TIMEOUT_TOTAL,
ErrorTracker.getCounterName(ErrorType.TIMEOUT));
- assertEquals(NutchMetrics.ERROR_OTHER_TOTAL,
+ assertEquals(NutchMetrics.ERROR_OTHER_TOTAL,
ErrorTracker.getCounterName(ErrorType.OTHER));
}
@Test
public void testGetCounterNameForThrowable() {
// Test getting counter name directly from throwable
- assertEquals(NutchMetrics.ERROR_NETWORK_TOTAL,
+ assertEquals(NutchMetrics.ERROR_NETWORK_TOTAL,
ErrorTracker.getCounterName(new IOException("Test")));
- assertEquals(NutchMetrics.ERROR_TIMEOUT_TOTAL,
+ assertEquals(NutchMetrics.ERROR_TIMEOUT_TOTAL,
ErrorTracker.getCounterName(new SocketTimeoutException("Test")));
- assertEquals(NutchMetrics.ERROR_URL_TOTAL,
+ assertEquals(NutchMetrics.ERROR_URL_TOTAL,
ErrorTracker.getCounterName(new MalformedURLException("Test")));
- assertEquals(NutchMetrics.ERROR_OTHER_TOTAL,
+ assertEquals(NutchMetrics.ERROR_OTHER_TOTAL,
ErrorTracker.getCounterName(new RuntimeException("Test")));
-
+
// Test Nutch-specific exceptions
assertEquals(NutchMetrics.ERROR_PROTOCOL_TOTAL,
ErrorTracker.getCounterName(new ProtocolException("Test")));
@@ -351,7 +351,7 @@ public class TestErrorTracker {
public void testConstructorWithContext() {
// Create ErrorTracker with context - should initialize counters
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER, mockContext);
-
+
// Verify counters were requested from context
// Total counter + 8 error type counters = 9 calls
verify(mockContext, atLeast(9)).getCounter(anyString(), anyString());
@@ -360,10 +360,10 @@ public class TestErrorTracker {
@Test
public void testInitCounters() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Initialize counters
tracker.initCounters(mockContext);
-
+
// Verify counters were requested
verify(mockContext).getCounter(NutchMetrics.GROUP_FETCHER, NutchMetrics.ERROR_TOTAL);
verify(mockContext).getCounter(NutchMetrics.GROUP_FETCHER, NutchMetrics.ERROR_NETWORK_TOTAL);
@@ -373,10 +373,10 @@ public class TestErrorTracker {
@Test
public void testIncrementCountersWithType() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER, mockContext);
-
+
// Increment counters directly
tracker.incrementCounters(ErrorType.NETWORK);
-
+
// Verify counter was incremented (total + specific type)
verify(mockCounter, times(2)).increment(1);
}
@@ -384,10 +384,10 @@ public class TestErrorTracker {
@Test
public void testIncrementCountersWithThrowable() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER, mockContext);
-
+
// Increment counters with throwable
tracker.incrementCounters(new IOException("Test"));
-
+
// Verify counter was incremented (total + NETWORK type)
verify(mockCounter, times(2)).increment(1);
}
@@ -395,7 +395,7 @@ public class TestErrorTracker {
@Test
public void testIncrementCountersWithoutInit() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Should throw IllegalStateException when counters not initialized
assertThrows(IllegalStateException.class, () -> {
tracker.incrementCounters(ErrorType.NETWORK);
@@ -405,15 +405,15 @@ public class TestErrorTracker {
@Test
public void testEmitCounters() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Record some errors locally
tracker.recordError(ErrorType.NETWORK);
tracker.recordError(ErrorType.NETWORK);
tracker.recordError(ErrorType.TIMEOUT);
-
+
// Emit counters (without cached counters - uses fallback)
tracker.emitCounters(mockContext);
-
+
// Verify counters were requested and incremented
verify(mockContext).getCounter(NutchMetrics.GROUP_FETCHER, NutchMetrics.ERROR_TOTAL);
verify(mockContext).getCounter(NutchMetrics.GROUP_FETCHER, NutchMetrics.ERROR_NETWORK_TOTAL);
@@ -423,18 +423,18 @@ public class TestErrorTracker {
@Test
public void testEmitCountersWithCachedCounters() {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER, mockContext);
-
+
// Reset mock to clear constructor calls
reset(mockCounter);
-
+
// Record some errors locally
tracker.recordError(ErrorType.NETWORK);
tracker.recordError(ErrorType.NETWORK);
tracker.recordError(ErrorType.TIMEOUT);
-
+
// Emit counters (with cached counters)
tracker.emitCounters(mockContext);
-
+
// Verify cached counters were used (increment called with accumulated values)
verify(mockCounter).increment(3L); // total count
verify(mockCounter).increment(2L); // NETWORK count
@@ -448,7 +448,7 @@ public class TestErrorTracker {
@Test
public void testThreadSafety() throws InterruptedException {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Create multiple threads that record errors concurrently
Thread[] threads = new Thread[10];
for (int i = 0; i < threads.length; i++) {
@@ -458,17 +458,17 @@ public class TestErrorTracker {
}
});
}
-
+
// Start all threads
for (Thread thread : threads) {
thread.start();
}
-
+
// Wait for all threads to complete
for (Thread thread : threads) {
thread.join();
}
-
+
// Verify counts
assertEquals(1000, tracker.getTotalCount());
assertEquals(1000, tracker.getCount(ErrorType.NETWORK));
@@ -477,34 +477,34 @@ public class TestErrorTracker {
@Test
public void testThreadSafetyMixedErrorTypes() throws InterruptedException {
ErrorTracker tracker = new ErrorTracker(NutchMetrics.GROUP_FETCHER);
-
+
// Create threads that record different error types concurrently
Thread networkThread = new Thread(() -> {
for (int i = 0; i < 500; i++) {
tracker.recordError(ErrorType.NETWORK);
}
});
-
+
Thread timeoutThread = new Thread(() -> {
for (int i = 0; i < 300; i++) {
tracker.recordError(ErrorType.TIMEOUT);
}
});
-
+
Thread urlThread = new Thread(() -> {
for (int i = 0; i < 200; i++) {
tracker.recordError(ErrorType.URL);
}
});
-
+
networkThread.start();
timeoutThread.start();
urlThread.start();
-
+
networkThread.join();
timeoutThread.join();
urlThread.join();
-
+
// Verify counts
assertEquals(1000, tracker.getTotalCount());
assertEquals(500, tracker.getCount(ErrorType.NETWORK));
diff --git a/src/test/org/apache/nutch/net/TestURLFilters.java b/src/test/org/apache/nutch/net/TestURLFilters.java
index 00c9b1489..5baca3f55 100644
--- a/src/test/org/apache/nutch/net/TestURLFilters.java
+++ b/src/test/org/apache/nutch/net/TestURLFilters.java
@@ -24,7 +24,7 @@ public class TestURLFilters {
/**
* Testcase for NUTCH-325.
- *
+ *
* @throws URLFilterException
*/
@Test
diff --git a/src/test/org/apache/nutch/net/protocols/TestHttpDateFormat.java b/src/test/org/apache/nutch/net/protocols/TestHttpDateFormat.java
index 818d35b30..2d2e4b3cc 100644
--- a/src/test/org/apache/nutch/net/protocols/TestHttpDateFormat.java
+++ b/src/test/org/apache/nutch/net/protocols/TestHttpDateFormat.java
@@ -31,7 +31,7 @@ public class TestHttpDateFormat {
/**
* Test date as string and epoche milliseconds:
- *
+ *
* <pre>
* $> date --date "Sun, 06 Nov 1994 08:49:37 GMT" '+%s'
* 784111777
diff --git a/src/test/org/apache/nutch/parse/TestOutlinkExtractor.java b/src/test/org/apache/nutch/parse/TestOutlinkExtractor.java
index ed39d9dfd..ffea90796 100644
--- a/src/test/org/apache/nutch/parse/TestOutlinkExtractor.java
+++ b/src/test/org/apache/nutch/parse/TestOutlinkExtractor.java
@@ -24,8 +24,8 @@ import static org.junit.jupiter.api.Assertions.*;
/**
* TestCase to check regExp extraction of URLs.
- *
- *
+ *
+ *
* @version 1.0
*/
public class TestOutlinkExtractor {
diff --git a/src/test/org/apache/nutch/parse/TestParserFactory.java b/src/test/org/apache/nutch/parse/TestParserFactory.java
index bbdef8eb8..c00e04838 100644
--- a/src/test/org/apache/nutch/parse/TestParserFactory.java
+++ b/src/test/org/apache/nutch/parse/TestParserFactory.java
@@ -28,7 +28,7 @@ import static org.junit.jupiter.api.Assertions.assertNotNull;
/**
* Unit test for new parse plugin selection.
- *
+ *
* @version 1.0
*/
public class TestParserFactory {
diff --git a/src/test/org/apache/nutch/parse/parse-plugin-test.xml b/src/test/org/apache/nutch/parse/parse-plugin-test.xml
index b748905dc..f6a426776 100644
--- a/src/test/org/apache/nutch/parse/parse-plugin-test.xml
+++ b/src/test/org/apache/nutch/parse/parse-plugin-test.xml
@@ -15,13 +15,13 @@
See the License for the specific language governing permissions and
limitations under the License.
- Author : mattmann
- Description: Test parse-plugins.xml file.
+ Author : mattmann
+ Description: Test parse-plugins.xml file.
-->
<parse-plugins>
- <!-- by default if the mimeType is set to *, or
+ <!-- by default if the mimeType is set to *, or
if it can't be determined, use parse-tika -->
<mimeType name="*">
<plugin id="parse-tika" />
@@ -35,17 +35,17 @@
!-->
<plugin id="parse-plugin-that-not-exist"/>
</mimeType>
-
+
<mimeType name="application/x-javascript">
<plugin id="parse-js"/>
</mimeType>
-
+
<mimeType name="text/rss">
<!-- Test that an extension-id can be directly used here -->
<plugin id="org.apache.nutch.parse.rss.RSSParser"/>
</mimeType>
- <!-- alias mappings for parse-xxx names to the actual extension implementation
+ <!-- alias mappings for parse-xxx names to the actual extension implementation
ids described in each plugin's plugin.xml file -->
<aliases>
<alias name="parse-js"
diff --git a/src/test/org/apache/nutch/plugin/HelloWorldExtension.java b/src/test/org/apache/nutch/plugin/HelloWorldExtension.java
index 32bf4e592..f21ef2f1c 100644
--- a/src/test/org/apache/nutch/plugin/HelloWorldExtension.java
+++ b/src/test/org/apache/nutch/plugin/HelloWorldExtension.java
@@ -18,13 +18,13 @@ package org.apache.nutch.plugin;
/**
* Simple Test-extensions
- *
+ *
*/
public class HelloWorldExtension implements ITestExtension {
/*
* (non-Javadoc)
- *
+ *
* @see
* org.apache.nutch.plugin.ITestExtension#testGetExtension(java.lang.String)
*/
diff --git a/src/test/org/apache/nutch/plugin/ITestExtension.java b/src/test/org/apache/nutch/plugin/ITestExtension.java
index 95cd18e95..9d386e103 100644
--- a/src/test/org/apache/nutch/plugin/ITestExtension.java
+++ b/src/test/org/apache/nutch/plugin/ITestExtension.java
@@ -18,8 +18,8 @@ package org.apache.nutch.plugin;
/**
* A Simple Test Extension Interface.
- *
- *
+ *
+ *
*/
public interface ITestExtension {
public String testGetExtension(String hello);
diff --git a/src/test/org/apache/nutch/plugin/SimpleTestPlugin.java b/src/test/org/apache/nutch/plugin/SimpleTestPlugin.java
index e3a4e1118..eae19fe81 100644
--- a/src/test/org/apache/nutch/plugin/SimpleTestPlugin.java
+++ b/src/test/org/apache/nutch/plugin/SimpleTestPlugin.java
@@ -20,7 +20,7 @@ import org.apache.hadoop.conf.Configuration;
/**
* Simple Test plugin
- *
+ *
*/
public class SimpleTestPlugin extends Plugin {
@@ -44,7 +44,7 @@ public class SimpleTestPlugin extends Plugin {
/*
* (non-Javadoc)
- *
+ *
* @see org.apache.nutch.plugin.Plugin#shutDown()
*/
@Override
diff --git a/src/test/org/apache/nutch/protocol/AbstractHttpProtocolPluginTest.java b/src/test/org/apache/nutch/protocol/AbstractHttpProtocolPluginTest.java
index 8ac14cc15..72877d146 100644
--- a/src/test/org/apache/nutch/protocol/AbstractHttpProtocolPluginTest.java
+++ b/src/test/org/apache/nutch/protocol/AbstractHttpProtocolPluginTest.java
@@ -119,7 +119,7 @@ public abstract class AbstractHttpProtocolPluginTest {
/**
* Starts the test server at a specified port and constant response.
- *
+ *
* @param port
* Port number. If 0, a random free port is used. The port number
* actually used by the test server is always stored in
@@ -264,7 +264,7 @@ public abstract class AbstractHttpProtocolPluginTest {
* Fetches the specified <code>page</code> from the local test server and
* checks whether the HTTP response status code matches with the expected
* code.
- *
+ *
* @param port
* port server is listening on
* @param page
diff --git a/src/test/org/apache/nutch/tools/TestCommonCrawlDataDumper.java b/src/test/org/apache/nutch/tools/TestCommonCrawlDataDumper.java
index 8124fe20b..575f26b22 100644
--- a/src/test/org/apache/nutch/tools/TestCommonCrawlDataDumper.java
+++ b/src/test/org/apache/nutch/tools/TestCommonCrawlDataDumper.java
@@ -32,7 +32,7 @@ import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
/**
- *
+ *
* Test harness for the {@link CommonCrawlDataDumper}.
*
*/
diff --git a/src/test/org/apache/nutch/util/CancellationAwareTestUtils.java b/src/test/org/apache/nutch/util/CancellationAwareTestUtils.java
index 055a64261..c0a9be862 100644
--- a/src/test/org/apache/nutch/util/CancellationAwareTestUtils.java
+++ b/src/test/org/apache/nutch/util/CancellationAwareTestUtils.java
@@ -24,19 +24,19 @@ import java.util.function.BooleanSupplier;
/**
* Utility class for making long-running tests cancellation-aware.
- *
+ *
* <p>This supports JUnit 6's fail-fast mode by allowing tests to check
* for cancellation requests and exit gracefully, ensuring proper resource
* cleanup even when the test suite is stopped early.</p>
- *
+ *
* <p>Usage example:</p>
* <pre>{@code
* @Test
* @Timeout(value = 5, unit = TimeUnit.MINUTES)
* void testLongRunningOperation() throws Exception {
- * CancellationAwareTestUtils.CancellationToken token =
+ * CancellationAwareTestUtils.CancellationToken token =
* CancellationAwareTestUtils.createToken();
- *
+ *
* try {
* while (hasMoreWork() && !token.isCancelled()) {
* doWork();
@@ -65,7 +65,7 @@ public class CancellationAwareTestUtils {
/**
* Check if cancellation has been requested.
* This checks both explicit cancellation and thread interruption.
- *
+ *
* @return true if the operation should be cancelled
*/
public boolean isCancelled() {
@@ -93,7 +93,7 @@ public class CancellationAwareTestUtils {
/**
* Throws InterruptedException if cancellation has been requested.
* Useful for cooperative cancellation in loops.
- *
+ *
* @throws InterruptedException if cancelled
*/
public void throwIfCancelled() throws InterruptedException {
@@ -105,7 +105,7 @@ public class CancellationAwareTestUtils {
/**
* Creates a new cancellation token.
- *
+ *
* @return a new CancellationToken instance
*/
@NonNull
@@ -115,7 +115,7 @@ public class CancellationAwareTestUtils {
/**
* Creates a cancellation token with an additional cancellation condition.
- *
+ *
* @param additionalCheck additional condition that triggers cancellation
* @return a new CancellationToken instance
*/
@@ -126,7 +126,7 @@ public class CancellationAwareTestUtils {
/**
* Executes an operation with periodic cancellation checks.
- *
+ *
* @param token the cancellation token to check
* @param operation the operation to execute (should be short-lived)
* @param iterations number of times to execute the operation
@@ -139,7 +139,7 @@ public class CancellationAwareTestUtils {
@NonNull Runnable operation,
int iterations,
int checkInterval) throws InterruptedException {
-
+
int completed = 0;
for (int i = 0; i < iterations; i++) {
if (i % checkInterval == 0) {
@@ -154,12 +154,12 @@ public class CancellationAwareTestUtils {
/**
* Sleeps for the specified duration while remaining cancellation-aware.
* Checks for cancellation every 100ms.
- *
+ *
* @param token the cancellation token
* @param millis total milliseconds to sleep
* @throws InterruptedException if cancelled or interrupted
*/
- public static void sleepWithCancellation(@NonNull CancellationToken token, long millis)
+ public static void sleepWithCancellation(@NonNull CancellationToken token, long millis)
throws InterruptedException {
long remaining = millis;
while (remaining > 0) {
@@ -172,14 +172,14 @@ public class CancellationAwareTestUtils {
/**
* Interface for operations that can be interrupted and resumed.
- *
+ *
* @param <T> the result type
*/
@FunctionalInterface
public interface CancellableOperation<T> {
/**
* Execute a portion of the operation.
- *
+ *
* @param token cancellation token to check
* @return the result, or null if more work is needed
* @throws Exception if the operation fails
@@ -190,7 +190,7 @@ public class CancellationAwareTestUtils {
/**
* Runs a cancellable operation, returning null if cancelled before completion.
- *
+ *
* @param <T> the result type
* @param operation the operation to run
* @return the result, or null if cancelled
diff --git a/src/testresources/fetch-test-site/nested_spider_trap.html b/src/testresources/fetch-test-site/nested_spider_trap.html
index dd32ee236..753459dc7 100644
--- a/src/testresources/fetch-test-site/nested_spider_trap.html
+++ b/src/testresources/fetch-test-site/nested_spider_trap.html
@@ -21,19 +21,19 @@
<body>Nutch fetcher test page
<table>
- <tr>
+ <tr>
<td>
-<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
-<b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b>
-<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
-<i><b><i><b><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></b></i></b></i>
-<b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
-</b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b>
-<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
+<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
+<b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b>
+<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
+<i><b><i><b><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></b></i></b></i>
+<b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
+</b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b>
+<i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b><i><b></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i></b></i>
</td>
</tr>
-
+
</table>
</body>
</html>
\ No newline at end of file