The default module export refers to a performance metrics factory configured using the runtime config from src/config.
To configure it, define a perf property within your config file.
There is a possibility to create a performance metrics factory with a custom configuration. It allows having several
differently configured performance metrics factories at the same time.
This is achieved using the perf method, which acquires a new config as the first argument.
core/perf
This module provides API to send performance metrics.
Usage
Configuration
There are two ways to use this module: with a custom configuration or default one.
Default configuration
The default module export refers to a performance metrics factory configured using the runtime config from
src/config
. To configure it, define aperf
property within your config file.config
some-file.ts
Configuration interface
Custom configuration
There is a possibility to create a performance metrics factory with a custom configuration. It allows having several differently configured performance metrics factories at the same time.
This is achieved using the
perf
method, which acquires a new config as the first argument.Time metrics
Currently, the module supports only the time metrics core/perf/timer.