-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove setNextScore in SearchScript. #6864
Conversation
import java.util.Map; | ||
|
||
public class ScriptScoreFunction extends ScoreFunction { | ||
|
||
static class CannedScorer extends Scorer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this class be final?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, done.
I left some comments... look good in general |
LGTM, we should make sure we fix mvel as well, not just groovy |
@kimchy Mvel it removed in master that is why it's not in the PR it's still on 1.x so I guess ryan is fixing it once he is porting the commit |
While it would be nice to do this all the way up the chain (into score functions), this at least removes the weird dual setNextScore/setScorer for SearchScripts.
Yes, I will fix mvel in 1.x when I backport to there. |
While it would be nice to do this all the way up the chain (into score functions), this at least removes the weird dual setNextScore/setScorer for SearchScripts. closes #6864
…er script engines to use. With the removal of setNextScore in elastic#6864, script engines must use the Scorer to find the score of a document. The DocLookup is updated appropriately to do this, but most script engines require a Number to be bound for numeric variables. Groovy already had an encapsulation for this funtionality, and this moves it out to be shared with other script engines.
With the removal of setNextScore in #6864, script engines must use the Scorer to find the score of a document. The DocLookup is updated appropriately to do this, but most script engines require a Number to be bound for numeric variables. Groovy already had an encapsulation for this funtionality, and this moves it out to be shared with other script engines. closes #6898
With the removal of setNextScore in #6864, script engines must use the Scorer to find the score of a document. The DocLookup is updated appropriately to do this, but most script engines require a Number to be bound for numeric variables. Groovy already had an encapsulation for this funtionality, and this moves it out to be shared with other script engines. closes #6898
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #23. (cherry picked from commit 5e5c373)
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #23.
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #23. (cherry picked from commit 5e5c373)
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #16. Closes #21.
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #16. Closes #21. (cherry picked from commit cd7756c)
Due to a change in elasticsearch 1.4.0, we need to apply a similar patch here. See elastic/elasticsearch#6864 See elastic/elasticsearch#7819 Closes #16. Closes #21. (cherry picked from commit cd7756c)
While it would be nice to do this all the way up the chain (into
score functions), this at least removes the weird dual
setNextScore/setScorer for SearchScripts.