[
https://issues.apache.org/jira/browse/NUTCH-2457?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16255550#comment-16255550
]
Tim Allison commented on NUTCH-2457:
------------------------------------
So, in lieu of a PR...please, please, please use the AutoDetectParser, like so:
{noformat}
+ Parser p = new AutoDetectParser(tikaConfig);
- Parser parser = tikaConfig.getParser(MediaType.parse(mimeType));
{noformat}
Your current method won't parse embedded documents/attachments.
Unit test: test that the extracted string contains "When in the Course of human
events" on the file that I linked in the description.
> Embedded documents likely not correctly parsed by Tika
> ------------------------------------------------------
>
> Key: NUTCH-2457
> URL: https://issues.apache.org/jira/browse/NUTCH-2457
> Project: Nutch
> Issue Type: Bug
> Reporter: Tim Allison
>
> While working on TIKA-2490, I think I found that Nutch's current method of
> requesting a mime-specific parser for each file will fail to parse embedded
> files, e.g.
> https://github.com/apache/tika/blob/master/tika-server/src/test/resources/test_recursive_embedded.docx
> The fix should be straightforward, and I'll submit a PR once I can get Nutch
> up and running in my dev environment.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)