View Source Pacer.Config (Pacer v0.1.6)
The Pacer.Config module provides functions for extracting user-provided configuration values specific to Pacer.
Summary
Functions
Fetches configuration options for extending the metadata provided in the
[:pacer, :execute_vertex, :start | :stop | :exception]
events for batched resolvers.
Takes the batch_telemetry_options configuration, invoking mfa-style config if available,
and converts the batch_telemetry_options keyword list into a map that gets merged into
the metadata for the [:pacer, :execute_vertex, :start | :stop | :exception]
events for
batched resolvers.
Functions
Fetches configuration options for extending the metadata provided in the
[:pacer, :execute_vertex, :start | :stop | :exception]
events for batched resolvers.
The configuration must be set under the key :batch_telemetry_options
at the application
level (i.e., Application.get_env(:pacer, :batch_telemetry_options)
) or when defining the
workflow itself (use Pacer.Workflow, batch_telemetry_options: <opts>
).
The batch_telemetry_options defined by the user must be either:
- a keyword list, or
- a {module, function, args} mfa tuple; when invoked, this function must return a keyword list
The keyword list of values returned by the mfa-style config, or the hardcoded keyword list, is fetched and converted into a map that gets merged into the telemetry event metadata for batched resolvers.
Takes the batch_telemetry_options configuration, invoking mfa-style config if available,
and converts the batch_telemetry_options keyword list into a map that gets merged into
the metadata for the [:pacer, :execute_vertex, :start | :stop | :exception]
events for
batched resolvers.