-
Notifications
You must be signed in to change notification settings - Fork 20
feat(policy)!: Add manager column to provider configuration for multi-instance support [backport to release/service/v0.8] #2718
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
Draft
opentdf-automation
wants to merge
2
commits into
release/service/v0.8
Choose a base branch
from
backport-2601-to-release/service/v0.8
base: release/service/v0.8
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
+1,698
−683
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Please cherry-pick the changes locally and resolve any conflicts. git fetch origin backport-2601-to-release/service/v0.8
git worktree add --checkout .worktree/backport-2601-to-release/service/v0.8 backport-2601-to-release/service/v0.8
cd .worktree/backport-2601-to-release/service/v0.8
git reset --hard HEAD^
git cherry-pick -x a5fc994acc5491bf8cbf751b675302b459e1f3b0
git push --force-with-lease |
3 tasks
4769755
to
effc352
Compare
…-instance support (#2601) This PR implements the provider configuration manager column enhancement and includes a significant architecture improvement to eliminate code duplication. Core Features - ✅ Added manager column to provider_config table with composite unique constraint (provider_name + manager) - ✅ Database migration with backward compatibility (existingrecords default to 'local' manager) - ✅ Updated protobuf definitions to require manager field in API requests - ✅ Enhanced SQL queries and audit logging to support manager field Key Benefits 1. Multiple Instance Support: Create multiple provider configs with same name but different manager types 2. No Code Duplication: Trust system is single source of truth for available managers 3. Automatic Discovery: Well-known configuration endpoint automatically exposes registered trust key managers 4. Premium Integration: Custom managers integrate seamlessly via existing WithTrustKeyManagerFactories pattern 5. Backward Compatibility: Existing providers automatically assigned 'local' manager type Technical Changes - Database: Added manager column with composite unique constraint - API: Manager field now required in CreateProviderConfig, optional in UpdateProviderConfig - Service: Validates against RegistrationParams.KeyManagerFactories instead of separate registry - Well-known Config: Dynamically populated from trust key manager factories - Tests: Updated to reflect new validation approach Usage for Custom Managers Premium builds can add custom managers using the existing pattern: ```go server.Start( server.WithTrustKeyManagerFactories( trust.NamedKeyManagerFactory{Name: "premium-hsm", Factory: hsmFactory}, trust.NamedKeyManagerFactory{Name: "premium-vault", Factory: vaultFactory}, ), ) ``` - [ ] I have added or updated unit tests - [ ] I have added or updated integration tests (if appropriate) - [ ] I have added or updated documentation (cherry picked from commit a5fc994)
effc352
to
c1d3396
Compare
Benchmark results, click to expandBenchmark authorization.GetDecisions Results:
Benchmark authorization.v2.GetMultiResourceDecision Results:
Standard Benchmark Metrics Skipped or FailedBulk Benchmark Results
TDF3 Benchmark Results:
NANOTDF Benchmark Results:
|
Benchmark results, click to expandBenchmark authorization.GetDecisions Results:
Benchmark authorization.v2.GetMultiResourceDecision Results:
Standard Benchmark Metrics Skipped or FailedBulk Benchmark Results
TDF3 Benchmark Results:
NANOTDF Benchmark Results:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
comp:db
DB component
comp:kas
Key Access Server
comp:policy
Policy Configuration ( attributes, subject mappings, resource mappings, kas registry)
docs
Documentation
size/m
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Backport of #2601 to
release/service/v0.8
.