ml-commons
ml-commons copied to clipboard
Add feature enable setting for controller index
Description
This PR will add a feature enable setting for controller index, to support multi-tenancy
Check List
- [ ] New functionality includes testing.
- [ ] All tests pass
- [ ] New functionality has been documented.
- [ ] New functionality has javadoc added
- [X] 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.
Shouldn't we check this kind of places too: https://github.com/opensearch-project/ml-commons/blob/b6618b2bcd18ab7070a8b8923074d365efe89dd9/plugin/src/main/java/org/opensearch/ml/model/MLModelManager.java#L1044
@b4sjoo Any update on this?
@b4sjoo Any update on this?
@dhrubo-os I don't think there are any blocking comments left, can we approve and merge it?
I haven't see any unit tests when controller is disabled for the transport actions. Can we add some tests accordingly?
Integration tests are failing. I retried now. I left few comments @b4sjoo
I haven't see any unit tests when controller is disabled for the transport actions. Can we add some tests accordingly?
Fine I can add them when I get back. Not a hard job
I think we should also check here before performing deletion?
I think we should also check here before performing deletion?
No need because it calls DeleteControllerTransportAction, which already have applied feature flag. No need to do the duplicated call.
The backport to feature/multi_tenancy failed:
The process '/usr/bin/git' failed with exit code 1
To backport manually, run these commands in your terminal:
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-feature/multi_tenancy feature/multi_tenancy
# Navigate to the new working tree
cd .worktrees/backport-feature/multi_tenancy
# Create a new branch
git switch --create backport/backport-2652-to-feature/multi_tenancy
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 a72181a0fadd32dd16b7a84092dc2e7e2fc4d8b9
# Push it to GitHub
git push --set-upstream origin backport/backport-2652-to-feature/multi_tenancy
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-feature/multi_tenancy
Then, create a pull request where the base branch is feature/multi_tenancy and the compare/head branch is backport/backport-2652-to-feature/multi_tenancy.