Skip to content

Conversation

ogprakash
Copy link

Description

When the max bucket size is hit and in the aggregation response partial or no results are returned, the response should clearly inform users that the results are incomplete.

This PR adds a partial results warning in the table visualization when results are truncated due to the bucket limit.

OpenSearch already exposes sum_other_doc_count in the aggregation response, which allows us to detect partial results (> 0 means some buckets were dropped due to the bucket size limit).

Issues Resolved

closes #10374

Screenshot

Screenshot 2025-08-18 at 7 34 37 PM

Testing the changes

  1. Create a table visualization.
  2. Set bucket size very small (e.g. 1–2). A "Partial results" warning should appear.
  3. Increase bucket size to a higher value. The warning should disappear and show complete results.

Changelog

  • skip

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Description

Issues Resolved

Screenshot

Testing the changes

Changelog

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

@github-actions github-actions bot added first-time-contributor Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry labels Oct 3, 2025
@ogprakash ogprakash force-pushed the feature/partial-result-warning branch from f40d5f0 to e0eca54 Compare October 3, 2025 12:33
@ogprakash
Copy link
Author

Hi @ruanyl,
I’ve addressed all the review comments and pushed the updates.
Could you please take a look when you get time? Thanks!

Copy link

codecov bot commented Oct 6, 2025

Codecov Report

❌ Patch coverage is 14.28571% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 60.17%. Comparing base (81d5f81) to head (e0eca54).
⚠️ Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
...s/data/public/search/expressions/opensearchaggs.ts 0.00% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10640      +/-   ##
==========================================
- Coverage   60.18%   60.17%   -0.01%     
==========================================
  Files        4428     4428              
  Lines      118504   118518      +14     
  Branches    19456    19461       +5     
==========================================
+ Hits        71319    71321       +2     
- Misses      42269    42281      +12     
  Partials     4916     4916              
Flag Coverage Δ
Linux_1 ?
Linux_2 38.83% <ø> (ø)
Linux_3 ?
Linux_4 32.60% <0.00%> (-0.01%) ⬇️
Windows_1 26.66% <14.28%> (-0.01%) ⬇️
Windows_2 38.80% <ø> (ø)
Windows_3 38.71% <0.00%> (-0.01%) ⬇️
Windows_4 32.60% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

first-time-contributor Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] When the max bucket size is hit in a query returning partial or no results, the response should indicate that clearly

1 participant