You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Suggestion: provide an instance method to allow fetching the indexed document if it exists.
Benefits:
This would allow comparing the indexed instance with the Rails model attributes to allow for better index updating control. i.e. do not update the index if no attributes have changed. The update_document feature does not work for async indexing as the record is reloaded from the database unless the changes hash is passed to the async worker.
This would allow integrity checking of the Rails SQL vs. the Elasticsearch for self-healing indexes if anything gets out of sync, e.g. if an async worker fails to update the index for whatever reason.
Thanks for your consideration. Is this a good idea? I will try to contribute a PR.
Maybe a simple get method on the Elasticsearch::Model::InstanceMethods?
Suggestion: provide an instance method to allow fetching the indexed document if it exists.
Benefits:
update_document
feature does not work for async indexing as the record is reloaded from the database unless the changes hash is passed to the async worker.Thanks for your consideration. Is this a good idea? I will try to contribute a PR.
Maybe a simple
get
method on theElasticsearch::Model::InstanceMethods
?The text was updated successfully, but these errors were encountered: