tika-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (TIKA-1507) Under OSGi, ForkParser failes to send core parser classes like ExternalParser
Date Wed, 04 Nov 2015 04:54:27 GMT

    [ https://issues.apache.org/jira/browse/TIKA-1507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14988874#comment-14988874
] 

Hudson commented on TIKA-1507:
------------------------------

SUCCESS: Integrated in tika-trunk-jdk1.7 #880 (See [https://builds.apache.org/job/tika-trunk-jdk1.7/880/])
TIKA-1507 - Moved tika-external-parsers.xml to tika-core to prevent OSGi split package issue.
(bob: [http://svn.apache.org/viewvc/tika/trunk/?view=rev&rev=1712462])
* trunk/tika-bundle/src/test/java/org/apache/tika/bundle/BundleIT.java
* trunk/tika-bundle/src/test/resources/testOCR.jpg
* trunk/tika-core/src/main/resources/org/apache/tika/parser
* trunk/tika-core/src/main/resources/org/apache/tika/parser/external
* trunk/tika-core/src/main/resources/org/apache/tika/parser/external/tika-external-parsers.xml
* trunk/tika-parsers/src/main/java/org/apache/tika/parser/ocr/TesseractOCRParser.java
* trunk/tika-parsers/src/main/resources/org/apache/tika/parser/external


> Under OSGi, ForkParser failes to send core parser classes like ExternalParser
> -----------------------------------------------------------------------------
>
>                 Key: TIKA-1507
>                 URL: https://issues.apache.org/jira/browse/TIKA-1507
>             Project: Tika
>          Issue Type: Bug
>          Components: packaging, parser
>    Affects Versions: 1.6, 1.7
>            Reporter: Nick Burch
>            Assignee: Bob Paulin
>             Fix For: 1.12
>
>         Attachments: TIKA-1507C.patch
>
>
> Under OSGi, if you try to use ForkParser with the Tesseract OCR parser, it will fail
with:
> java.lang.NoClassDefFoundError: org/apache/tika/parser/external/ExternalParser
> 	at org.apache.tika.parser.ocr.TesseractOCRParser.hasTesseract(TesseractOCRParser.java:117)
> 	at org.apache.tika.parser.ocr.TesseractOCRParser.getSupportedTypes(TesseractOCRParser.java:91)
> 	at org.apache.tika.parser.CompositeParser.getParsers(CompositeParser.java:81)
> 	at org.apache.tika.parser.DefaultParser.getParsers(DefaultParser.java:95)
> 	at org.apache.tika.parser.CompositeParser.getParser(CompositeParser.java:209)
> 	at org.apache.tika.parser.CompositeParser.parse(CompositeParser.java:244)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:622)
> 	at org.apache.tika.fork.ForkServer.call(ForkServer.java:144)
> 	at org.apache.tika.fork.ForkServer.processRequests(ForkServer.java:124)
> 	at org.apache.tika.fork.ForkServer.main(ForkServer.java:69)
> Caused by: java.lang.ClassNotFoundException: Unable to find class org.apache.tika.parser.external.ExternalParser
> 	at org.apache.tika.fork.ClassLoaderProxy.findClass(ClassLoaderProxy.java:117)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:323)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
> 	... 13 more
> ExternalParser lives in the Tika Core jar, not the Tika Parsers one. This all works fine
outside of OSGi, so it looks like something about the OSGi bundling is causing the fork parser
to fail to send the parser-related classes from Tika Core over to the forked JVM



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message