Skip to content
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

Function score multi values #5940

Closed
wants to merge 11 commits into from

Conversation

brwe
Copy link
Contributor

@brwe brwe commented Apr 25, 2014

Decay functions currently only use the first value in a field that contains
multiple values to compute the distance to the origin. Instead, they should
consider all distances if more values are in the field and then use
one of min/max/sum/avg which is defined by the user.

closes #3960

@@ -36,6 +36,7 @@
import org.elasticsearch.index.fielddata.GeoPointValues;
import org.elasticsearch.index.fielddata.IndexGeoPointFieldData;
import org.elasticsearch.index.fielddata.IndexNumericFieldData;
import org.elasticsearch.index.fielddata.fieldcomparator.SortMode;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should now move this mode into a util class maybe in org.elasticsearch.search.MultiValueMode

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

brwe and others added 11 commits April 25, 2014 14:07
@brwe
Copy link
Contributor Author

brwe commented Apr 25, 2014

Thanks for the quick review! I updated the branch, added a commit for each comment.

@brwe brwe added the review label Apr 25, 2014
@brwe brwe self-assigned this Apr 25, 2014
@jpountz
Copy link
Contributor

jpountz commented Apr 25, 2014

LGTM.

@s1monw
Copy link
Contributor

s1monw commented Apr 25, 2014

LGTM

@s1monw s1monw closed this in f285ffc Apr 28, 2014
s1monw added a commit that referenced this pull request Apr 28, 2014
Decay functions currently only use the first value in a field that contains
multiple values to compute the distance to the origin. Instead, it should
consider all distances if more values are in the field and then use
one of min/max/sum/avg which is defined by the user.

Relates to #3960
closes #5940
@brwe brwe removed the review label Apr 28, 2014
@kimchy kimchy added the feature label Apr 28, 2014
@clintongormley clintongormley added :Search/Search Search-related issues that do not fall into other categories and removed :Query DSL labels Feb 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>feature :Search/Search Search-related issues that do not fall into other categories v1.2.0 v2.0.0-beta1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

function_score should throw exception if decay function is used with multi valued field
5 participants