Details

    • Type: Sub-task
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.12
    • Fix Version/s: 1.12
    • Component/s: parser
    • Labels:
      None
    • Environment:

      All

      Description

      While using TIKA-server we observed that GeoTopic parser started holding state and returned all the location retrieved for any previous request.

      This was happening as mutable object org.apache.tika.parser.geo.topic.NameEntityExtractor was initialised once and then was reused by all request.

      As part of this fix org.apache.tika.parser.geo.topic.NameEntityExtractor is recreated for every request.

        Activity

        Hide
        githubbot ASF GitHub Bot added a comment -

        GitHub user smadha opened a pull request:

        https://github.com/apache/tika/pull/71

        fix for TIKA-1834 contributed by msharan@usc.edu

        You can merge this pull request into a Git repository by running:

        $ git pull https://github.com/smadha/tika TIKA-1834

        Alternatively you can review and apply these changes as the patch at:

        https://github.com/apache/tika/pull/71.patch

        To close this pull request, make a commit to your master/trunk branch
        with (at least) the following in the commit message:

        This closes #71


        commit 0154e3067c8a63ab176e4e2161515d2d7d45b8e7
        Author: smadha <msharan@usc.edu>
        Date: 2016-01-18T18:08:18Z

        fix for TIKA-1834 contributed by msharan@usc.edu


        Show
        githubbot ASF GitHub Bot added a comment - GitHub user smadha opened a pull request: https://github.com/apache/tika/pull/71 fix for TIKA-1834 contributed by msharan@usc.edu You can merge this pull request into a Git repository by running: $ git pull https://github.com/smadha/tika TIKA-1834 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/tika/pull/71.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #71 commit 0154e3067c8a63ab176e4e2161515d2d7d45b8e7 Author: smadha <msharan@usc.edu> Date: 2016-01-18T18:08:18Z fix for TIKA-1834 contributed by msharan@usc.edu
        Hide
        chrismattmann Chris A. Mattmann added a comment -

        tests pass, and patch applies fine, will commit now! thanks Madhav Sharan!

        Show
        chrismattmann Chris A. Mattmann added a comment - tests pass, and patch applies fine, will commit now! thanks Madhav Sharan !
        Hide
        chrismattmann Chris A. Mattmann added a comment -
        [INFO] --- maven-bundle-plugin:2.3.4:install (default-install) @ tika-java7 ---
        [INFO] Installing org/apache/tika/tika-java7/1.12-SNAPSHOT/tika-java7-1.12-SNAPSHOT.jar
        [INFO] Writing OBR metadata
        [INFO]                                                                         
        [INFO] ------------------------------------------------------------------------
        [INFO] Building Apache Tika 1.12-SNAPSHOT
        [INFO] ------------------------------------------------------------------------
        [INFO] 
        [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ tika ---
        [INFO] 
        [INFO] --- maven-remote-resources-plugin:1.5:process (default) @ tika ---
        [INFO] 
        [INFO] --- maven-site-plugin:3.4:attach-descriptor (attach-descriptor) @ tika ---
        [INFO] 
        [INFO] --- forbiddenapis:2.0:check (default) @ tika ---
        [INFO] Skipping execution for packaging "pom"
        [INFO] 
        [INFO] --- forbiddenapis:2.0:testCheck (default) @ tika ---
        [INFO] Skipping execution for packaging "pom"
        [INFO] 
        [INFO] --- maven-install-plugin:2.5.2:install (default-install) @ tika ---
        [INFO] Installing /Users/mattmann/tmp/tika1.12/pom.xml to /Users/mattmann/.m2/repository/org/apache/tika/tika/1.12-SNAPSHOT/tika-1.12-SNAPSHOT.pom
        [INFO] ------------------------------------------------------------------------
        [INFO] Reactor Summary:
        [INFO] 
        [INFO] Apache Tika parent ................................. SUCCESS [  1.875 s]
        [INFO] Apache Tika core ................................... SUCCESS [ 19.173 s]
        [INFO] Apache Tika parsers ................................ SUCCESS [03:51 min]
        [INFO] Apache Tika XMP .................................... SUCCESS [  3.680 s]
        [INFO] Apache Tika serialization .......................... SUCCESS [  1.956 s]
        [INFO] Apache Tika batch .................................. SUCCESS [02:03 min]
        [INFO] Apache Tika application ............................ SUCCESS [ 41.319 s]
        [INFO] Apache Tika OSGi bundle ............................ SUCCESS [ 25.187 s]
        [INFO] Apache Tika translate .............................. SUCCESS [  2.478 s]
        [INFO] Apache Tika server ................................. SUCCESS [ 29.457 s]
        [INFO] Apache Tika examples ............................... SUCCESS [ 19.309 s]
        [INFO] Apache Tika Java-7 Components ...................... SUCCESS [  2.733 s]
        [INFO] Apache Tika ........................................ SUCCESS [  0.039 s]
        [INFO] ------------------------------------------------------------------------
        [INFO] BUILD SUCCESS
        [INFO] ------------------------------------------------------------------------
        [INFO] Total time: 08:22 min
        [INFO] Finished at: 2016-01-18T10:37:40-08:00
        [INFO] Final Memory: 124M/1724M
        [INFO] ------------------------------------------------------------------------
        [chipotle:~/tmp/tika1.12] mattmann% 
        
        Show
        chrismattmann Chris A. Mattmann added a comment - [INFO] --- maven-bundle-plugin:2.3.4:install (default-install) @ tika-java7 --- [INFO] Installing org/apache/tika/tika-java7/1.12-SNAPSHOT/tika-java7-1.12-SNAPSHOT.jar [INFO] Writing OBR metadata [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Building Apache Tika 1.12-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ tika --- [INFO] [INFO] --- maven-remote-resources-plugin:1.5:process (default) @ tika --- [INFO] [INFO] --- maven-site-plugin:3.4:attach-descriptor (attach-descriptor) @ tika --- [INFO] [INFO] --- forbiddenapis:2.0:check (default) @ tika --- [INFO] Skipping execution for packaging "pom" [INFO] [INFO] --- forbiddenapis:2.0:testCheck (default) @ tika --- [INFO] Skipping execution for packaging "pom" [INFO] [INFO] --- maven-install-plugin:2.5.2:install (default-install) @ tika --- [INFO] Installing /Users/mattmann/tmp/tika1.12/pom.xml to /Users/mattmann/.m2/repository/org/apache/tika/tika/1.12-SNAPSHOT/tika-1.12-SNAPSHOT.pom [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Apache Tika parent ................................. SUCCESS [ 1.875 s] [INFO] Apache Tika core ................................... SUCCESS [ 19.173 s] [INFO] Apache Tika parsers ................................ SUCCESS [03:51 min] [INFO] Apache Tika XMP .................................... SUCCESS [ 3.680 s] [INFO] Apache Tika serialization .......................... SUCCESS [ 1.956 s] [INFO] Apache Tika batch .................................. SUCCESS [02:03 min] [INFO] Apache Tika application ............................ SUCCESS [ 41.319 s] [INFO] Apache Tika OSGi bundle ............................ SUCCESS [ 25.187 s] [INFO] Apache Tika translate .............................. SUCCESS [ 2.478 s] [INFO] Apache Tika server ................................. SUCCESS [ 29.457 s] [INFO] Apache Tika examples ............................... SUCCESS [ 19.309 s] [INFO] Apache Tika Java-7 Components ...................... SUCCESS [ 2.733 s] [INFO] Apache Tika ........................................ SUCCESS [ 0.039 s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 08:22 min [INFO] Finished at: 2016-01-18T10:37:40-08:00 [INFO] Final Memory: 124M/1724M [INFO] ------------------------------------------------------------------------ [chipotle:~/tmp/tika1.12] mattmann%
        Hide
        githubbot ASF GitHub Bot added a comment -

        Github user asfgit closed the pull request at:

        https://github.com/apache/tika/pull/71

        Show
        githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/tika/pull/71
        Hide
        chrismattmann Chris A. Mattmann added a comment -

        applied in trunk!

        [chipotle:~/tmp/tika1.12] mattmann% svn commit -m "Fix for TIKA-1834: Fix for GeoTopic parser holding state while running Tika server contributed by smadha <msharan@usc.edu> this closes #71."
        Sending        CHANGES.txt
        Sending        tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/GeoParser.java
        Sending        tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/NameEntityExtractor.java
        Transmitting file data ...
        Committed revision 1725318.
        [chipotle:~/tmp/tika1.12] mattmann% 
        
        Show
        chrismattmann Chris A. Mattmann added a comment - applied in trunk! [chipotle:~/tmp/tika1.12] mattmann% svn commit -m "Fix for TIKA-1834: Fix for GeoTopic parser holding state while running Tika server contributed by smadha <msharan@usc.edu> this closes #71." Sending CHANGES.txt Sending tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/GeoParser.java Sending tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/NameEntityExtractor.java Transmitting file data ... Committed revision 1725318. [chipotle:~/tmp/tika1.12] mattmann%
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in tika-trunk-jdk1.7 #902 (See https://builds.apache.org/job/tika-trunk-jdk1.7/902/)
        Fix for TIKA-1834: Fix for GeoTopic parser holding state while running Tika server contributed by smadha <msharan@usc.edu> this closes #71. (mattmann: http://svn.apache.org/viewvc/tika/trunk/?view=rev&rev=1725318)

        • trunk/CHANGES.txt
        • trunk/tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/GeoParser.java
        • trunk/tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/NameEntityExtractor.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in tika-trunk-jdk1.7 #902 (See https://builds.apache.org/job/tika-trunk-jdk1.7/902/ ) Fix for TIKA-1834 : Fix for GeoTopic parser holding state while running Tika server contributed by smadha <msharan@usc.edu> this closes #71. (mattmann: http://svn.apache.org/viewvc/tika/trunk/?view=rev&rev=1725318 ) trunk/CHANGES.txt trunk/tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/GeoParser.java trunk/tika-parsers/src/main/java/org/apache/tika/parser/geo/topic/NameEntityExtractor.java

          People

          • Assignee:
            chrismattmann Chris A. Mattmann
            Reporter:
            msharan@usc.edu Madhav Sharan
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development