Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 0f1ffd0

Browse files
yngvar-antonssonDifferentialOrange
andauthoredJan 20, 2021
Cartridge role setup in documentation (#170)
Co-authored-by: Georgy Moiseev <[email protected]>
1 parent 1f06e88 commit 0f1ffd0

File tree

3 files changed

+18
-4
lines changed

3 files changed

+18
-4
lines changed
 

‎doc/monitoring/getting_started.rst

+18-4
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ via configuration.
7676

7777
**Usage**
7878

79-
#. Add the ``metrics`` package to dependencies in the ``.rockspec`` file.
80-
Make sure that you are using version 0.3.0 or higher.
79+
#. Add ``metrics`` package to dependencies in the ``.rockspec`` file.
80+
Make sure that you are using version **0.3.0** or higher.
8181

8282
.. code-block:: lua
8383
@@ -87,7 +87,8 @@ via configuration.
8787
...
8888
}
8989
90-
#. Add ``cartridge.roles.metrics`` to the roles list in ``cartridge.cfg``
90+
#. Make sure that you have ``cartridge.roles.metrics``
91+
in the roles list in ``cartridge.cfg``
9192
in your entry-point file (e.g. ``init.lua``).
9293

9394
.. code-block:: lua
@@ -101,8 +102,18 @@ via configuration.
101102
},
102103
})
103104
105+
#. Enable role in the interface:
106+
107+
.. image:: images/role-enable.png
108+
:align: center
109+
110+
Since version **0.6.0** metrics role is permanent and enabled on instances by default.
111+
104112
#. After role initialization, default metrics will be enabled and the global
105-
label 'alias' will be set. If you need to use the functionality of any
113+
label ``'alias'`` will be set. **Note** that ``'alias'`` label value is set by
114+
instance :ref:`configuration option <cartridge-cfg>` ``alias``.
115+
116+
If you need to use the functionality of any
106117
metrics package, you may get it as a Cartridge service and use it like
107118
a regular package after ``require``:
108119

@@ -124,6 +135,9 @@ via configuration.
124135
- path: '/path_for_prometheus_metrics'
125136
format: 'prometheus'
126137
138+
.. image:: images/role-config.png
139+
:align: center
140+
127141
**OR**
128142

129143
Use ``set_export``:

‎doc/monitoring/images/role-config.png

124 KB
Loading

‎doc/monitoring/images/role-enable.png

126 KB
Loading

0 commit comments

Comments
 (0)
Please sign in to comment.