1
我正在嘗試爲項目設置新的生產服務器,但在配置elasticsearch時遇到問題。當我嘗試做進口從鐵軌控制檯我得到一個模型(*** - >變灰):彈性搜索錯誤請求 - 找不到處理程序的處理程序
Elasticsearch::Transport::Transport::Errors::BadRequest: [400] No handler found for uri [//***/***/_bulk?type=***] and method [POST]
from /***/gems/elasticsearch-transport-1.0.12/lib/elasticsearch/transport/transport/base.rb:135:in `__raise_transport_error'
from /***/elasticsearch-transport-1.0.12/lib/elasticsearch/transport/transport/base.rb:227:in `perform_request'
from /***/elasticsearch-transport-1.0.12/lib/elasticsearch/transport/transport/http/faraday.rb:20:in `perform_re
我的初始化文件看起來像:
config = {
host: 'http://localhost:9200/',
transport_options: {
request: { timeout: 5 }
}
}
if File.exist?('config/elasticsearch.yml')
config.merge! (YAML.load_file('config/elasticsearch.yml').symbolize_keys)
end
Elasticsearch::Model.client = Elasticsearch::Client.new(config)
我用Elasticsearch版本5.3.0
也許這個問題會有所幫助:http://stackoverflow.com/questions/35025401/no-handler-found-for-uri-index-type-和方法,把 –