* Enable autogeneration for default runtime metrics list in collectors tests according to Go version
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Adapt withDefaultRuntimeMetrics function to work regardless of the Go version
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Autogenerate go collector test for go1.23
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Modify gen_go_collector_set.go to please linter and regenerate files
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Simplify gen_go_collector_set.go logic by modifying func computeMetricsList
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Slight simplification of withDefaultRuntimeMetrics func
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
* Refactor withDefaultRuntimeMetrics with generated default runtime metrics subsets
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
---------
Signed-off-by: Arianna Vespri <arianna.vespri@yahoo.it>
Now that 1.23 is out, update the supported version matrix to Go 1.21
through 1.23. This allows us to start using `log/slog`.
* Update generated tests.
Signed-off-by: SuperQ <superq@gmail.com>
* Removeed go_memstat_lookups_total which was always set to 0; added runtime/metrics info to memstat metric helps.
I know we ideally should not remove any metric from default list, but
this one is always zero, so let's save everyone's money.
Signed-off-by: bwplotka <bwplotka@gmail.com>
* Update prometheus/go_collector.go
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>
---------
Signed-off-by: bwplotka <bwplotka@gmail.com>
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
* go collector: add default metrics acceptance tests; adding more context to HELP
The context and details for help were possible thanks to @vesari research, thanks for that!
Signed-off-by: bwplotka <bwplotka@gmail.com>
* Update prometheus/go_collector.go
Co-authored-by: Arianna Vespri <36129782+vesari@users.noreply.github.com>
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>
---------
Signed-off-by: bwplotka <bwplotka@gmail.com>
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>
Co-authored-by: Arianna Vespri <36129782+vesari@users.noreply.github.com>
* collectors/version: Move to collectors directory and remove unrelated code.
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
* examples: Add Version Collector example
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
---------
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
* Add Go 1.21 support
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
* Update README.md
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
---------
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
* Fix convention violating names for generated collector metrics
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
* Add new Go collector example
Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>
* Renamed files.
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>
* gocollector: Added options to Go Collector for diffetent collections.
Fixes https://github.com/prometheus/client_golang/issues/983
Also:
* fixed TestMemStatsEquivalence, it was noop before (:
* Removed gc_cpu_fraction metric completely, since it's not working completely for Go1.17+
Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>