-
Notifications
You must be signed in to change notification settings - Fork 451
PMM-8770 enable safe metrics collection #389
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PMM-8770 enable safe metrics collection #389
Conversation
In my local I have go 1.17 so the sum was different and tests were failing.
Now discovering mode automatically search for all databases and all collections. It might receive a filter list and ignores system collections.
| var stats []bson.M | ||
| if err = cursor.All(d.ctx, &stats); err != nil { | ||
| d.logger.Errorf("cannot get $indexStats for collection %s.%s: %s", database, collection, err) | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unnecessary whitespace
main.go
Outdated
| DisableDiagnosticData bool `name:"no-collector.diagnosticdata" help:"Disable collecting metrics from getDiagnosticData"` | ||
| DisableReplicasetStatus bool `name:"no-collector.replicasetstatus" help:"Disable collecting metrics from replSetGetStatus"` | ||
| EnableDBStats bool `name:"collector.dbstats" help:"Enable collecting metrics from dbStats"` | ||
| CollStatsLimit int `name:"collector.collstats-limit" help:"Enable collstats and indexstats collector only if there are less than <n> collections. -1=No limit" default:"100"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would set no limit by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And if we need limit in PMM set it there.
|
Please fix all golint issues |
PMM-8770: Enable safe Collection metrics collection for MongoDB
Feature Build: PR #2154