Apache Nutch is an extensible and scalable web crawler
Add a log4j library plugin (lib-log4j)
Jerome Charron5889cf4a5016
diff --git a/src/plugin/build.xml b/src/plugin/build.xmlindex 1e88de532..cfc86b85a 100755--- a/src/plugin/build.xml+++ b/src/plugin/build.xml@@ -13,6 +13,7 @@<ant dir="languageidentifier" target="deploy"/><ant dir="lib-http" target="deploy"/><ant dir="lib-jakarta-poi" target="deploy"/>+ <ant dir="lib-log4j" target="deploy"/><ant dir="lib-lucene-analyzers" target="deploy"/><ant dir="lib-parsems" target="deploy"/><ant dir="nutch-extensionpoints" target="deploy"/>@@ -78,6 +79,7 @@<ant dir="languageidentifier" target="clean"/><ant dir="lib-http" target="clean"/><ant dir="lib-jakarta-poi" target="clean"/>+ <ant dir="lib-log4j" target="clean"/><ant dir="lib-lucene-analyzers" target="clean"/><ant dir="lib-parsems" target="clean"/><ant dir="nutch-extensionpoints" target="clean"/>diff --git a/src/plugin/clustering-carrot2/build.xml b/src/plugin/clustering-carrot2/build.xmlindex e4e3eab22..e700c7f0a 100644--- a/src/plugin/clustering-carrot2/build.xml+++ b/src/plugin/clustering-carrot2/build.xml@@ -4,4 +4,10 @@<import file="../build-plugin.xml"/>+ <path id="plugin.deps">+ <fileset dir="../lib-log4j/lib">+ <include name="*.jar" />+ </fileset>+ </path>+</project>diff --git a/src/plugin/clustering-carrot2/lib/log4j.LICENSE b/src/plugin/clustering-carrot2/lib/log4j.LICENSEdeleted file mode 100644index 030564fc1..000000000--- a/src/plugin/clustering-carrot2/lib/log4j.LICENSE+++ /dev/null@@ -1,48 +0,0 @@-/*- * ============================================================================- * The Apache Software License, Version 1.1- * ============================================================================- *- * Copyright (C) 1999 The Apache Software Foundation. All rights reserved.- *- * Redistribution and use in source and binary forms, with or without modifica-- * tion, are permitted provided that the following conditions are met:- *- * 1. Redistributions of source code must retain the above copyright notice,- * this list of conditions and the following disclaimer.- *- * 2. Redistributions in binary form must reproduce the above copyright notice,- * this list of conditions and the following disclaimer in the documentation- * and/or other materials provided with the distribution.- *- * 3. The end-user documentation included with the redistribution, if any, must- * include the following acknowledgment: "This product includes software- * developed by the Apache Software Foundation (http://www.apache.org/)."- * Alternately, this acknowledgment may appear in the software itself, if- * and wherever such third-party acknowledgments normally appear.- *- * 4. The names "log4j" and "Apache Software Foundation" must not be used to- * endorse or promote products derived from this software without prior- * written permission. For written permission, please contact- * [email protected].- *- * 5. Products derived from this software may not be called "Apache", nor may- * "Apache" appear in their name, without prior written permission of the- * Apache Software Foundation.- *- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,- * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND- * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE- * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-- * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.- *- * This software consists of voluntary contributions made by many individuals- * on behalf of the Apache Software Foundation. For more information on the- * Apache Software Foundation, please see <http://www.apache.org/>.- *- */diff --git a/src/plugin/clustering-carrot2/plugin.xml b/src/plugin/clustering-carrot2/plugin.xmlindex 882855253..38820932c 100644--- a/src/plugin/clustering-carrot2/plugin.xml+++ b/src/plugin/clustering-carrot2/plugin.xml@@ -29,6 +29,7 @@<requires><import plugin="nutch-extensionpoints"/>+ <import plugin="lib-log4j"/></requires><extension id="org.apache.nutch.clustering.carrot2"diff --git a/src/plugin/lib-log4j/build.xml b/src/plugin/lib-log4j/build.xmlnew file mode 100644index 000000000..0eeb32e9e--- /dev/null+++ b/src/plugin/lib-log4j/build.xml@@ -0,0 +1,17 @@+<?xml version="1.0"?>++<project name="lib-log4j" default="jar">++ <import file="../build-plugin.xml"/>++ <!--+ ! Override the compile and jar targets,+ ! since there is nothing to compile here.+ ! -->+ <target name="compile" depends="init">+ <echo message="Compiling plugin: ${name}"/>+ </target>++ <target name="jar" depends="compile"/>++</project>diff --git a/src/plugin/clustering-carrot2/lib/log4j-1.2.11.jar b/src/plugin/lib-log4j/lib/log4j-1.2.11.jarsimilarity index 100%rename from src/plugin/clustering-carrot2/lib/log4j-1.2.11.jarrename to src/plugin/lib-log4j/lib/log4j-1.2.11.jardiff --git a/src/plugin/lib-log4j/plugin.xml b/src/plugin/lib-log4j/plugin.xmlnew file mode 100644index 000000000..6ebf6a960--- /dev/null+++ b/src/plugin/lib-log4j/plugin.xml@@ -0,0 +1,21 @@+<?xml version="1.0" encoding="UTF-8"?>+<!--+ ! Log4j library+ ! (http://logging.apache.org/log4j/)+ !+ ! Dowload : http://logging.apache.org/site/binindex.cgi+ ! License : http://www.apache.org/licenses/LICENSE-2.0.txt+ !-->+<plugin+ id="lib-log4j"+ name="Log4j"+ version="1.2.11"+ provider-name="org.apache.log4j">++ <runtime>+ <library name="log4j-1.2.11.jar">+ <export name="*"/>+ </library>+ </runtime>++</plugin>diff --git a/src/plugin/parse-pdf/build.xml b/src/plugin/parse-pdf/build.xmlindex cb758566c..872bda75e 100644--- a/src/plugin/parse-pdf/build.xml+++ b/src/plugin/parse-pdf/build.xml@@ -4,6 +4,12 @@<import file="../build-plugin.xml"/>+ <path id="plugin.deps">+ <fileset dir="../lib-log4j/lib">+ <include name="*.jar" />+ </fileset>+ </path>+<!-- for junit test --><mkdir dir="${build.test}/data"/><copy file="sample/pdftest.pdf" todir="${build.test}/data"/>diff --git a/src/plugin/parse-pdf/lib/log4j-1.2.9.jar b/src/plugin/parse-pdf/lib/log4j-1.2.9.jardeleted file mode 100644index a6568b01a..000000000Binary files a/src/plugin/parse-pdf/lib/log4j-1.2.9.jar and /dev/null differdiff --git a/src/plugin/parse-pdf/lib/log4j-LICENSE.txt b/src/plugin/parse-pdf/lib/log4j-LICENSE.txtdeleted file mode 100644index 007db57f8..000000000--- a/src/plugin/parse-pdf/lib/log4j-LICENSE.txt+++ /dev/null@@ -1,48 +0,0 @@-/*- * ============================================================================- * The Apache Software License, Version 1.1- * ============================================================================- *- * Copyright (C) 1999 The Apache Software Foundation. All rights reserved.- *- * Redistribution and use in source and binary forms, with or without modifica-- * tion, are permitted provided that the following conditions are met:- *- * 1. Redistributions of source code must retain the above copyright notice,- * this list of conditions and the following disclaimer.- *- * 2. Redistributions in binary form must reproduce the above copyright notice,- * this list of conditions and the following disclaimer in the documentation- * and/or other materials provided with the distribution.- *- * 3. The end-user documentation included with the redistribution, if any, must- * include the following acknowledgment: "This product includes software- * developed by the Apache Software Foundation (http://www.apache.org/)."- * Alternately, this acknowledgment may appear in the software itself, if- * and wherever such third-party acknowledgments normally appear.- *- * 4. The names "log4j" and "Apache Software Foundation" must not be used to- * endorse or promote products derived from this software without prior- * written permission. For written permission, please contact- * [email protected].- *- * 5. Products derived from this software may not be called "Apache", nor may- * "Apache" appear in their name, without prior written permission of the- * Apache Software Foundation.- *- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,- * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND- * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE- * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-- * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.- *- * This software consists of voluntary contributions made by many individuals- * on behalf of the Apache Software Foundation. For more information on the- * Apache Software Foundation, please see <http://www.apache.org/>.- *- */diff --git a/src/plugin/parse-pdf/plugin.xml b/src/plugin/parse-pdf/plugin.xmlindex d91739afe..56b01f885 100644--- a/src/plugin/parse-pdf/plugin.xml+++ b/src/plugin/parse-pdf/plugin.xml@@ -16,6 +16,7 @@<requires><import plugin="nutch-extensionpoints"/>+ <import plugin="lib-log4j"/></requires><extension id="org.apache.nutch.parse.pdf"diff --git a/src/plugin/parse-rss/build.xml b/src/plugin/parse-rss/build.xmlindex d2045a8d4..9e2b806d4 100644--- a/src/plugin/parse-rss/build.xml+++ b/src/plugin/parse-rss/build.xml@@ -4,6 +4,11 @@<import file="../build-plugin.xml"/>+ <path id="plugin.deps">+ <fileset dir="../lib-log4j/lib">+ <include name="*.jar" />+ </fileset>+ </path><!-- for junit test --><mkdir dir="${build.test}/data"/>diff --git a/src/plugin/parse-rss/lib/log4j-1.2.6.jar b/src/plugin/parse-rss/lib/log4j-1.2.6.jardeleted file mode 100644index be4a9176c..000000000Binary files a/src/plugin/parse-rss/lib/log4j-1.2.6.jar and /dev/null differdiff --git a/src/plugin/parse-rss/plugin.xml b/src/plugin/parse-rss/plugin.xmlindex f02d40c07..4c222aae3 100644--- a/src/plugin/parse-rss/plugin.xml+++ b/src/plugin/parse-rss/plugin.xml@@ -24,6 +24,7 @@<requires><import plugin="nutch-extensionpoints"/>+ <import plugin="lib-log4j"/></requires><extension id="org.apache.nutch.parse.rss"