Support 'meta' parameter in dispatch_metric()
Change-Id: Icb9940b57ab1b4f8de9b3d05fb79fde32f5e0e83
This commit is contained in:
parent
c31425f83b
commit
ab142b8d45
@ -92,11 +92,14 @@ class Base(object):
|
||||
- 'type_instance' (optional)
|
||||
- 'plugin_instance' (optional)
|
||||
- 'type' (optional, default='gauge')
|
||||
- 'meta' (optional)
|
||||
|
||||
For example:
|
||||
|
||||
{'type_instance':'foo', 'values': 1}
|
||||
{'type_instance':'bar', 'type': 'DERIVE', 'values': 1}
|
||||
{'type_instance':'bar', 'type': 'DERIVE', 'values': 1,
|
||||
'meta': {'tagA': 'valA'}}
|
||||
{'type': 'dropped_bytes', 'values': [1,2]}
|
||||
"""
|
||||
raise NotImplemented("Must be implemented by the subclass!")
|
||||
@ -120,7 +123,7 @@ class Base(object):
|
||||
type_instance=type_instance,
|
||||
values=values,
|
||||
# w/a for https://github.com/collectd/collectd/issues/716
|
||||
meta={'0': True}
|
||||
meta=metric.get('meta', {'0': True})
|
||||
)
|
||||
v.dispatch()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user