David Parks
David Parks

Reputation: 32111

Solr: Boosting documents based on a numeric 'popularity' field - do it at index time or query time?

I'm reading the solr cookbook and it suggests using a boost function bf=product(popularity) parameter to boost certain documents based on the "popularity" score.

This could also be implemented using a index time boost on the document right?

So which is the better option? Is there a difference in terms of:

Upvotes: 2

Views: 1019

Answers (1)

Alexandre Rafalovitch
Alexandre Rafalovitch

Reputation: 9789

This depends on how often your popularity changes. If it is pre-baked and changes infrequently, then you can boost at index time. If it changes frequently (e.g. based on the live searches), then you probably want to store it externally to specific records, using (for example) ExternalFileField.

Upvotes: 4

Related Questions