Skip to content

Fix README elasticsearch-model #764

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 3, 2019

Conversation

katsuhisa91
Copy link
Contributor

I found an inconsistency method name, inside README of elasticsearch-model's Asynchronous Callbacks section.

You wrote Article Model file as below.

class Article
  include Elasticsearch::Model

  after_save    { Indexer.perform_async(:index,  self.id) }
  after_destroy { Indexer.perform_async(:delete, self.id) }
end

But, you wrote example implementation of the Indexer worker class as below.

class Indexer
  include Sidekiq::Worker
  sidekiq_options queue: 'elasticsearch', retry: false
  ...]
  def perform(operation, record_id)
    ...]
  end
end

I think we should fix Indexer worker class's method name from perform to perform_async.

@katsuhisa91 katsuhisa91 changed the title fix README elasticsearch-model Fix README elasticsearch-model Dec 18, 2017
@estolfo estolfo merged commit 26e4cf8 into elastic:master May 3, 2019
@estolfo
Copy link
Contributor

estolfo commented May 3, 2019

@katsuhisa91 thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants