Functions for collecting context from various sources and merging into a collected context map.
Some example sources of context data:
Functions for collecting context from various sources and merging into a collected context map. Some example sources of context data: - environmental data about stack/sys/env/host names - request call graph context from prodigal - tracing span information
Dynamic context data bound in the local process. This is merged last into the collected context data, so it may override their entries.
Dynamic context data bound in the local process. This is merged last into the collected context data, so it may override their entries.
(clear!)
Remove all registered context collectors.
Remove all registered context collectors.
(collect)
Collect a merged context map by calling each registered context function.
Collect a merged context map by calling each registered context function.
(register! k f)
Register a function for collecting context data to include in events.
Returns the key k
.
The key uniquely identifies the function and will replace any existing
collector; it may also be used to remove it later with unregister!
.
Register a function for collecting context data to include in events. Returns the key `k`. The key uniquely identifies the function and will replace any existing collector; it may also be used to remove it later with `unregister!`.
(register-static! data)
(register-static! k data)
Register the provided map of data as a static set of context attributes which apply to all events in the process. This is useful for common patterns such as environmental sources of context. Returns the key identifying the registered collector.
Register the provided map of data as a static set of context attributes which apply to all events in the process. This is useful for common patterns such as environmental sources of context. Returns the key identifying the registered collector.
(unregister! k)
Remove the identified function from the collection of context collectors.
Remove the identified function from the collection of context collectors.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close