6.0.0
This version has many smaller changes and two major changes: the deprecation of the ActiveRecord Persistence pattern and a refactor of the Repository pattern.
This version includes all the changes in 6.0.0.pre in addition to those listed below.
Breaking Changes
- You must include the
Elasticsearch::Persistence::Repository::DSL
mixin if you'd like to define settings at the class-level for a Repository. - Settings on a Repository class and instances are immutable. For example, you cannot set a repository client with
repository.client = ....
. This is true for the following settings:document_type
index_name
klass
client
- The following methods can no longer be called on a Repository class. They must be called on instances.
create_index!
delete_index!
refresh_index!
index_exists?
- Clients must be defined explicitly for repositories. The client setting on
Elasticsearch::Persistence
is removed. This setting was previously mutable and led to unexpected behavior for repositories.
Here is a full list of changes:
ActiveModel
- Inherit from HashWrapper for disabling warnings
- Fix import method to pass index name on refresh (#692)
- Use default scope on ActiveRecord model when importing (#827)
- Support scope, query and preprocess importing options in Mongoid Adapter in 6.x (#829)
- Address performance of HashWrapper in Response objects (#825)
Persistence
- Address performance of HashWrapper in Response objects (#825)
- Minor refactor in Repository::Search
- Remove example music app that demonstrates the AR pattern
- Update Sinatra app
- Update README
- Change document type references to _doc