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

Restrict Search Replicas to Allocate only to Search dedicated node #17457

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

vinaykpud
Copy link
Contributor

@vinaykpud vinaykpud commented Feb 25, 2025

Description

In this PR we restrict Search replica to assign to any node if search replica dedicated node ie cluster.routing.allocation.search.replica.dedicated.include setting is not set. So by default search replicas will be unassigned state until we set dedicated search node by calling API like this or with yaml file

curl -X PUT "http://localhost:9200/_cluster/settings" \
-H "Content-Type: application/json" \
-d '{
  "persistent": {
    "cluster.routing.allocation.search.replica.dedicated.include._name": "opensearch-node4"
  }
}'

Related Issues

Resolves #17422
Resolves #17421
Resolves #17334
Related to #15306

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@github-actions github-actions bot added bug Something isn't working Search:Performance labels Feb 25, 2025
Signed-off-by: Vinay Krishna Pudyodu <[email protected]>
Copy link
Contributor

❌ Gradle check result for f9c54c5: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Signed-off-by: Vinay Krishna Pudyodu <[email protected]>
Copy link
Contributor

❕ Gradle check result for 2d5b977: UNSTABLE

Please review all flaky tests that succeeded after retry and create an issue if one does not already exist to track the flaky failure.

Copy link

codecov bot commented Feb 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.49%. Comparing base (5666982) to head (2d5b977).
Report is 16 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main   #17457      +/-   ##
============================================
- Coverage     72.49%   72.49%   -0.01%     
- Complexity    65717    65727      +10     
============================================
  Files          5303     5304       +1     
  Lines        304793   304824      +31     
  Branches      44202    44208       +6     
============================================
+ Hits         220966   220984      +18     
- Misses        65693    65726      +33     
+ Partials      18134    18114      -20     

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

@mch2
Copy link
Member

mch2 commented Feb 26, 2025

@vinaykpud can we combine this with a solution for #17421 so that we are not blocking replica allocation after this lands?, fix there should be a simple check.

List<String> replicas = internalCluster().startDataOnlyNodes(2);

// search node setting
client().admin()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets set these during setup ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we want to set this dynamically

@github-actions github-actions bot added the enhancement Enhancement or improvement to existing feature or request label Feb 28, 2025
Copy link
Contributor

❌ Gradle check result for 96f5eb3: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Signed-off-by: Vinay Krishna Pudyodu <[email protected]>
@vinaykpud vinaykpud requested a review from bugmakerrrrrr as a code owner March 1, 2025 00:16
@vinaykpud vinaykpud requested a review from jed326 as a code owner March 1, 2025 00:21
Copy link
Contributor

github-actions bot commented Mar 1, 2025

❌ Gradle check result for de1e719: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement Enhancement or improvement to existing feature or request Search:Performance
Projects
None yet
2 participants