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

[Backport 2.x] [BUG][Data] Support for custom filters with heterogeneous data fields #5584

Merged
merged 1 commit into from
Dec 13, 2023

Conversation

opensearch-trigger-bot[bot]
Copy link
Contributor

Backport 805400d from #5577.

…#5577)

* [BUG][Data] Support for custom filters with heterogeneous data fields

When enabling the advanced setting `courier:ignoreFilterIfFieldNotInIndex`
Custom OpenSearch Query DSL filters could technically be applied to index
patterns that map to indices that are not exactly the same. Since the
custom query filter is a user input then users can really type anything
that they need. Or any field that they know is present but we do not know
for sure.

Therefore, we can check if the id which is the index pattern title to check
if we should apply the filter or not.

Issue resolved:
https://github.com/opensearch-project/dashboards-visualizations/issues/281

I believe issue:
#5423

Should closed as that is expected functionality.

Signed-off-by: Kawika Avilla <[email protected]>

* [Cleanup] utilize the same helper function

Originally when implementing the fix the historical comment caused concern about
potential breaking changes.

But after discussion, we decided it is more clear to consolidate the helper functions.

Signed-off-by: Kawika Avilla <[email protected]>
(cherry picked from commit 805400d)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

# Conflicts:
#	CHANGELOG.md
Copy link

codecov bot commented Dec 7, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (b635c4b) 66.98% compared to head (f5d48ea) 66.98%.
Report is 1 commits behind head on 2.x.

Additional details and impacted files
@@           Coverage Diff           @@
##              2.x    #5584   +/-   ##
=======================================
  Coverage   66.98%   66.98%           
=======================================
  Files        3287     3287           
  Lines       63266    63268    +2     
  Branches    10052    10053    +1     
=======================================
+ Hits        42378    42381    +3     
  Misses      18449    18449           
+ Partials     2439     2438    -1     
Flag Coverage Δ
Linux_1 35.24% <0.00%> (-0.01%) ⬇️
Linux_2 55.12% <0.00%> (-0.01%) ⬇️
Linux_3 43.82% <100.00%> (+<0.01%) ⬆️
Linux_4 35.49% <0.00%> (+<0.01%) ⬆️
Windows_1 35.27% <0.00%> (-0.01%) ⬇️
Windows_2 55.08% <0.00%> (-0.01%) ⬇️
Windows_3 43.84% <100.00%> (+<0.01%) ⬆️
Windows_4 35.49% <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.

@ananzh ananzh merged commit d518b64 into 2.x Dec 13, 2023
85 of 86 checks passed
@github-actions github-actions bot deleted the backport/backport-5577-to-2.x branch December 13, 2023 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autocut Skip the changelog verification check on backports distinguished-contributor v2.12.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants