Creates an HTTP server that exposes the metrics from the given registry at the /metrics endpoint on the specified port. Passing port 0 lets the operating system choose an available port; the returned endpoint's PrometheusEndpoint.url includes the actual bound port when available.
Value parameters
port
Port to listen on (default: 9090)
registry
Prometheus collector registry containing metrics
Attributes
Returns
Right(endpoint) on success, Left(error) if port unavailable or other failure