Skip to content

Commit

Permalink
BC-8575 refine news metrics by targetModel
Browse files Browse the repository at this point in the history
  • Loading branch information
Loki-Afro committed Dec 16, 2024
1 parent 09b9e04 commit 269b488
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions ansible/roles/mongodb_query_exporter/templates/values.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -927,14 +927,25 @@ aggregations:
value: count
overrideEmpty: true
emptyValue: 0
labels: []
labels:
- type
constLabels:
mongodb_collection: news
longterm: 'true'
mode: pull
pipeline: |
[
{ "$count" : "count" }
{
"$group": {
"_id": "$targetModel",
"groupCount": { "$sum": 1 }
}
},
{
"$project": {
"type": "$_id",
"groupCount": 1
}
}
]

- database: {{ mongodb_query_exporter_mongodb_sc_db_name }}
Expand Down

0 comments on commit 269b488

Please sign in to comment.