[
https://issues.apache.org/jira/browse/SOLR-5707?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hoss Man updated SOLR-5707:
---------------------------
Attachment: SOLR-5707_vsp.patch
The new SOLR-5707_vsp.patch I just posted heads down the route I mentioned
before of implementing exprssions using a ValueSourceParser. From what i can
tell, this new patch provides the same level of functionality as Ryan's
previous "ComputedField" based patch (i was able to re-use most of his tests
with just some minor tweaks to the syntax) but is (in my option) a cleaner
approach, and leaves us more room to move forward with uesful things like:
* easily using request params in bindings
* dynamicly specified expressions (which can be compiled & cached if they are
reused)
At present there are a handful of nocommit's in the patch along 3 general lines:
* more javadocs
* more tests - in particular, ryan's patch had more tests of bad-config & error
cases - my patch definitely needs beefed up in that area
* forcing "wantsScore" so expressions used in "fl" can depend on score.
This last item is problem ryan noted in his patch as well -- it's no worse with
the new ValueSource approach, but it's also no better...
Solr currently decides if/when it needs to compte scores based on the
ReturnField class - which decides based on whether "score" is in the "fl". So
at present, if you wnat to put an expression in the "fl" that depends on score,
it won't work unless you also put "score" in the "fl". I have some ideas on
how on a generalized improvement to make this better, but it's non trivial, and
i'm not sure if it should block this issue or if folks think the current
situation is an acceptible workarround and we can tackle simplifying the score
case later?
In any case - i wnated to get this patch up for folks to look at before
investing a lot more time in polishing it.
[~rjernst]: what do you think of this approach?
> Lucene Expressions in Solr
> --------------------------
>
> Key: SOLR-5707
> URL: https://issues.apache.org/jira/browse/SOLR-5707
> Project: Solr
> Issue Type: New Feature
> Reporter: Ryan Ernst
> Attachments: SOLR-5707.patch, SOLR-5707_vsp.patch
>
>
> Expressions should be available for use in Solr.
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]