0

Is it possible to get the number of hits on single collection as well as bandwith usage in mongodb ?

3
  • Interesting question (+1). The NoSQL bandwagon is truly grinding to a shuddering halt under the weight of questions like this - these systems are great for astronaut programmers who work for large web-based companies and don't have to or want to think about instrumentation. The reality is that without instrumentation, databases are little better than bitbuckets.
    – Vérace
    Commented Nov 5, 2019 at 12:52
  • contd... You might want to try PostgreSQL's JSONB functionality in conjunction with the stats available. Not sure how it works with JSON tables - AFAIK, JSONB collections are pretty much like normal tables. If you decide to try this route, you may want to check beforehand - I wouldn't want to give you a bum steer! p.s. welcome to the forum! :-)
    – Vérace
    Commented Nov 5, 2019 at 12:52
  • There are a number of collection-level metrics and index usage stats available in MongoDB, but hits and bandwidth sound like metrics more applicable to a web UI/API. Do these links cover the sort of metrics you are after? If not, please edit your question to include more specific examples.
    – Stennie
    Commented Nov 11, 2019 at 6:24

1 Answer 1

1

There is a documentation section for Analyzing Performance, another for Monitoring, and one specifically for free monitoring.

You can also run the command db.serverStatus() to retrieve server statistics.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.