Updated DE architecture doc + 'period' param

In this changeset, I updated the architecture documentation
about the Decision Engine by adding a new sequence diagram
outlining the CDM synchronization workflow.
I also explained the default 'period' parameter used in the
CDMC plugin.

Change-Id: I09790281ba9117e302ab8e66a887667929c6c261
Partially-Implements: blueprint cluster-model-objects-wrapper
This commit is contained in:
Vincent Françoise
2016-06-30 11:43:49 +02:00
parent 06c6c4691b
commit 4f8591cb02
8 changed files with 112 additions and 54 deletions

View File

@@ -114,12 +114,15 @@ tune the action to its needs. To do so, you can implement the
def execute(self):
assert self.config.test_opt == 0
def get_config_opts(self):
return [
@classmethod
def get_config_opts(cls):
return super(
DummyAction, cls).get_config_opts() + [
cfg.StrOpt('test_opt', help="Demo Option.", default=0),
# Some more options ...
]
The configuration options defined within this class method will be included
within the global ``watcher.conf`` configuration file under a section named by
convention: ``{namespace}.{plugin_name}``. In our case, the ``watcher.conf``

View File

@@ -54,6 +54,10 @@ Define configuration parameters
===============================
At this point, you have a fully functional cluster data model collector.
By default, cluster data model collectors define an ``period`` option (see
:py:meth:`~.BaseClusterDataModelCollector.get_config_opts`) that corresponds
to the interval of time between each synchronization of the in-memory model.
However, in more complex implementation, you may want to define some
configuration options so one can tune the cluster data model collector to its
needs. To do so, you can implement the :py:meth:`~.Loadable.get_config_opts`
@@ -73,8 +77,10 @@ class method as followed:
# Do something here...
return model
def get_config_opts(self):
return [
@classmethod
def get_config_opts(cls):
return super(
DummyClusterDataModelCollector, cls).get_config_opts() + [
cfg.StrOpt('test_opt', help="Demo Option.", default=0),
# Some more options ...
]

View File

@@ -91,8 +91,10 @@ tune the planner to its needs. To do so, you can implement the
assert self.config.test_opt == 0
# [...]
def get_config_opts(self):
return [
@classmethod
def get_config_opts(cls):
return super(
DummyPlanner, cls).get_config_opts() + [
cfg.StrOpt('test_opt', help="Demo Option.", default=0),
# Some more options ...
]