lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sha...@apache.org
Subject svn commit: r890679 - in /lucene/solr/trunk: ./ contrib/dataimporthandler/ contrib/dataimporthandler/src/extras/ contrib/dataimporthandler/src/extras/main/ contrib/dataimporthandler/src/extras/main/java/ contrib/dataimporthandler/src/extras/main/java/o...
Date Tue, 15 Dec 2009 07:49:08 GMT
Author: shalin
Date: Tue Dec 15 07:49:07 2009
New Revision: 890679

URL: http://svn.apache.org/viewvc?rev=890679&view=rev
Log:
Reverting SOLR-1643 and moving TikaEntityProcessor and test to extras

Added:
    lucene/solr/trunk/contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java
  (props changed)
      - copied unchanged from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java
  (props changed)
      - copied unchanged from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java
  (props changed)
      - copied unchanged from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
      - copied, changed from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/resources/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/resources/solr/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/resources/solr/conf/
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/resources/solr/conf/dataimport-schema-no-unique-key.xml
      - copied unchanged from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/test/resources/solr/conf/dataimport-schema-no-unique-key.xml
    lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/resources/solr/conf/dataimport-solrconfig.xml
      - copied unchanged from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/test/resources/solr/conf/dataimport-solrconfig.xml
Removed:
    lucene/solr/trunk/contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
    lucene/solr/trunk/contrib/dataimporthandler/src/test/resources/solr/conf/dataimport-schema-no-unique-key.xml
Modified:
    lucene/solr/trunk/build.xml
    lucene/solr/trunk/contrib/dataimporthandler/CHANGES.txt
    lucene/solr/trunk/contrib/dataimporthandler/build.xml

Modified: lucene/solr/trunk/build.xml
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/build.xml?rev=890679&r1=890678&r2=890679&view=diff
==============================================================================
--- lucene/solr/trunk/build.xml (original)
+++ lucene/solr/trunk/build.xml Tue Dec 15 07:49:07 2009
@@ -529,6 +529,8 @@
   	
     <solr-jar destfile="${dist}/apache-solr-dataimporthandler-src-${version}.jar"
               basedir="contrib/dataimporthandler/src/main/java" />
+    <solr-jar destfile="${dist}/apache-solr-dataimporthandler-extras-src-${version}.jar"
+              basedir="contrib/dataimporthandler/src/extras/main/java" />
 
     <solr-jar destfile="${dist}/apache-solr-cell-src-${version}.jar"
               basedir="contrib/extraction/src" />
@@ -731,6 +733,7 @@
     <sign-maven-dependency-artifacts artifact.id="solr-commons-csv" gpg.passphrase="${gpg.passphrase}"/>
     <sign-maven-artifacts artifact.id="solr-core" gpg.passphrase="${gpg.passphrase}"/>
     <sign-maven-artifacts artifact.id="solr-dataimporthandler" gpg.passphrase="${gpg.passphrase}"/>
+    <sign-maven-artifacts artifact.id="solr-dataimporthandler-extras" gpg.passphrase="${gpg.passphrase}"/>
     <sign-maven-artifacts artifact.id="solr-clustering" gpg.passphrase="${gpg.passphrase}"/>
 
     <sign-maven-artifacts artifact.id="solr-cell" gpg.passphrase="${gpg.passphrase}"/>
@@ -794,6 +797,15 @@
         </artifact-attachments>
       </m2-deploy>
 
+      <m2-deploy pom.xml="contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template"
+                 jar.file="${dist}/apache-solr-dataimporthandler-extras-${version}.jar">
+
+        <artifact-attachments>
+          <attach file="${dist}/apache-solr-dataimporthandler-extras-src-${version}.jar"
classifier="sources"/>
+          <attach file="${dist}/apache-solr-dataimporthandler-docs-${version}.jar" classifier="javadoc"/>
+        </artifact-attachments>
+      </m2-deploy>
+
       <m2-deploy pom.xml="contrib/extraction/solr-cell-pom.xml.template"
                  jar.file="${dist}/apache-solr-cell-${version}.jar">
         <artifact-attachments>

Modified: lucene/solr/trunk/contrib/dataimporthandler/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/dataimporthandler/CHANGES.txt?rev=890679&r1=890678&r2=890679&view=diff
==============================================================================
--- lucene/solr/trunk/contrib/dataimporthandler/CHANGES.txt (original)
+++ lucene/solr/trunk/contrib/dataimporthandler/CHANGES.txt Tue Dec 15 07:49:07 2009
@@ -50,7 +50,7 @@
 
 Build
 ----------------------
-* SOLR-1643: Moved dataimporthandler extras into dataimporthandler core (shalin)
+
 
 Documentation
 ----------------------

Modified: lucene/solr/trunk/contrib/dataimporthandler/build.xml
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/dataimporthandler/build.xml?rev=890679&r1=890678&r2=890679&view=diff
==============================================================================
--- lucene/solr/trunk/contrib/dataimporthandler/build.xml (original)
+++ lucene/solr/trunk/contrib/dataimporthandler/build.xml Tue Dec 15 07:49:07 2009
@@ -37,10 +37,17 @@
   	<pathelement location="${solr-path}/build/solr" />
   	<pathelement location="${solr-path}/build/solrj" />
   	<fileset dir="${solr-path}/lib" includes="*.jar"/>
-    <fileset dir="lib/" includes="*.jar"/>
-  	<fileset dir="${tikalibs-path}" includes="*.jar"/>
   </path>
 
+  <path id="extras.classpath">
+  	<pathelement location="${solr-path}/build/solr" />
+  	<pathelement location="${solr-path}/build/solrj" />
+  	<pathelement location="target/classes" />
+  	<fileset dir="${solr-path}/lib" includes="*.jar"/>
+  	<fileset dir="lib/" includes="*.jar"/>
+  	<fileset dir="${tikalibs-path}" includes="*.jar"/>
+  </path>
+	
   <path id="test.classpath">
   	<path refid="common.classpath" />
   	<path refid="classpath.jetty" />
@@ -49,6 +56,16 @@
     <pathelement path="${java.class.path}"/>
   </path>
 
+  <path id="test.extras.classpath">
+  	<path refid="extras.classpath" />
+  	<path refid="classpath.jetty" />
+	  <pathelement path="target/classes" />
+	  <pathelement path="target/extras/classes" />
+  	<pathelement path="target/test-classes" />
+  	<pathelement path="target/extras/test-classes" />
+    <pathelement path="${java.class.path}"/>
+  </path>
+	
   <target name="clean">
   	<delete failonerror="false" dir="target"/>
     <delete failonerror="false">
@@ -77,9 +94,18 @@
     </solr-javac>
   </target>
 
-  <target name="build" depends="compile">
+  <target name="compileExtras" depends="compile">
+    <solr-javac destdir="target/extras/classes"
+                classpathref="extras.classpath">
+      <src path="src/extras/main/java" />
+    </solr-javac>
+  </target>
+	
+  <target name="build" depends="compile,compileExtras">
     <solr-jar destfile="target/${fullnamever}.jar" basedir="target/classes"
               manifest="${common.dir}/${dest}/META-INF/MANIFEST.MF" />
+    <solr-jar destfile="target/apache-${ant.project.name}-extras-${version}.jar" basedir="target/extras/classes"
+              manifest="${common.dir}/${dest}/META-INF/MANIFEST.MF" />
   </target>
 	
   <target name="compileTests" depends="compile">
@@ -89,7 +115,16 @@
   	</solr-javac>
   </target>
 
-  <target name="test" depends="compileTests">
+  <target name="compileExtrasTests" depends="compileExtras">
+  	<solr-javac destdir="target/extras/test-classes"
+  	                classpathref="test.classpath">
+  	  <src path="src/extras/test/java" />
+  	</solr-javac>
+  </target>
+
+  <target  name="test" depends="testCore,testExtras"/>
+	
+  <target name="testCore" depends="compileTests">
   	<mkdir dir="${junit.output.dir}"/>
   	
   	<junit printsummary="on"
@@ -112,6 +147,29 @@
     <fail if="tests.failed">Tests failed!</fail>
   </target>
 
+  <target name="testExtras" depends="compileExtrasTests">
+  	<mkdir dir="${junit.output.dir}"/>
+
+  	<junit printsummary="on"
+           haltonfailure="no"
+           errorProperty="tests.failed"
+           failureProperty="tests.failed"
+           dir="src/extras/test/resources/"
+           >
+      <formatter type="brief" usefile="false" if="junit.details"/>
+      <classpath refid="test.extras.classpath"/>
+      <formatter type="xml"/>
+      <batchtest fork="yes" todir="${junit.output.dir}" unless="testcase">
+        <fileset dir="src/extras/test/java" includes="${junit.includes}"/>
+      </batchtest>
+      <batchtest fork="yes" todir="${junit.output.dir}" if="testcase">
+        <fileset dir="src/extras/test/java" includes="**/${testcase}.java"/>
+      </batchtest>
+    </junit>
+
+    <fail if="tests.failed">Tests failed!</fail>
+  </target>
+	
   <target name="dist" depends="build">
   	<copy todir="../../build/web">
   		<fileset dir="src/main/webapp" includes="**" />
@@ -119,6 +177,7 @@
   	<mkdir dir="../../build/web/WEB-INF/lib"/>
   	<copy file="target/${fullnamever}.jar" todir="${solr-path}/build/web/WEB-INF/lib"></copy>
   	<copy file="target/${fullnamever}.jar" todir="${solr-path}/dist"></copy>
+  	<copy file="target/apache-${ant.project.name}-extras-${version}.jar" todir="${solr-path}/dist"></copy>
   </target>
 	
   <target name="javadoc">
@@ -127,6 +186,7 @@
 
       <path id="javadoc.classpath">
         <path refid="common.classpath"/>
+        <path refid="extras.classpath"/>
       </path>
 
       <invoke-javadoc
@@ -134,6 +194,7 @@
       	title="${Name} ${version} contrib-${fullnamever} API">
         <sources>
           <packageset dir="src/main/java"/>
+          <packageset dir="src/extras/main/java"/>
         </sources>
       </invoke-javadoc>
     </sequential>

Added: lucene/solr/trunk/contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template?rev=890679&view=auto
==============================================================================
--- lucene/solr/trunk/contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template
(added)
+++ lucene/solr/trunk/contrib/dataimporthandler/solr-dataimporthandler-extras-pom.xml.template
Tue Dec 15 07:49:07 2009
@@ -0,0 +1,52 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+  <!--
+    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.  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.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+  -->
+
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.solr</groupId>
+    <artifactId>solr-parent</artifactId>
+    <version>@maven_version@</version>
+  </parent>
+
+  <groupId>org.apache.solr</groupId>
+  <artifactId>solr-dataimporthandler-extras</artifactId>
+  <name>Apache Solr DataImportHandler Extras</name>
+  <version>@maven_version@</version>
+  <description>Apache Solr DataImportHandler Extras</description>
+  <packaging>jar</packaging>
+
+  <dependencies>
+    <dependency>
+      <groupId>javax.activation</groupId>
+      <artifactId>activation</artifactId>
+      <version>1.1</version>
+    </dependency>
+    <dependency>
+      <groupId>javax.mail</groupId>
+      <artifactId>mail</artifactId>
+      <version>1.4.1</version>
+    </dependency>
+  </dependencies>
+
+</project>

Propchange: lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/MailEntityProcessor.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: lucene/solr/trunk/contrib/dataimporthandler/src/extras/main/java/org/apache/solr/handler/dataimport/TikaEntityProcessor.java
------------------------------------------------------------------------------
    svn:keywords = Id

Propchange: lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestMailEntityProcessor.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Copied: lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
(from r890676, lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java)
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java?p2=lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java&p1=lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java&r1=890676&r2=890679&rev=890679&view=diff
==============================================================================
--- lucene/solr/trunk/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
(original)
+++ lucene/solr/trunk/contrib/dataimporthandler/src/extras/test/java/org/apache/solr/handler/dataimport/TestTikaEntityProcessor.java
Tue Dec 15 07:49:07 2009
@@ -48,7 +48,7 @@
             "<dataConfig>" +
                     "  <dataSource name=\"binary\" type=\"BinFileDataSource\"/>" +
                     "  <document>" +
-                    "    <entity processor=\"TikaEntityProcessor\" url=\"../../../../extraction/src/test/resources/solr-word.pdf\"
dataSource=\"binary\">" +
+                    "    <entity processor=\"TikaEntityProcessor\" url=\"../../../../../extraction/src/test/resources/solr-word.pdf\"
dataSource=\"binary\">" +
                     "      <field column=\"Author\" meta=\"true\" name=\"author\"/>"
+
                     "      <field column=\"title\" meta=\"true\" name=\"docTitle\"/>"
+
                     "      <field column=\"text\"/>" +



Mime
View raw message