searchkick: connect_timeout=() does not exist for Typhoeus::Request class
Hi, I cant reindex afte install gem Typhoeus
rake searchkick:reindex CLASS=Film
rake aborted!
NoMethodError: undefined method connect_timeout=' for #<Typhoeus::Request:0x007f8a00777f90> /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/adapter/typhoeus.rb:104:in
configure_timeout’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/adapter/typhoeus.rb:47:in request' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/adapter/typhoeus.rb:22:in
perform_request’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/adapter/typhoeus.rb:14:in call' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/rack_builder.rb:139:in
build_response’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/faraday-0.9.1/lib/faraday/connection.rb:377:in run_request' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-transport-1.0.6/lib/elasticsearch/transport/transport/http/faraday.rb:21:in
block in perform_request’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-transport-1.0.6/lib/elasticsearch/transport/transport/base.rb:187:in call' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-transport-1.0.6/lib/elasticsearch/transport/transport/base.rb:187:in
perform_request’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-transport-1.0.6/lib/elasticsearch/transport/transport/http/faraday.rb:20:in perform_request' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-transport-1.0.6/lib/elasticsearch/transport/client.rb:111:in
perform_request’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-api-1.0.6/lib/elasticsearch/api/namespace/common.rb:21:in perform_request' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/elasticsearch-api-1.0.6/lib/elasticsearch/api/actions/indices/get_aliases.rb:29:in
get_aliases’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/searchkick-0.8.5/lib/searchkick/reindex.rb:42:in clean_indices' /Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/searchkick-0.8.5/lib/searchkick/reindex.rb:13:in
reindex’
/Users/yurgon/.rvm/gems/ruby-2.0.0-p481@railstutorial_rails_4_0/gems/searchkick-0.8.5/lib/searchkick/tasks.rb:10:in `block (2 levels) in <top (required)>’
Tasks: TOP => searchkick:reindex
(See full trace by running task with --trace)
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 16 (5 by maintainers)
I created an initializer called “elasticsearch.rb” and added this,
And it magically worked! Hope this helps.
Cleaning up issues.
typhoeus/adapters/faraday
is now automatically required whentyphoeus
is detected, fwiw.Able to reproduce the error if
require "typhoeus/adapters/faraday"
is not included in an initializer. I’d check if it’s that.https://github.com/ankane/searchkick#performance