Skip to content

Undefined method 'logger' after update to elasticsearch gem v7.14.0 #998

Closed
@edariedl

Description

@edariedl

Hi, after upgrading to elasticsearch gem 7.14.0, I started to get errors when creating and deleting indexes in test setups. I suppose it is caused by changes in elasticsearch-transport https://github.com/elastic/elasticsearch-ruby/releases/tag/v7.14.0

Here is the stack trace:

Error:
MyTest#test_should_send_email:
NoMethodError: undefined method `logger' for #<Elasticsearch::Transport::Client:0x000055ba65120a50>
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/elasticsearch-model-7.1.1/lib/elasticsearch/model/indexing.rb:293:in `rescue in delete_index!'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/elasticsearch-model-7.1.1/lib/elasticsearch/model/indexing.rb:289:in `delete_index!'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/elasticsearch-model-7.1.1/lib/elasticsearch/model/indexing.rb:248:in `create_index!'
    /home/circleci/project/test/test_helper.rb:49:in `block (2 levels) in <class:TestCase>'
    /home/circleci/project/test/test_helper.rb:47:in `each'
    /home/circleci/project/test/test_helper.rb:47:in `block in <class:TestCase>'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/test_case.rb:111:in `block in parallelize_setup'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization/worker.rb:79:in `block in after_fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization/worker.rb:78:in `each'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization/worker.rb:78:in `after_fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization/worker.rb:24:in `block in start'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/fork_tracker.rb:10:in `block in fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/fork_tracker.rb:8:in `fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/fork_tracker.rb:8:in `fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/fork_tracker.rb:27:in `fork'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization/worker.rb:15:in `start'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization.rb:37:in `block in start'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization.rb:36:in `times'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization.rb:36:in `each'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization.rb:36:in `map'
    /home/circleci/project/vendor/bundle/ruby/2.6.0/gems/activesupport-6.1.4/lib/active_support/testing/parallelization.rb:36:in `start'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions