Skip to content

Commit

Permalink
Revert removing of metric
Browse files Browse the repository at this point in the history
  • Loading branch information
dyedwiper committed Feb 5, 2025
1 parent 58d18e2 commit fceef51
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions ansible/roles/mongodb_query_exporter/templates/values.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -583,6 +583,28 @@ aggregations:
{ "$match" : { "contents.component" : "resources" }},
{ "$count" : "count" }
]
- database: {{ mongodb_query_exporter_mongodb_sc_db_name }}
collection: lessons
metrics:
- name: sc_nexboard_lessons
type: gauge
help: 'The number of nexboard lessons'
value: count
overrideEmpty: true
emptyValue: 0
labels: []
constLabels:
mongodb_collection: lessons
longterm: 'true'
mode: pull
pipeline: |
[
{ "$match" : { "contents.component" : "neXboard" }},
{ "$project" : { "contents" : 1 }},
{ "$unwind" : { "path" : "$contents" }},
{ "$match" : { "contents.component" : "neXboard" }},
{ "$count" : "count" }
]
- database: {{ mongodb_query_exporter_mongodb_sc_db_name }}
collection: lessons
metrics:
Expand Down

0 comments on commit fceef51

Please sign in to comment.