Skip to content

0.10.0

Compare
Choose a tag to compare
@release-drafter release-drafter released this 08 Jun 11:32
· 3972 commits to develop since this release
967d86e

Changes

This release primarily consists of changes to the Metrics core utility. Most notably:

  • The Metrics constructor now accepts a service parameter (alternatively the POWERTOOLS_SERVICE_NAME env var), as with the Tracer and Logger interfaces. This will create a default dimension named "service", with the value provided. Note that if you're already using the env var, this new dimension will start being recorded after upgrading to this version.
  • You can now specify the namespace by passing a namespace parameter to the Metrics constructor, or by supplying the POWERTOOLS_METRICS_NAMESPACE env var. This should be preferred to using the add_namespace method, which has been deprecated and will be removed in a future release.
  • To avoid repetition for the common task of recording metrics for Lambda cold starts, you can now achieve this by passing the capture_cold_start_metric parameter to the log_metrics decorator.

🌟New features and non-breaking changes

  • feat: add capture_cold_start_metric for log_metrics (#67) by @heitorlessa
  • improv: update metrics interface to resemble other core utils (#60) by @cakepietoast
  • improv: Better namespace/dimension handling for Metrics (#62) by @cakepietoast

🌟 Minor Changes

This release was made possible by the following contributors:

@cakepietoast, @danilohgds, @heitorlessa, @jfuss and @nmoutschen