-
Notifications
You must be signed in to change notification settings - Fork 112
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
Support multi-scope configuration settings #476
Conversation
@blueorangutan docbuild |
not sure if the ape accepts corrections ;) |
@DaanHoogland a Jenkins job has been kicked to build the document. I'll keep you posted as I make progress. |
QA-Doc build preview: https://qa.cloudstack.cloud/builds/docs-build/pr/476. (QA-JID 306) |
@abh1sar can you please add a diagram depicting hierarchy for different scopes? |
@shwstppr although we have defined a hierarchy for each scope in the code, this general information is not useful for the admin, unless we are talking about specific settings and their scopes. |
I see it has been added to code PR description which should be enough for now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comment otherwise lgtm
Use the following steps to set local configuration parameters for an | ||
account, zone, cluster, or primary storage. These values will override | ||
the global configuration settings. | ||
Configurations can also be set at more granular levels. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we emphasize somewhere level = scope?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…stack-documentation into multi-scope-config
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@blueorangutan docbuild |
@abh1sar a Jenkins job has been kicked to build the document. I'll keep you posted as I make progress. |
QA-Doc build preview: https://qa.cloudstack.cloud/builds/docs-build/pr/476. (QA-JID 308) |
This PR introduces the concept of multi-scope configuration settings. In addition to the Global level, currently all configurations can be set at a single scope level. It will be useful if a configuration can be set at multiple scopes. For example, a configuration set at the domain level will apply for all accounts, but it can be set for an account as well. In which case the account level setting will override the domain level setting. This is done by changing the column `scope` of table `configuration` from string (single scope) to bitmask (multiple scopes). ``` public enum Scope { Global(null, 1), Zone(Global, 1 << 1), Cluster(Zone, 1 << 2), StoragePool(Cluster, 1 << 3), ManagementServer(Global, 1 << 4), ImageStore(Zone, 1 << 5), Domain(Global, 1 << 6), Account(Domain, 1 << 7); ``` Each scope is also assigned a parent scope. When a configuration for a given scope is not defined but is available for multiple scope types, the value will be retrieved from the parent scope. If there is no parent scope or if the configuration is defined for a single scope only, the value will fall back to the global level. Hierarchy for different scopes is defined as below : - Global - Zone - Cluster - Storage Pool - Image Store - Management Server - Domain - Account This PR also updates the scope of the following configurations (Storage Pool scope is added in addition to the existing Zone scope): - pool.storage.allocated.capacity.disablethreshold - pool.storage.allocated.resize.capacity.disablethreshold - pool.storage.capacity.disablethreshold Doc PR : apache/cloudstack-documentation#476 Signed-off-by: Abhishek Kumar <[email protected]> Co-authored-by: Abhishek Kumar <[email protected]>
Doc PR for apache/cloudstack#10300
📚 Documentation preview 📚: https://cloudstack-documentation--476.org.readthedocs.build/en/476/