Skip to content

Make opensearch_security.multitenancy.tenants.preferred configurable dynamically via security config api#5986

Open
itsmevichu wants to merge 8 commits intoopensearch-project:mainfrom
itsmevichu:feature/gh-5969
Open

Make opensearch_security.multitenancy.tenants.preferred configurable dynamically via security config api#5986
itsmevichu wants to merge 8 commits intoopensearch-project:mainfrom
itsmevichu:feature/gh-5969

Conversation

@itsmevichu
Copy link

Description

  • Category (Enhancement)
  • Why these changes are required?
    This PR proposes making opensearch_security.multitenancy.tenants.preferred configurable dynamically via the Security configuration API in OpenSearch, instead of being solely controlled via opensearch_dashboards.yml
  • What is the old behavior before changes and new behavior after changes?
    Before: preferred_tenants was not part of config APIs or /dashboardsinfo.
    After: preferred_tenants can be set via tenancy config API, is persisted in ConfigV7.Kibana, returned in /dashboardsinfo.

Issues Resolved

#5969

Testing

  • Added/updated unit tests in MultiTenancyConfigApiTest and ConfigV7Test for preferred_tenants. :

Check List

  • New functionality includes testing
  • New functionality has been documented
  • New Roles/Permissions have a corresponding security dashboards plugin PR
  • API changes companion pull request created
  • Commits are signed per the DCO using --signoff

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.

…nfo API

Signed-off-by: Vishnutheep B <vishnutheep@gmail.com>
Signed-off-by: Vishnutheep B <vishnutheep@gmail.com>
@itsmevichu itsmevichu marked this pull request as draft March 4, 2026 05:02
@itsmevichu itsmevichu marked this pull request as ready for review March 8, 2026 13:15
Signed-off-by: Vishnutheep B <vishnutheep@gmail.com>
@cwperks
Copy link
Member

cwperks commented Mar 22, 2026

@itsmevichu thank you for this PR. Can you please fix the CHANGELOG conflict? Apologies for not running the checks earlier. They are running now. Please look for any failures if some of the checks come back red.

@codecov
Copy link

codecov bot commented Mar 22, 2026

Codecov Report

❌ Patch coverage is 95.83333% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.91%. Comparing base (1d77e46) to head (5f3f93e).
⚠️ Report is 21 commits behind head on main.

Files with missing lines Patch % Lines
.../dlic/rest/validation/RequestContentValidator.java 91.66% 0 Missing and 2 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #5986      +/-   ##
==========================================
+ Coverage   73.82%   73.91%   +0.08%     
==========================================
  Files         439      439              
  Lines       27087    27130      +43     
  Branches     4018     4021       +3     
==========================================
+ Hits        19998    20053      +55     
+ Misses       5180     5173       -7     
+ Partials     1909     1904       -5     
Files with missing lines Coverage Δ
...ity/dlic/rest/api/MultiTenancyConfigApiAction.java 92.78% <100.00%> (+1.87%) ⬆️
...rivileges/DashboardsMultiTenancyConfiguration.java 90.90% <100.00%> (+0.90%) ⬆️
...opensearch/security/rest/DashboardsInfoAction.java 81.03% <100.00%> (+0.33%) ⬆️
...search/security/securityconf/impl/v7/ConfigV7.java 84.28% <100.00%> (+0.11%) ⬆️
.../dlic/rest/validation/RequestContentValidator.java 89.84% <91.66%> (+3.57%) ⬆️

... and 10 files with indirect coverage changes

🚀 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.

@itsmevichu
Copy link
Author

The failing CI checks seems irrelevant.

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