Refactor resource dependencies
This refactors resource dependencies to avoid unnecessary dependencies across services. For example zaqar service does not require cinder db. Change-Id: I2757b36f027fa7a44b8d0533667956601962eac6 Signed-off-by: Takashi Kajinami <kajinamit@oss.nttdata.com>
This commit is contained in:
@@ -67,4 +67,8 @@ class cloudkitty::db (
|
||||
pool_timeout => $database_pool_timeout,
|
||||
mysql_enable_ndb => $mysql_enable_ndb,
|
||||
}
|
||||
|
||||
# all db settings should be applied and all packages should be installed
|
||||
# before dbsync starts
|
||||
Oslo::Db['cloudkitty_config'] -> Anchor['cloudkitty::dbsync::begin']
|
||||
}
|
||||
|
@@ -31,19 +31,6 @@ class cloudkitty::deps {
|
||||
-> Cloudkitty_api_paste_ini<||>
|
||||
-> Anchor['cloudkitty::config::end']
|
||||
|
||||
# all coordination settings should be applied and all packages should be
|
||||
# installed before service startup
|
||||
Oslo::Coordination<||> -> Anchor['cloudkitty::service::begin']
|
||||
|
||||
# all db settings should be applied and all packages should be installed
|
||||
# before dbsync starts
|
||||
Oslo::Db<||> -> Anchor['cloudkitty::dbsync::begin']
|
||||
|
||||
# policy config should occur in the config block also.
|
||||
Anchor['cloudkitty::config::begin']
|
||||
-> Openstacklib::Policy<| tag == 'cloudkitty' |>
|
||||
-> Anchor['cloudkitty::config::end']
|
||||
|
||||
# On any uwsgi config change, we must restart Cloudkitty API.
|
||||
Anchor['cloudkitty::config::begin']
|
||||
-> Cloudkitty_api_uwsgi_config<||>
|
||||
|
@@ -28,6 +28,10 @@ class cloudkitty::orchestrator (
|
||||
manage_config => false,
|
||||
}
|
||||
|
||||
# all coordination settings should be applied and all packages should be
|
||||
# installed before service startup
|
||||
Oslo::Coordination['cloudkitty_config'] -> Anchor['cloudkitty::service::begin']
|
||||
|
||||
cloudkitty_config {
|
||||
'orchestrator/coordination_url': value => $coordination_url, secret => true;
|
||||
'orchestrator/max_workers': value => $max_workers;
|
||||
|
@@ -69,6 +69,11 @@ class cloudkitty::policy (
|
||||
|
||||
create_resources('openstacklib::policy', { $policy_path => $policy_parameters })
|
||||
|
||||
# policy config should occur in the config block also.
|
||||
Anchor['cloudkitty::config::begin']
|
||||
-> Openstacklib::Policy[$policy_path]
|
||||
-> Anchor['cloudkitty::config::end']
|
||||
|
||||
oslo::policy { 'cloudkitty_config':
|
||||
enforce_scope => $enforce_scope,
|
||||
enforce_new_defaults => $enforce_new_defaults,
|
||||
|
Reference in New Issue
Block a user