Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ruby-on-rails/56.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/heroku/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ruby on rails 韦伯索尔+;赫罗库+;用db:seed自动完成太阳黑子_Ruby On Rails_Heroku_Solr_Websolr - Fatal编程技术网

Ruby on rails 韦伯索尔+;赫罗库+;用db:seed自动完成太阳黑子

Ruby on rails 韦伯索尔+;赫罗库+;用db:seed自动完成太阳黑子,ruby-on-rails,heroku,solr,websolr,Ruby On Rails,Heroku,Solr,Websolr,我正在Heroku上安装我的应用程序。已经安装了20美元的websolr插件。迁移已经运行 运行heroku rake db:seed时,我得到以下错误 你知道这是什么原因吗 $ heroku run rake db:seed RSolr::Error::Http - 400 Bad Request Error: <html><head><title>Apache Tomcat/6.0.28 - Error report</title><st

我正在Heroku上安装我的应用程序。已经安装了20美元的websolr插件。迁移已经运行

运行heroku rake db:seed时,我得到以下错误

你知道这是什么原因吗

$ heroku run rake db:seed
RSolr::Error::Http - 400 Bad Request
Error: <html><head><title>Apache Tomcat/6.0.28 - Error report</title><style><!--H1 {font-    family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status     400 - ERROR: [doc=Dvd 2] unknown field 'dvd_title_as'</h1><HR size="1" noshade="noshade"><p>    <b>type</b> Status report</p><p><b>message</b> <u>ERROR: [doc=Dvd 2] unknown field     'dvd_title_as'</u></p><p><b>description</b> <u>The request sent by the client was     syntactically incorrect (ERROR: [doc=Dvd 2] unknown field 'dvd_title_as').</u></p><HR size="1"     noshade="noshade"><h3>Apache Tomcat/6.0.28</h3></body></html>

Request Data: "<?xml version=\"1.0\" encoding=\"UTF-8\"?><add><doc><field name=\"id\">Dvd 2</field><field name=\"type\">Dvd</field><field name=\"type\">ActiveRecord::Base</field><field name=\"class_name\">Dvd</field><field name=\"featured_b\">false</field><field name=\"dvd_title_as\">100% Dirty Slut</field><field name=\"title_text\">100% Dirty Slut</field><field name=\"studio_text\">Cherry Boxxx</field></doc></add>"

Backtrace: /app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:230:in `adapt_response'
/app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:167:in `execute'
/app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:161:in     `send_and_receive'
(eval):2:in `post'
/app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:67:in `update'
/app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:87:in `add'
/app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/indexer.rb:101:in `add_documents'
/app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/indexer.rb:26:in `add'
/app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/session.rb:91:in `index'
/app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/session_proxy/abstract_session_proxy.rb:11:in `index'
/app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot.rb:184:in `index'

Tasks: TOP => db:seed
(See full trace by running task with --trace)
$heroku运行rake db:seed
RSolr::Error::Http-400错误请求
错误:Apache Tomcat/6.0.28-错误报告HTTP状态400-错误:[doc=Dvd 2]未知字段“Dvd_title_as”
类型状态报告消息错误:[doc=Dvd 2]未知字段“Dvd_title_as”

说明客户端发送的请求语法不正确(错误:[doc=Dvd 2]未知字段“dvd\u title\u as”)。


Apache Tomcat/6.0.28 请求数据:“Dvd 2DvdActiveRecord::BaseDVD False100%脏泥浆100%脏泥浆箱XX” 回溯:/app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:230:in'adapt_response' /app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:167:in'execute' /app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:161:in'send_and_receive' (评估):2:在“post”中 /app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:67:in'update' /app/vendor/bundle/ruby/1.9.1/gems/rsolr-1.0.8/lib/rsolr/client.rb:87:in'add' /app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/indexer.rb:101:在“添加文档”中 /app/vendor/bundle/ruby/1.9.1/gems/sunsspot-1.3.3/lib/sunsspot/indexer.rb:26:in'add' /app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot/session.rb:91:in'index' /app/vendor/bundle/ruby/1.9.1/gems/sunsspot-1.3.3/lib/sunsspot/session\u proxy/abstract\u session\u proxy.rb:11:in'index' /app/vendor/bundle/ruby/1.9.1/gems/sunspot-1.3.3/lib/sunspot.rb:184:in'index' 任务:TOP=>db:seed (通过使用--trace运行任务查看完整跟踪)
我建议访问help.websolr.com并填写支持请求。

HTML响应中隐藏的错误消息是
未知字段“dvd\u title\u as”

基本上,应用程序发送给Solr的文档没有在
schema.xml
中定义。您可能需要使用应用程序的最新架构更新您的websolr索引,您可以使用
heroku插件打开仪表板:open websolr