我也必须从给定的URL抓取PDF文档...推荐任何工具/API来抓取PDF文档...现在我正在使用nutch抓取,但我不能抓取PDF从给定的URL...should我使用任何插件抓取PDF在nutch?
seed.txt --> http://nutch.apache.org regex-urlfilter.txt->+^http://([a-z0-9]*.)*nutch.apache.org/
提前感谢
发布于 2014-12-30 04:01:23
在regex-urlfilter.txt部分中添加“
”和“
”在
-
这个答案来自here。我在Nutch上工作的时候测试过它
<property>
<name>plugin.includes</name>
<value>protocol-http|urlfilter-regex|parse-(html|tika|text)|index-(basic|anchor)|scoring-opic|urlnormalizer-(pass|regex|basic)</value>
<description>
...
</description>
</property>
发布于 2016-01-28 12:51:35
我发现即使你使用了tika插件,它仍然不能抓取pdf或任何ms office文件到crawldb中。你需要在nutch-site.xml中的白名单中添加你想要抓取的url,才能得到pdf和任何ms office文件:
<property>
<name>http.robot.rules.whitelist</name>
<value>xxx.xxx.xxx.xxx</value>
<description>Comma separated list of hostnames or IP addresses to ignore
robot rules parsing for. Use with care and only if you are explicitly
allowed by the site owner to ignore the site's robots.txt!
</description>
</property>
发布于 2013-08-21 14:49:47
使用Nutch的parse-tika插件。纯文本、XML、OpenDocument (OpenOffice.org)、Microsoft Office (Word、Excel、Powerpoint)、PDF、RTF、MP3 (ID3标签)都是由Tika插件解析的
https://stackoverflow.com/questions/18054889
复制相似问题