Store pool name in component registry
Alongside other information about provider pools, store the configured name of a pool in the PoolComponent of the component registry. Change-Id: I509a6cfd42c24bc55f563fd13222af129015b727
This commit is contained in:
parent
eef07d21f3
commit
909cf73ca0
|
@ -455,6 +455,7 @@ class PoolWorker(threading.Thread, stats.StatsReporter):
|
|||
pool_config = self.getPoolConfig()
|
||||
self.component_info.content.update({
|
||||
'id': self.launcher_id,
|
||||
'name': self.pool_name,
|
||||
'provider_name': self.provider_name,
|
||||
'supported_labels': list(pool_config.labels),
|
||||
'state': self.component_info.RUNNING,
|
||||
|
|
|
@ -36,6 +36,7 @@ class TestComponentRegistry(tests.DBTestCase):
|
|||
version=get_version_string())
|
||||
launcher.content.update({
|
||||
'id': "launcher-Poolworker.provider-main-" + uuid.uuid4().hex,
|
||||
'name': 'main',
|
||||
'provider_name': 'provider',
|
||||
'supported_labels': [],
|
||||
'state': launcher.RUNNING,
|
||||
|
|
|
@ -215,6 +215,7 @@ class PoolComponent(BaseComponent):
|
|||
super().__init__(*args, **kwargs)
|
||||
self.initial_state = {
|
||||
"id": None,
|
||||
"name": None,
|
||||
"provider_name": None,
|
||||
"supported_labels": [],
|
||||
"priority": 100,
|
||||
|
|
Loading…
Reference in New Issue