cloudstack/server/src/main/java/com/cloud
Abhisar Sinha 2a4a1f73d0
Support multi-scope configuration settings (#10300)
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 : https://github.com/apache/cloudstack-documentation/pull/476

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
Co-authored-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2025-02-14 11:25:01 +05:30
..
account CLOUDSTACK-10105: Use maven standard project structure in all projects (#2283) 2018-01-20 03:19:27 +05:30
acl Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
agent/manager Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
alert api,agent,server,engine-schema: scalability improvements (#9840) 2025-02-01 12:28:41 +05:30
api Merge branch '4.20' 2025-02-12 16:54:05 +01:00
async CLOUDSTACK-10105: Use maven standard project structure in all projects (#2283) 2018-01-20 03:19:27 +05:30
bgp Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
capacity api,agent,server,engine-schema: scalability improvements (#9840) 2025-02-01 12:28:41 +05:30
configuration Support multi-scope configuration settings (#10300) 2025-02-14 11:25:01 +05:30
consoleproxy Merge branch '4.20' 2025-02-01 21:20:08 +01:00
dc Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
deploy api,agent,server,engine-schema: scalability improvements (#9840) 2025-02-01 12:28:41 +05:30
event Fixed listEvents intermittent exception: (#9661) 2024-09-17 15:37:10 +05:30
ha server: investigate pending HA work when executing in new MS session (#10167) 2025-01-28 14:39:31 +05:30
hypervisor Merge branch '4.20' 2025-02-01 21:20:08 +01:00
metadata Normalize loggers and upgrade log4j 1.2 to log4j 2.19 (#7131) 2024-02-08 09:55:41 -03:00
network Support multi-scope configuration settings (#10300) 2025-02-14 11:25:01 +05:30
projects Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
resource Merge branch '4.20' 2025-02-01 21:20:08 +01:00
resourceicon Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
resourcelimit Add Resource Limits to Backups and Object Storage (#10017) 2025-02-07 16:56:20 +05:30
server Support multi-scope configuration settings (#10300) 2025-02-14 11:25:01 +05:30
servlet Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
storage Support multi-scope configuration settings (#10300) 2025-02-14 11:25:01 +05:30
tags Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
template Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
test Normalize loggers and upgrade log4j 1.2 to log4j 2.19 (#7131) 2024-02-08 09:55:41 -03:00
usage Improve logging to include more identifiable information (#9873) 2025-01-06 16:42:37 +05:30
user Merge branch '4.19' into 4.20 2025-02-12 15:00:51 +01:00
uuididentity add entity-type to message when no UUID is found for a DB ID (#5163) 2021-07-21 08:01:08 -03:00
vm Merge branch '4.19' into 4.20 2025-02-12 15:00:51 +01:00