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] fix(queryEnhancements): data.search() should not ignore the strategy passed as parameter #8495

Merged
merged 1 commit into from
Oct 7, 2024

Conversation

opensearch-trigger-bot[bot]
Copy link
Contributor

Backport e077644 from #8368.

…` passed as parameter (#8368)

* fix(queryEnhancements): data.search() should not ignore the `strategy` passed as parameter

This is quick fix for the issue that the search strategy passed to
data.search() API been completely ignored when query enhancement is
enabled and the localStorage has a language preserved.

For example, selecting a language from discover language selector
will make data.search() called with a specific strategy to use the
language config stored in localStorage which is unexpected.

With this fix, language config is only used when search strategy is not
passed specifically.

Signed-off-by: Yulong Ruan <[email protected]>

* Changeset file for PR #8368 created/updated

---------

Signed-off-by: Yulong Ruan <[email protected]>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
(cherry picked from commit e077644)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Copy link
Contributor

github-actions bot commented Oct 4, 2024

❌ Invalid Changelog Heading

The '## Changelog' heading in your PR description is either missing or malformed. Please make sure that your PR description includes a '## Changelog' heading with proper spelling, capitalization, spacing, and Markdown syntax.

Copy link

codecov bot commented Oct 4, 2024

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 61.02%. Comparing base (200986a) to head (8c61d31).
Report is 4 commits behind head on 2.x.

Files with missing lines Patch % Lines
src/plugins/data/public/search/search_service.ts 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##              2.x    #8495   +/-   ##
=======================================
  Coverage   61.02%   61.02%           
=======================================
  Files        3758     3758           
  Lines       89306    89306           
  Branches    13962    13962           
=======================================
  Hits        54495    54495           
  Misses      31417    31417           
  Partials     3394     3394           
Flag Coverage Δ
Linux_1 28.92% <0.00%> (ø)
Linux_2 56.41% <ø> (ø)
Linux_3 37.80% <0.00%> (?)
Linux_4 30.06% <0.00%> (ø)
Windows_1 28.93% <0.00%> (ø)
Windows_2 56.37% <ø> (ø)
Windows_3 37.81% <0.00%> (ø)
Windows_4 30.06% <0.00%> (ø)

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.

@SuZhou-Joe SuZhou-Joe merged commit c5462c3 into 2.x Oct 7, 2024
67 of 70 checks passed
@github-actions github-actions bot deleted the backport/backport-8368-to-2.x branch October 7, 2024 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
all-star-contributor autocut Skip the changelog verification check on backports discover for discover reinvent discover-next failed changeset
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants