summaryrefslogtreecommitdiff
path: root/doc/source/configuration/metering-agent.rst
diff options
context:
space:
mode:
Diffstat (limited to 'doc/source/configuration/metering-agent.rst')
-rw-r--r--doc/source/configuration/metering-agent.rst56
1 files changed, 28 insertions, 28 deletions
diff --git a/doc/source/configuration/metering-agent.rst b/doc/source/configuration/metering-agent.rst
index 663ec186b2..5bfa752361 100644
--- a/doc/source/configuration/metering-agent.rst
+++ b/doc/source/configuration/metering-agent.rst
@@ -42,18 +42,18 @@ also called as legacy) have the following format; bear in mind that if labels
are shared, then the counters are for all routers of all projects where the
labels were applied.
- .. code-block:: json
-
- {
- "pkts": "<the number of packets that matched the rules of the labels>",
- "bytes": "<the number of bytes that matched the rules of the labels>",
- "time": "<seconds between the first data collection and the last one>",
- "first_update": "timeutils.utcnow_ts() of the first collection",
- "last_update": "timeutils.utcnow_ts() of the last collection",
- "host": "<neutron metering agent host name>",
- "label_id": "<the label id>",
- "tenant_id": "<the tenant id>"
- }
+.. code-block:: json
+
+ {
+ "pkts": "<the number of packets that matched the rules of the labels>",
+ "bytes": "<the number of bytes that matched the rules of the labels>",
+ "time": "<seconds between the first data collection and the last one>",
+ "first_update": "timeutils.utcnow_ts() of the first collection",
+ "last_update": "timeutils.utcnow_ts() of the last collection",
+ "host": "<neutron metering agent host name>",
+ "label_id": "<the label id>",
+ "tenant_id": "<the tenant id>"
+ }
The ``first_update`` and ``last_update`` timestamps represent the moment
when the first and last data collection happened within the report interval.
@@ -129,21 +129,21 @@ legacy mode such as ``bytes``, ``pkts``, ``time``, ``first_update``,
``last_update``, and ``host``. As follows we present an example of JSON message
with all of the possible attributes.
- .. code-block:: json
-
- {
- "resource_id": "router-f0f745d9a59c47fdbbdd187d718f9e41-label-00c714f1-49c8-462c-8f5d-f05f21e035c7",
- "project_id": "f0f745d9a59c47fdbbdd187d718f9e41",
- "first_update": 1591058790,
- "bytes": 0,
- "label_id": "00c714f1-49c8-462c-8f5d-f05f21e035c7",
- "label_name": "test1",
- "last_update": 1591059037,
- "host": "<hostname>",
- "time": 247,
- "pkts": 0,
- "label_shared": true
- }
+.. code-block:: json
+
+ {
+ "resource_id": "router-f0f745d9a59c47fdbbdd187d718f9e41-label-00c714f1-49c8-462c-8f5d-f05f21e035c7",
+ "project_id": "f0f745d9a59c47fdbbdd187d718f9e41",
+ "first_update": 1591058790,
+ "bytes": 0,
+ "label_id": "00c714f1-49c8-462c-8f5d-f05f21e035c7",
+ "label_name": "test1",
+ "last_update": 1591059037,
+ "host": "<hostname>",
+ "time": 247,
+ "pkts": 0,
+ "label_shared": true
+ }
The ``resource_id`` is a unique identified for the "resource" being
monitored. Here we consider a resource to be any of the granularities that
@@ -156,4 +156,4 @@ As follows we present all of the possible configuration one can use in the
metering agent init file.
.. show-options::
- :config-file: etc/oslo-config-generator/metering_agent.ini \ No newline at end of file
+ :config-file: etc/oslo-config-generator/metering_agent.ini