flexmetric 0.3.2__py3-none-any.whl → 0.3.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flexmetric
3
- Version: 0.3.2
3
+ Version: 0.3.3
4
4
  Summary: A secure flexible Prometheus exporter for commands, databases, functions, and scripts.
5
5
  Home-page: https://github.com/nikhillingadhal1999/flexmetric
6
6
  Author: Nikhil Lingadhal
@@ -160,6 +160,27 @@ commands:
160
160
  value_column: 4
161
161
  timeout_seconds: 60
162
162
  ```
163
+ Example to select label_column and value_column
164
+
165
+ ```bash
166
+ Filesystem Size Used Avail Use% Mounted on
167
+ /dev/sda1 50G 20G 28G 42% /
168
+ /dev/sdb1 100G 10G 85G 10% /data
169
+ ```
170
+ ## Fields description
171
+
172
+
173
+ | Field | Description |
174
+ |------------------|-----------------------------------------------------------------------------|
175
+ | `name` | The **name** of the metric (`disk_usage`). This is the metric name seen in Prometheus. |
176
+ | `command` | The **shell command** to execute (`df -h` in this case). |
177
+ | `label` | The **label name** to attach to the metric (`path`). |
178
+ | `label_column` | The **column index** from the command's output to use as the label. Here `-1` means the **last column** (typically the mount path in `df -h`). |
179
+ | `value_column` | The **column index** from the command's output to extract the **numeric value**. Here `4` refers to the fifth column, which is usually the **Use%** in `df -h`. |
180
+ | `timeout_seconds`| How long (in seconds) to wait for the command before timing out. Here it's set to `60` seconds. |
181
+
182
+ ## Database mode
183
+
163
184
  ```yaml
164
185
  databases:
165
186
  - name: mydb
@@ -175,6 +196,8 @@ queries:
175
196
  label: table
176
197
  label_value: users
177
198
  ```
199
+ ## Functions mode
200
+
178
201
  executable_functions.txt
179
202
  ```
180
203
  function_name_1
@@ -11,8 +11,8 @@ flexmetric/metric_process/expiring_queue.py,sha256=1oC0MjloitPiRo7yDgVarz81ETEQa
11
11
  flexmetric/metric_process/process_commands.py,sha256=QAsR5uXt6rku_lTrBCfslerpqW0hMLSffzUFmxPC-fw,3556
12
12
  flexmetric/metric_process/prometheus_agent.py,sha256=hjPmNhJiB-844CgIcaw5A-VLmJqyMwQ_j1e_GI-UPSo,7422
13
13
  flexmetric/metric_process/views.py,sha256=05UbGBrAkEn_aJq7qBb_1yphCfnXiTqmXFLznMMpkN8,1194
14
- flexmetric-0.3.2.dist-info/METADATA,sha256=0imUzfRyM5YKgh-KWA9rtaiZ3ogZyScZLUAQFKH6dH0,8691
15
- flexmetric-0.3.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
16
- flexmetric-0.3.2.dist-info/entry_points.txt,sha256=urVePn5EWr3JqNvkYP7OsB_h2_Bqvv-Wq1MJRBexm8A,79
17
- flexmetric-0.3.2.dist-info/top_level.txt,sha256=zBlrNwKhXUNhgu9RRZnXxYwYnmE-eocRe6wKSmQROA4,11
18
- flexmetric-0.3.2.dist-info/RECORD,,
14
+ flexmetric-0.3.3.dist-info/METADATA,sha256=C6LEjLX8FxXysm4SvZ016r8m1IvxKEHllgeJrWtTcp8,9921
15
+ flexmetric-0.3.3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
16
+ flexmetric-0.3.3.dist-info/entry_points.txt,sha256=urVePn5EWr3JqNvkYP7OsB_h2_Bqvv-Wq1MJRBexm8A,79
17
+ flexmetric-0.3.3.dist-info/top_level.txt,sha256=zBlrNwKhXUNhgu9RRZnXxYwYnmE-eocRe6wKSmQROA4,11
18
+ flexmetric-0.3.3.dist-info/RECORD,,