MrDys / blacklight

Blacklight Plugin
http://projectblacklight.org/
Other
1 stars 1 forks source link

Add Solr response context to each SolrDocument instance #474

Closed MrDys closed 12 years ago

MrDys commented 12 years ago

CODEBASE-289: The second, optional parameter to RSolr::Ext::Model (which is the base class for Blacklight's SolrDocument) is the solr response context [1], which allows the SolrDocument access to things like highlighting and more like this. I propose to add this to our solr helper methods [2], but am slightly concerned this could introduce unnecessary overhead for those who might not take advantage of this.

While I probably can make this configurable (using some helper method, presumably), I thought I should first check if anyone is actually concerned? Unless someone -1s this proposal after the committers call next week, I'll just go ahead and make the changes and we can back them out later if needed.

Chris

[1] https://github.com/mwmitchell/rsolr-ext/blob/master/lib/rsolr-ext/model.rb#L96 [2] https://github.com/projectblacklight/blacklight/blob/master/lib/blacklight/solr_helper.rb#L208 , https://github.com/projectblacklight/blacklight/blob/master/lib/blacklight/solr_helper.rb#L233 , https://github.com/projectblacklight/blacklight/blob/master/lib/blacklight/solr_helper.rb#L248

MrDys commented 12 years ago

Original reporter: cbeer

MrDys commented 12 years ago

cbeer: Fixed in commit https://github.com/projectblacklight/blacklight/commit/0303489286fccc9f27e14ef93a109210d6f75ef5