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

Truncated score when using the significat terms aggregation #32770

Closed
Blakko opened this issue Aug 10, 2018 · 2 comments · Fixed by #32774
Closed

Truncated score when using the significat terms aggregation #32770

Blakko opened this issue Aug 10, 2018 · 2 comments · Fixed by #32774

Comments

@Blakko
Copy link

Blakko commented Aug 10, 2018

When using the significant terms aggregation with the Java High Level REST Client the returned score is truncated.
What i mean is that when querying ES via API i get the correct score eg: 0.1243235, but the same query executed via the client returns a score of 0.0.

Looking at the code it feels like here

there should be

bucket.score = parser.doubleValue();
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

@markharwood
Copy link
Contributor

Thanks, good catch!

markharwood added a commit to markharwood/elasticsearch that referenced this issue Aug 10, 2018
…g parsed as long.

Added test.
Thanks for the report/fix, Blakko

Closes elastic#32770
markharwood added a commit that referenced this issue Aug 14, 2018
Significance score doubles were being parsed as long. Existing tests did not catch this because SignificantLongTermsTests and SignificantStringTermsTests did not set the score. Fixed these and also added integration test.

Thanks for the report/fix, Blakko

Closes #32770
markharwood added a commit that referenced this issue Aug 14, 2018
Significance score doubles were being parsed as long. Existing tests did not catch this because SignificantLongTermsTests and SignificantStringTermsTests did not set the score. Fixed these and also added integration test.

Thanks for the report/fix, Blakko

Closes #32770
markharwood added a commit that referenced this issue Aug 15, 2018
…nreliable.

This test is superfluous - it was added to address #32770 but it later turned out there was an existing test that just required a fix to provide the missing test coverage.

Closes #32855
markharwood added a commit that referenced this issue Aug 15, 2018
…nreliable.

This test is superfluous - it was added to address #32770 but it later turned out there was an existing test that just required a fix to provide the missing test coverage.

Closes #32855
jasontedor added a commit that referenced this issue Aug 15, 2018
* 6.x: (96 commits)
  Introduce global checkpoint listeners (#32696)
  Use JDK 10 for 6.4 BWC builds (#32866)
  Remove unused imports - follow up to removal of test in issue 32855
  Removed flaky test. Looks like randomisation makes these assertions unreliable. This test is superfluous - it was added to address #32770 but it later turned out there was an existing test that just required a fix to provide the missing test coverage.
  [test] mute IndexShardTests.testDocStats
  Test: Fix forbidden uses in test framework (#32824)
  Security: remove password hash bootstrap check (#32440)
  Move validation to server for put user requests (#32471)
  [ML] Add high level REST client docs for ML put job endpoint (#32843)
  Painless: Change fqn_only to no_import (#32817)
  [test] mute testSearchWithSignificantTermsAgg
  Backport: CompletableContext class to avoid throwable (#32829)
  [TEST] Select free port for Minio (#32837)
  SCRIPTING: Support BucketAggScript return null (#32811) (#32833)
  HLRC: Add Delete License API (#32586)
  Aggregations/HL Rest client fix: missing scores (#32774)
  HLRC: migration get assistance API (#32744)
  Fix NOOP bulk updates (#32819)
  Increase logging testRetentionPolicyChangeDuringRecovery
  AwaitsFix case-functions.sql-spec
  ...
@jimczi jimczi added v7.0.0-beta1 and removed v7.0.0 labels Feb 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants