Metric data exporter to Prometheus.
Metric data exporter to Prometheus.
(http-server)
(http-server {:keys [host port executor registry otel-scope-enabled label?
default-aggregation-selector memory-mode default-handler]
:or {otel-scope-enabled true}})
Returns a Prometheus HTTP server which acts as a MetricReader
implementation. May take an option map as follows:
key | description |
---|---|
:host | The host to bind to (default: "0.0.0.0" ). |
:port | The port to bind to (default: 9464 ). |
:executor | ExecutorService to use for the Prometheus HTTP server (default: a fixed pool of 5 daemon threads). |
:registry | PrometheusRegistry to use for the HTTP server (default: new registry). |
:otel-scope-enabled | True if otel_scope_* attributes are generated (default: true). |
:label? | fn which takes the name of a resource attribute and returns true if it should be added as a label on each exported metric (default: no attributes added). |
:default-aggregation-selector | Function which takes an InstrumentType and returns default Aggregation (default: same as DefaultAggregationSelector/getDefault ). |
|:memory-mode
| Either :immutable-data
for thread safe or :reusable-data
for non thread safe (but reduced) data allocations (default: :reusable-data
).
|:default-handler
| Override for default HttpHandler.
Returns a Prometheus HTTP server which acts as a `MetricReader` implementation. May take an option map as follows: | key | description | |-------------------------------|-------------| |`:host` | The host to bind to (default: `"0.0.0.0"`). |`:port` | The port to bind to (default: `9464`). |`:executor` | `ExecutorService` to use for the Prometheus HTTP server (default: a fixed pool of 5 daemon threads). |`:registry` | `PrometheusRegistry` to use for the HTTP server (default: new registry). |`:otel-scope-enabled` | True if `otel_scope_*` attributes are generated (default: true). |`:label?` | fn which takes the name of a resource attribute and returns true if it should be added as a label on each exported metric (default: no attributes added). |`:default-aggregation-selector`| Function which takes an `InstrumentType` and returns default `Aggregation` (default: same as `DefaultAggregationSelector/getDefault`). |`:memory-mode` | Either `:immutable-data` for thread safe or `:reusable-data` for non thread safe (but reduced) data allocations (default: `:reusable-data`). |`:default-handler` | Override for default HttpHandler.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close