Four Tips on Designing SOLR Schema
However similar SOLR to a database, designing schema for each of them has a distinct difference.
- SOLR is optimized to search purpose, on the other hand, database was commonly design to store (related) data
- SOLR has a custom behaviour when storing and querying data, ie: indexing behaviour and query behaviour.
So how is it to design schema in SOLR?
- Cover all basic data. Make sure to index everything you need to search onto. Indexing more data won’t hurt, storage is cheap.
- Cover common search behaviour. Do you search over several fields? Dismax query type sometime does fit your need as it is searching word by word. Store in one field or multifield? Or both? SOLR has copyField feature.You can use it for store concatenated values.
- Work on the relevancy and scoring. Setup proper score boosting to your search query. You may found a necessity to ignore score or to use FunctionQuery to tweak scoring or filling a “formula” field, ie: linear, product, sum, etc.
- Practise make perfect. Gather feedback from your users, check what search is work and what is not.
FAQ (to be answered soon):
- Why SOLR, is database not enough?
- Would it be fair to compare database to Lucene?
Photo by estherase
Sphere: Related Content
Related entries:
- Going Vertical with SOLR: Apa sih SOLR itu?
- Ideas: Selling custom search (using SOLR)
- Lebih jauh dengan (bisnis dan) SOLR
- One Post Per Day: When The Going Gets Tough
2008
20
Aug
- Posted by Akhmad Fathonih at 08:51 am
- Permalink for this entry
- Filed under: Dev Hours, One Post Per Day
- RSS comments feed of this entry
- TrackBack URI









No comments
Leave a comment