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

distance_feature queries get their boost applied twice #63691

Closed
nik9000 opened this issue Oct 14, 2020 · 1 comment · Fixed by #63767
Closed

distance_feature queries get their boost applied twice #63691

nik9000 opened this issue Oct 14, 2020 · 1 comment · Fixed by #63767
Assignees
Labels
>bug :Search/Search Search-related issues that do not fall into other categories Team:Search Meta label for search team

Comments

@nik9000
Copy link
Member

nik9000 commented Oct 14, 2020

It looks to me like we wrap distance_feature queries in boost at the query builder layer and Lucene also wraps them lower down. Check out #63638.

@nik9000 nik9000 added >bug :Search/Search Search-related issues that do not fall into other categories needs:triage Requires assignment of a team area label labels Oct 14, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search (:Search/Search)

@elasticmachine elasticmachine added the Team:Search Meta label for search team label Oct 14, 2020
@mayya-sharipova mayya-sharipova self-assigned this Oct 15, 2020
mayya-sharipova added a commit to mayya-sharipova/elasticsearch that referenced this issue Oct 15, 2020
Currently if distance_feature query contains boost,
it incorrectly  gets applied twice: in AbstractQueryBuilder::toQuery and
we also pass this boost to Lucene's LongPoint.newDistanceFeatureQuery.
As a result we get incorrect scores.

This fixes this error to ensure that boost is applied only once.

Closes elastic#63691
@mayya-sharipova mayya-sharipova removed the needs:triage Requires assignment of a team area label label Oct 15, 2020
mayya-sharipova added a commit that referenced this issue Oct 16, 2020
Currently if distance_feature query contains boost,
it incorrectly  gets applied twice: in AbstractQueryBuilder::toQuery and
we also pass this boost to Lucene's LongPoint.newDistanceFeatureQuery.
As a result we get incorrect scores.

This fixes this error to ensure that boost is applied only once.

Closes #63691
mayya-sharipova added a commit that referenced this issue Oct 16, 2020
Currently if distance_feature query contains boost,
it incorrectly  gets applied twice: in AbstractQueryBuilder::toQuery and
we also pass this boost to Lucene's LongPoint.newDistanceFeatureQuery.
As a result we get incorrect scores.

This fixes this error to ensure that boost is applied only once.

Closes #63691
mayya-sharipova added a commit that referenced this issue Oct 16, 2020
Currently if distance_feature query contains boost,
it incorrectly  gets applied twice: in AbstractQueryBuilder::toQuery and
we also pass this boost to Lucene's LongPoint.newDistanceFeatureQuery.
As a result we get incorrect scores.

This fixes this error to ensure that boost is applied only once.

Closes #63691
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Search/Search Search-related issues that do not fall into other categories Team:Search Meta label for search team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants