track collection size
I would like to be able to track the size of our collections (i.e. # of records, total disk size) over time. It would be ideal if there was an automated way to do this with Atlas, perhaps with Charts ?
5
votes
Chris
shared this idea
-
Tapani commented
While it's not automated, you can get a point-in-time snapshot with collStats: https://www.mongodb.com/docs/manual/reference/operator/aggregation/collStats/
You could solve this over time by writing a scheduled trigger than takes a snapshot at the desired interval and stores it in a collection. Then it's a matter of creating a Charts view of that collection.