Skip to content

Latest commit

 

History

History
36 lines (26 loc) · 3.16 KB

metrics.md

File metadata and controls

36 lines (26 loc) · 3.16 KB

LaunchDarkly Relay Proxy - Metrics integrations

(Back to README)

You can configure the Relay Proxy to export statistics and route traces to Datadog, Stackdriver, and Prometheus. To learn about the available settings for each of these options, read Configuration.

The Relay Proxy supports the following metrics:

  • connections: The number of currently existing stream connections from SDKs to the Relay Proxy.
  • newconnections: The cumulative number of stream connections that have been made to the Relay Proxy since it started up.
  • requests: The cumulative number of requests received by all of the Relay Proxy's service endpoints (except for the status endpoint) since it started up.

You can filter metrics by the following tags:

  • platformCategory: The kind of SDK that the metric was generated by. The value of this tag can be:
  • env: The name of the LaunchDarkly environment. This is whatever name you gave to the environment in the configuration file, or, if you are using automatic configuration mode or offline mode, it is the actual name of the project and environment in LaunchDarkly. Example: MyApplication Staging
  • route: The request URL path. This can be any of the endpoint paths described in Service endpoints exactly as written there, so variables like {user} will appear as a placeholder rather than showing the actual value. Example: /sdk/evalx/{envId}/users/{user}
  • method: The HTTP method used for the request. Example: GET
  • userAgent: The user agent used to make the request, typically a LaunchDarkly SDK version. Example: "Node/3.4.0"

Note: Traces for stream connections will trace until the connection is closed.

Prometheus configuration

If you are using Prometheus, make sure your Prometheus configuration has a scrape_configs section defining the Relay Proxy as an endpoint. For instance, if the Relay Proxy is configured to expose Prometheus metrics on the default port of 8031:

scrape_configs:
  - job_name: 'ld-relay'
    scrape_interval: 10s
    static_configs:
      - targets: ['localhost:8031']