This repository has been archived by the owner on Oct 14, 2024. It is now read-only.
Releases: randlabs/go-metrics
Releases · randlabs/go-metrics
Release v1.3.5
Release v1.3.4
- Updated dependencies.
Release v1.3.3
- Updated dependencies.
Release v1.3.2
- Updated dependencies.
- Minor improvements.
Release v1.3.1
- Increased metrics endpoint write timeout.
- Updated dependencies.
Release v1.3.0
- Updated dependencies.
- The library now required Go v1.19+.
- Added listener error callback to notify the app if the listening loop exits with an error.
- Added handler for HEAD request on
/health
endpoint. - Also added a proper
content-type
to the/health
endpoint which detects a JSON or plain text.
Release v1.2.0
IMPORTANT: This is a breaking change.
- Health check callback now must return a string instead of an object and the value will be send directly as the output.
Reason for this change
Previously, the user had to return an object or struct, and ensure it contained a copy of the internal application state, usually protected by a mutex to avoid concurrent reading and writing.
If slices, maps or pointers were present, a deep copy was required in order to avoid accessing shared data out of the mutex.
Now, to avoid confusion, the callback must, for e.g., encode a struct as a JSON string and return it.
Release v1.1.2
- Updated dependencies. Mainly
go-webserver
.
Release v1.1.1
- Updated dependencies.
Release v1.1.0
IMPORTANT NOTE: This release contains some breaking changes.
CreateMetricsWebServer
was renamed toCreateMetricsController
and returns aController
object instead ofMetricsWebServer
.Stop
was renamed toDestroy
.- New fields added to
Options
struct.
- Added support for an external web server.
- Improved support for middlewares and endpoint protection.