【问题标题】:Tika exception error while indexing rich documents rails 3索引丰富文档时出现Tika异常错误rails 3
【发布时间】:2012-09-27 11:07:00
【问题描述】:

我只是使用 sunspot_cell 在富文档中实现全文搜索。 我正在使用回形针作为附件。

我已经完成了所有必需的配置,并将所有 *.jar 文件包含在 solr/lib 目录中。 但它无法索引文档。 我收到以下 Tika 异常错误:

RSolr::Error::Http (RSolr::Error::Http - 500 Internal Server Error
Error:     org.apache.tika.exception.TikaException: Unexpected RuntimeException from org.apache.tika.parser.pdf.PDFParser@17fc44f
org.apache.solr.common.SolrException: org.apache.tika.exception.TikaException: Unexpected RuntimeException from org.apache.tika.parser.pdf.PDFParser@17fc44f
    at org.apache.solr.handler.extraction.ExtractingDocumentLoader.load(ExtractingDocumentLoader.java:219)
    at org.apache.solr.handler.ContentStreamHandlerBase.handleRequestBody(ContentStreamHandlerBase.java:58)
    at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:129)
    at org.apache.solr.core.RequestHandlers$LazyRequestHandlerWrapper.handleRequest(RequestHandlers.java:241)
    at org.apache.solr.core.SolrCore.execute(SolrCore.java:1372)
    at org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:356)
    at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:252)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)

我的 Gemfile 看起来像

gem 'sunspot', :git => "git://github.com/sunspot/sunspot.git"
gem 'sunspot_rails', :git => "git://github.com/sunspot/sunspot.git", :require =>  "sunspot_rails"
gem 'sunspot_test'
gem 'sunspot_cell', :git => 'git://github.com/zheileman/sunspot_cell.git'

group :development, :test do
  gem 'sunspot_cell_jars', :git => 'https://github.com/mrcsparker/sunspot_cell_jars.git'
  gem 'sunspot_solr', :git => "git://github.com/sunspot/sunspot.git", :require => "sunspot_solr"
  gem 'progress_bar'
end

对此的任何解决方案。

问候, 卡兰

【问题讨论】:

    标签: ruby-on-rails-3 sunspot-solr apache-tika


    【解决方案1】:

    这似乎不合逻辑,但不知何故我能够找到解决方案。

    尝试使用 Web-rick 运行您的开发服务器,而不是任何其他的 eg:thin 它将开始工作。:)

    【讨论】:

      猜你喜欢
      • 2017-10-18
      • 1970-01-01
      • 2019-01-30
      • 2013-09-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多