Solarium 2.2.0 released
Solarium 2.2.0 released
Join the DZone community and get the full member experience.Join For Free
Bugsnag monitors application stability, so you can make data-driven decisions on whether you should be building new features, or fixing bugs. Learn more.
This release includes:
- Support for the MoreLikeThis handler
- Spellcheck support
- Analysis support, both document and field analysis
- Support for distributed search (sharding)
- Per-field settings for highlighting
- A PeclHttp client adapter
- Several create methods now have an auto-add option to make them easier to use
- Some delete methods that worked by key now support an object as input, again to simplify use.
- A fix for better detecting errors in ping requests (issue #46)
- A fix to the handling of headers in the ZendHttp client adapter (issue #45)
This release contains a lot of contributed work:
- Gasol contributed MoreLikeThis handler support, the PeclHttp client adapter and support for distributed search.
- theUniC contributed per-field highlighting options
- acasademont contributed the spellcheck component
- danielholmes contributed a fix for the handling of headers in the ZendHttp client adapter
Thanks a lot guys! Really nice to see Solarium being used and improved by the community.
All new features have been documented in the manual. I’ve also added new examples to the project and updated several examples to make use of new features.
I can’t describe all changes in this post, but here’s one example of a small change in 2.2.0 that will make using Solarium just a little bit easier. Adding a filterquery used to work like this:
// create a filterquery $fq = $this->createFilterQuery(); $fq->setKey('maxprice'); $fq->setQuery('price:[1 TO 300]'); // and add it $this->addFilterQuery($fq);
From now on you can use this oneliner:
$this->createFilterQuery('maxprice')->setQuery('price:[1 TO 300]');
If you supply an id to the create method it will automatically add the filterquery instance for you, so you only need to apply your settings without manually adding it. The same thing also works for facets:
Finally, the API docs are now generated using DocBlox, instead of PhpDocumenter. Therefore the layout of the API docs has changed.
Published at DZone with permission of Bas De Nooijer , DZone MVB. See the original article here.
Opinions expressed by DZone contributors are their own.