Difference between revisions of "Ceilometer/blueprints/multi-publisher"
m (Text replace - "__NOTOC__" to "") |
|||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | + | ||
* '''Launchpad Entry''': [[CeilometerSpec]]:multi-publisher | * '''Launchpad Entry''': [[CeilometerSpec]]:multi-publisher | ||
* '''Created''': 05 Dec 2012 | * '''Created''': 05 Dec 2012 | ||
Line 28: | Line 28: | ||
Five components for multiple publisher support, data collector, transformer, publisher and pipeline, pipeline manager. | Five components for multiple publisher support, data collector, transformer, publisher and pipeline, pipeline manager. | ||
− | Data collectors collect measurements from other openstack project. Now two types of data collector in ceilometer, pollster and notification handler. | + | * Data collectors collect measurements from other openstack project. Now two types of data collector in ceilometer, pollster and notification handler. |
− | + | * Transformers transform the data from data collectors or from other transformers. They can change the counter name, translate to another data format, drop some data etc. | |
− | Transformers transform the data from data collectors or from other transformers. They can change the counter name, translate to another data format, drop some data etc. | + | * Publishers publish data to the world through conduit. |
− | + | * Pipeline is a logic components chaining the data collectors, transformers and publishers together, so that measurement flows from different data collectors to different publishers. Multiple pipeline exists in the system. | |
− | Publishers publish data to the world through conduit. | + | * Pipeline manager manages the pipelines in the system. Only one pipeline manager exist in the system. The measurement collected from the collector will be dispatched to the pipeline manager. |
− | |||
− | Pipeline is a logic components chaining the data collectors, transformers and publishers together, so that measurement flows from different data collectors to different publishers. Multiple pipeline exists in the system. | ||
− | |||
− | Pipeline manager manages the pipelines in the system. Only one pipeline manager exist in the system. The measurement collected from the collector will be dispatched to the pipeline manager. | ||
== Implementation == | == Implementation == | ||
Line 46: | Line 42: | ||
Each pipeline item defines a list of targeted counter, an list of transformers with their corresponding parameter as dictionary, and publishers. | Each pipeline item defines a list of targeted counter, an list of transformers with their corresponding parameter as dictionary, and publishers. | ||
+ | <pre><nowiki> | ||
[ | [ | ||
{ | { | ||
− | "counter_names" : ["counter_1", "counter_2"], | + | "counter_names" : ["counter_1", "counter_2"], |
− | "tranformers": [ | + | |
+ | "tranformers":[ | ||
{"Transformer_name": "Transformer_1", | {"Transformer_name": "Transformer_1", | ||
"Transformer_param": {}}, | "Transformer_param": {}}, | ||
Line 55: | Line 53: | ||
"Transformer_param": {}} | "Transformer_param": {}} | ||
], | ], | ||
+ | |||
"publishers": ["publisher_1", "publisher_2"] | "publishers": ["publisher_1", "publisher_2"] | ||
+ | |||
}, | }, | ||
+ | |||
{ | { | ||
− | "counter_names" : ["counter_3", "counter_4"], | + | |
+ | "counter_names" : ["counter_3", "counter_4"], | ||
+ | |||
+ | |||
"tranformers": [ | "tranformers": [ | ||
+ | |||
{"Transformer_name": "Transformer_1", | {"Transformer_name": "Transformer_1", | ||
+ | |||
"Transformer_param": {}}, | "Transformer_param": {}}, | ||
+ | |||
{"Transformer_name": "Transformer_2", | {"Transformer_name": "Transformer_2", | ||
+ | |||
"Transformer_param": {}} | "Transformer_param": {}} | ||
+ | |||
], | ], | ||
+ | |||
"publishers": ["publisher_1", "publisher_2"] | "publishers": ["publisher_1", "publisher_2"] | ||
+ | |||
} | } | ||
+ | |||
] | ] | ||
+ | |||
+ | </nowiki></pre> | ||
+ | |||
Target counter name format: "*", "counter_name", or "!counter_name". It's from the 'name' field in the Counter named tuple. | Target counter name format: "*", "counter_name", or "!counter_name". It's from the 'name' field in the Counter named tuple. | ||
Line 77: | Line 92: | ||
=== UI Changes === | === UI Changes === | ||
− | + | User should provide a config file for the pipeline definition. Currently we support yaml file format. | |
+ | |||
+ | An alternate syntax in YAML might be: | ||
+ | |||
+ | |||
+ | <pre><nowiki> | ||
+ | --- | ||
+ | - | ||
+ | counters: counter_1, counter_2 | ||
+ | transformers: | ||
+ | - | ||
+ | name: Transformer_1 | ||
+ | parameters: | ||
+ | p1: value | ||
+ | publishers: | ||
+ | - publisher_1 | ||
+ | - publisher_2 | ||
+ | |||
+ | - | ||
+ | counters: counter_3, counter_4 | ||
+ | transformers: | ||
+ | - | ||
+ | name: Transformer_2 | ||
+ | parameters: | ||
+ | p1: value | ||
+ | publishers: | ||
+ | - publisher_1 | ||
+ | - publisher_2 | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | or more compactly | ||
+ | |||
+ | |||
+ | <pre><nowiki> | ||
+ | |||
+ | - counters: counter_1, counter_2 | ||
+ | publishers: [publisher_1, publisher_2] | ||
+ | transformers: | ||
+ | - name: Transformer_1 | ||
+ | parameters: {p1: value} | ||
+ | - counters: counter_3, counter_4 | ||
+ | publishers: [publisher_1, publisher_2] | ||
+ | transformers: | ||
+ | - name: Transformer_2 | ||
+ | parameters: {p1: value} | ||
+ | </nowiki></pre> | ||
+ | |||
=== Code Changes === | === Code Changes === |
Latest revision as of 23:29, 17 February 2013
- Launchpad Entry: CeilometerSpec:multi-publisher
- Created: 05 Dec 2012
- Contributors: Yunhong Jiang
Contents
Summary
Multiple publishers in ceilometer transform collected measurements into different format, like meter, metrics etc, and publish to different target, like data storage, synaps etc, through different conduit, like rpc, UDP etc.
To support different requirement from different publishers, a set a transformers are orgnized as pipeline, to transform the data from counter to meter, metrics etc.
Release Note
Rationale
User stories
Disk usage data are published to ceilometer collector through message bus as meter, and published to synaps through PutMetricData API as metrics.
Metering system publish network usage data as per-vnic usage information, while CW publish the network usage data as a whole.
Assumptions
Design
This is just one possible design for this feature (keep that in mind).
Five components for multiple publisher support, data collector, transformer, publisher and pipeline, pipeline manager.
- Data collectors collect measurements from other openstack project. Now two types of data collector in ceilometer, pollster and notification handler.
- Transformers transform the data from data collectors or from other transformers. They can change the counter name, translate to another data format, drop some data etc.
- Publishers publish data to the world through conduit.
- Pipeline is a logic components chaining the data collectors, transformers and publishers together, so that measurement flows from different data collectors to different publishers. Multiple pipeline exists in the system.
- Pipeline manager manages the pipelines in the system. Only one pipeline manager exist in the system. The measurement collected from the collector will be dispatched to the pipeline manager.
Implementation
Below is the pipeline definition.
Top level is an array of pipeline definition.
Each pipeline item defines a list of targeted counter, an list of transformers with their corresponding parameter as dictionary, and publishers.
[ { "counter_names" : ["counter_1", "counter_2"], "tranformers":[ {"Transformer_name": "Transformer_1", "Transformer_param": {}}, {"Transformer_name": "Transformer_2", "Transformer_param": {}} ], "publishers": ["publisher_1", "publisher_2"] }, { "counter_names" : ["counter_3", "counter_4"], "tranformers": [ {"Transformer_name": "Transformer_1", "Transformer_param": {}}, {"Transformer_name": "Transformer_2", "Transformer_param": {}} ], "publishers": ["publisher_1", "publisher_2"] } ]
Target counter name format: "*", "counter_name", or "!counter_name". It's from the 'name' field in the Counter named tuple.
Transformer_name is from namespace definitions in setup.py.
Publisher_name is from namespace definitions in setup.py.
UI Changes
User should provide a config file for the pipeline definition. Currently we support yaml file format.
An alternate syntax in YAML might be:
--- - counters: counter_1, counter_2 transformers: - name: Transformer_1 parameters: p1: value publishers: - publisher_1 - publisher_2 - counters: counter_3, counter_4 transformers: - name: Transformer_2 parameters: p1: value publishers: - publisher_1 - publisher_2
or more compactly
- counters: counter_1, counter_2 publishers: [publisher_1, publisher_2] transformers: - name: Transformer_1 parameters: {p1: value} - counters: counter_3, counter_4 publishers: [publisher_1, publisher_2] transformers: - name: Transformer_2 parameters: {p1: value}
Code Changes
Changes to agent manager, central manager, collect service to load the transformers and publishers, to setup the pipeline manager.
Add the implementation of transformer, the publishers etc.
Migration
Include:
- data migration, if any
- redirects from old URLs to new ones, if any
- how users will be pointed to the new way of doing things, if necessary.
Test/Demo Plan
This need not be added or completed until the specification is nearing beta.
Unresolved issues
This should highlight any issues that should be addressed in further specifications, and not problems with the specification itself; since any specification with problems cannot be approved.
BoF agenda and discussion
Use this section to take notes during the BoF; if you keep it in the approved spec, use it for summarising what was discussed and note any options that were rejected.