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] Adding QueryGroup schema (#13669) #14690

Merged
merged 2 commits into from
Jul 9, 2024

Conversation

kaushalmahi12
Copy link
Contributor

Description

Backport PR for original PR: #13669

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.

* rebase with opensearch/main

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupId propagation logic from coordinator to data nodes

Signed-off-by: Kaushal Kumar <[email protected]>

* add sandbox schema

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupTests

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupMetadata tests

Signed-off-by: Kaushal Kumar <[email protected]>

* run spotlessApply

Signed-off-by: Kaushal Kumar <[email protected]>

* add mode field in ResourceLimitGroup schema

Signed-off-by: Kaushal Kumar <[email protected]>

* fix breaking testcases

Signed-off-by: Kaushal Kumar <[email protected]>

* add task cancellation skeleton

Signed-off-by: Kaushal Kumar <[email protected]>

* add multitenant labels in searchSource builder

Signed-off-by: Kaushal Kumar <[email protected]>

* write custom xcontent parser for ResourceLimitGroup

Signed-off-by: Kaushal Kumar <[email protected]>

* remove unrelated changes

Signed-off-by: Kaushal Kumar <[email protected]>

* remove non-existing import fro cluster settings

Signed-off-by: Kaushal Kumar <[email protected]>

* remove non releated changes

Signed-off-by: Kaushal Kumar <[email protected]>

* add _id as the resourceLimitGroup key

Signed-off-by: Kaushal Kumar <[email protected]>

* add change to register resource limit group metadata

Signed-off-by: Kaushal Kumar <[email protected]>

* add updatedAt in resource limit group

Signed-off-by: Kaushal Kumar <[email protected]>

* rename resourceLimitGroup to queryGroup

Signed-off-by: Kaushal Kumar <[email protected]>

* address the comments on PR

Signed-off-by: Kaushal Kumar <[email protected]>

* rename the mode member var to resiliency mode

Signed-off-by: Kaushal Kumar <[email protected]>

* address comments

Signed-off-by: Kaushal Kumar <[email protected]>

* add change in CHANGELOG

Signed-off-by: Kaushal Kumar <[email protected]>

* add tests for custom namedWritable QueryGroupMetadata

Signed-off-by: Kaushal Kumar <[email protected]>

* structure resourceLimits into an object

Signed-off-by: Kaushal Kumar <[email protected]>

* add QueryGroup.toXContent test case

Signed-off-by: Kaushal Kumar <[email protected]>

* fix precommit errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix precommit errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix assemble errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix checkstyle errors

Signed-off-by: Kaushal Kumar <[email protected]>

* address comments

Signed-off-by: Kaushal Kumar <[email protected]>

---------

Signed-off-by: Kaushal Kumar <[email protected]>
Copy link
Contributor

github-actions bot commented Jul 9, 2024

❌ Gradle check result for fff79ae: 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?

Copy link
Contributor

github-actions bot commented Jul 9, 2024

✅ Gradle check result for 6b8ccb2: SUCCESS

Copy link

codecov bot commented Jul 9, 2024

Codecov Report

Attention: Patch coverage is 79.36508% with 39 lines in your changes missing coverage. Please review.

Project coverage is 71.43%. Comparing base (7040df2) to head (6b8ccb2).

Files Patch % Lines
...va/org/opensearch/cluster/metadata/QueryGroup.java 85.24% 8 Missing and 10 partials ⚠️
...java/org/opensearch/cluster/metadata/Metadata.java 0.00% 10 Missing ⚠️
...pensearch/cluster/metadata/QueryGroupMetadata.java 80.39% 8 Missing and 2 partials ⚠️
...search/backpressure/SearchBackpressureService.java 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##                2.x   #14690    +/-   ##
==========================================
  Coverage     71.42%   71.43%            
- Complexity    62382    62435    +53     
==========================================
  Files          5103     5105     +2     
  Lines        293268   293454   +186     
  Branches      42730    42760    +30     
==========================================
+ Hits         209478   209637   +159     
+ Misses        66236    66203    -33     
- Partials      17554    17614    +60     

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

Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

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

Assuming it's the same code just rebased. LMK if otherwise.

@dblock dblock merged commit fb64a4d into opensearch-project:2.x Jul 9, 2024
32 checks passed
@kaushalmahi12
Copy link
Contributor Author

Yes, Thanks @dblock

kkewwei pushed a commit to kkewwei/OpenSearch that referenced this pull request Jul 24, 2024
…pensearch-project#14690)

* Adding QueryGroup schema (opensearch-project#13669)

* rebase with opensearch/main

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupId propagation logic from coordinator to data nodes

Signed-off-by: Kaushal Kumar <[email protected]>

* add sandbox schema

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupTests

Signed-off-by: Kaushal Kumar <[email protected]>

* add resourceLimitGroupMetadata tests

Signed-off-by: Kaushal Kumar <[email protected]>

* run spotlessApply

Signed-off-by: Kaushal Kumar <[email protected]>

* add mode field in ResourceLimitGroup schema

Signed-off-by: Kaushal Kumar <[email protected]>

* fix breaking testcases

Signed-off-by: Kaushal Kumar <[email protected]>

* add task cancellation skeleton

Signed-off-by: Kaushal Kumar <[email protected]>

* add multitenant labels in searchSource builder

Signed-off-by: Kaushal Kumar <[email protected]>

* write custom xcontent parser for ResourceLimitGroup

Signed-off-by: Kaushal Kumar <[email protected]>

* remove unrelated changes

Signed-off-by: Kaushal Kumar <[email protected]>

* remove non-existing import fro cluster settings

Signed-off-by: Kaushal Kumar <[email protected]>

* remove non releated changes

Signed-off-by: Kaushal Kumar <[email protected]>

* add _id as the resourceLimitGroup key

Signed-off-by: Kaushal Kumar <[email protected]>

* add change to register resource limit group metadata

Signed-off-by: Kaushal Kumar <[email protected]>

* add updatedAt in resource limit group

Signed-off-by: Kaushal Kumar <[email protected]>

* rename resourceLimitGroup to queryGroup

Signed-off-by: Kaushal Kumar <[email protected]>

* address the comments on PR

Signed-off-by: Kaushal Kumar <[email protected]>

* rename the mode member var to resiliency mode

Signed-off-by: Kaushal Kumar <[email protected]>

* address comments

Signed-off-by: Kaushal Kumar <[email protected]>

* add change in CHANGELOG

Signed-off-by: Kaushal Kumar <[email protected]>

* add tests for custom namedWritable QueryGroupMetadata

Signed-off-by: Kaushal Kumar <[email protected]>

* structure resourceLimits into an object

Signed-off-by: Kaushal Kumar <[email protected]>

* add QueryGroup.toXContent test case

Signed-off-by: Kaushal Kumar <[email protected]>

* fix precommit errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix precommit errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix assemble errors

Signed-off-by: Kaushal Kumar <[email protected]>

* fix checkstyle errors

Signed-off-by: Kaushal Kumar <[email protected]>

* address comments

Signed-off-by: Kaushal Kumar <[email protected]>

---------

Signed-off-by: Kaushal Kumar <[email protected]>

* add min supported version in query group metadata

Signed-off-by: Kaushal Kumar <[email protected]>

---------

Signed-off-by: Kaushal Kumar <[email protected]>
Signed-off-by: kkewwei <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants