The Service Map for APM is here!

Ambassador API Gateway

StatsD Check StatsD Check

Overview

Get metrics from Ambassador in real time to:

  • Visualize the performance of your microservices

  • Understand the impact of new versions of your services as you use Ambassador to do a canary rollout

snapshot

Setup

By default, Ambassador installs a statsd sidecar on its pod. This sidecar forwards statsd metric to any Kubernetes service named statsd-sink.

  1. Create a file datadog-statsd-sink.yaml with the following configuration, replacing the API key below with your own API key:
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
 name: statsd-sink
spec:
 replicas: 1
 template:
   metadata:
     labels:
       service: statsd-sink
   spec:
     containers:
     - name: statsd-sink
       image: datadog/docker-dd-agent:latest
       ports:
         - containerPort: 8125
           name: dogstatsdport
           protocol: UDP
       env:
         - name: API_KEY
           value: <YOUR_DATADOG_API_KEY>
         - name: KUBERNETES
           value: "yes"
         - name: SD_BACKEND
           value: docker
     restartPolicy: Always
status: {}
---
apiVersion: v1
kind: Service
metadata:
 labels:
   service: statsd-sink
 name: statsd-sink
spec:
 ports:
 - protocol: UDP
   port: 8125
   name: dogstatsdport
 selector:
   service: statsd-sink
  1. Deploy the agent to Kubernetes:
kubectl apply -f datadog-statsd-sink.yaml
  1. As soon as some traffic flows through Ambassador, your metrics should appear.

Data Collected

Metrics

envoy.listener.downstream_cx_total
(count)
Total connections
shown as connection
envoy.listener.downstream_cx_destroy
(count)
Total destroyed connections
shown as connection
envoy.listener.downstream_cx_active
(gauge)
Total active connections
shown as connection
envoy.listener.downstream_cx_length_ms
(gauge)
Connection length milliseconds
shown as millisecond
envoy.listener_manager.listener_added
(count)
Total listeners added (either via static config or LDS)
shown as host
envoy.listener_manager.listener_modified
(count)
Total listeners modified (via LDS)
shown as host
envoy.listener_manager.listener_removed
(count)
Total listeners removed (via LDS)
shown as host
envoy.listener_manager.listener_create_success
(count)
Total listener objects successfully added to workers
shown as host
envoy.listener_manager.listener_create_failure
(count)
Total failed listener object additions to workers
shown as host
envoy.listener_manager.total_listeners_warming
(gauge)
Number of currently warming listeners
shown as host
envoy.listener_manager.total_listeners_active
(gauge)
Number of currently active listeners
shown as host
envoy.listener_manager.total_listeners_draining
(gauge)
Number of currently draining listeners
shown as host
envoy.http.downstream_cx_total
(count)
Total connections
shown as connection
envoy.http.downstream_cx_ssl_total
(count)
Total TLS connections
shown as connection
envoy.http.downstream_cx_http1_total
(count)
Total HTTP/1.1 connections
shown as connection
envoy.http.downstream_cx_websocket_total
(count)
Total WebSocket connections
shown as connection
envoy.http.downstream_cx_http2_total
(count)
Total HTTP/2 connections
shown as connection
envoy.http.downstream_cx_destroy
(count)
Total connections destroyed
shown as connection
envoy.http.downstream_cx_destroy_remote
(count)
Total connections destroyed due to remote close
shown as connection
envoy.http.downstream_cx_destroy_local
(count)
Total connections destroyed due to local close
shown as connection
envoy.http.downstream_cx_destroy_active_rq
(count)
Total connections destroyed with active requests
shown as connection
envoy.http.downstream_cx_destroy_local_active_rq
(count)
Total connections destroyed locally with active requests
shown as connection
envoy.http.downstream_cx_destroy_remote_active_rq
(count)
Total connections destroyed remotely with active requests
shown as connection
envoy.http.downstream_cx_active
(gauge)
Total active connections
shown as connection
envoy.http.downstream_cx_ssl_active
(gauge)
Total active TLS connections
shown as connection
envoy.http.downstream_cx_http1_active
(gauge)
Total active HTTP/1.1 connections
shown as connection
envoy.http.downstream_cx_websocket_active
(gauge)
Total active WebSocket connections
shown as connection
envoy.http.downstream_cx_http2_active
(gauge)
Total active HTTP/2 connections
shown as connection
envoy.http.downstream_cx_protocol_error
(count)
Total protocol errors
shown as error
envoy.http.downstream_cx_length_ms
(gauge)
Connection length milliseconds
shown as millisecond
envoy.http.downstream_cx_rx_bytes_total
(count)
Total bytes received
shown as byte
envoy.http.downstream_cx_rx_bytes_buffered
(gauge)
Total received bytes currently buffered
shown as byte
envoy.http.downstream_cx_tx_bytes_total
(count)
Total bytes sent
shown as byte
envoy.http.downstream_cx_tx_bytes_buffered
(gauge)
Total sent bytes currently buffered
shown as byte
envoy.http.downstream_cx_drain_close
(count)
Total connections closed due to draining
shown as connection
envoy.http.downstream_cx_idle_timeout
(count)
Total connections closed due to idle timeout
shown as connection
envoy.http.downstream_flow_control_paused_reading_total
(count)
Total number of times reads were disabled due to flow control
shown as occurrence
envoy.http.downstream_flow_control_resumed_reading_total
(count)
Total number of times reads were enabled on the connection due to flow control
shown as occurrence
envoy.http.downstream_rq_total
(count)
Total requests
shown as request
envoy.http.downstream_rq_http1_total
(count)
Total HTTP/1.1 requests
shown as request
envoy.http.downstream_rq_http2_total
(count)
Total HTTP/2 requests
shown as request
envoy.http.downstream_rq_active
(gauge)
Total active requests
shown as request
envoy.http.downstream_rq_response_before_rq_complete
(count)
Total responses sent before the request was complete
shown as response
envoy.http.downstream_rq_rx_reset
(count)
Total request resets received
shown as request
envoy.http.downstream_rq_tx_reset
(count)
Total request resets sent
shown as request
envoy.http.downstream_rq_non_relative_path
(count)
Total requests with a non-relative HTTP path
shown as request
envoy.http.downstream_rq_too_large
(count)
Total requests resulting in a 413 due to buffering an overly large body
shown as request
envoy.http.downstream_rq_1xx
(count)
Total 1xx responses
shown as response
envoy.http.downstream_rq_2xx
(count)
Total 2xx responses
shown as response
envoy.http.downstream_rq_3xx
(count)
Total 3xx responses
shown as response
envoy.http.downstream_rq_4xx
(count)
Total 4xx responses
shown as response
envoy.http.downstream_rq_5xx
(count)
Total 5xx responses
shown as response
envoy.http.downstream_rq_ws_on_non_ws_route
(count)
Total WebSocket upgrade requests rejected by non WebSocket routes
shown as request
envoy.http.downstream_rq_time
(gauge)
Request time milliseconds
shown as millisecond
envoy.cluster_manager.cluster_added
(count)
Total clusters added (either via static config or CDS)
shown as node
envoy.cluster_manager.cluster_modified
(count)
Total clusters modified (via CDS)
shown as node
envoy.cluster_manager.cluster_removed
(count)
Total clusters removed (via CDS)
shown as node
envoy.cluster.upstream_cx_total
(count)
Total connections
shown as connection
envoy.cluster.upstream_cx_active
(gauge)
Total active connections
shown as connection
envoy.cluster.upstream_cx_http1_total
(count)
Total HTTP/1.1 connections
shown as connection
envoy.cluster.upstream_cx_http2_total
(count)
Total HTTP/2 connections
shown as connection
envoy.cluster.upstream_cx_connect_ms
(gauge)
Connection establishment milliseconds
shown as millisecond
envoy.cluster.upstream_cx_length_ms
(gauge)
Connection length milliseconds
shown as millisecond
envoy.cluster.upstream_cx_rx_bytes_total
(count)
Total received connection bytes
shown as byte
envoy.cluster.upstream_cx_rx_bytes_buffered
(gauge)
Received connection bytes currently buffered
shown as byte
envoy.cluster.upstream_cx_tx_bytes_total
(count)
Total sent connection bytes
shown as byte
envoy.cluster.upstream_cx_tx_bytes_buffered
(gauge)
Send connection bytes currently buffered
shown as byte
envoy.cluster.upstream_rq_total
(count)
Total requests
shown as request
envoy.cluster.upstream_rq_active
(gauge)
Total active requests
shown as request
envoy.cluster.upstream_rq_pending_total
(count)
Total requests pending a connection pool connection
shown as request
envoy.cluster.upstream_rq_pending_active
(gauge)
Total active requests pending a connection pool connection
shown as request
envoy.cluster.membership_change
(count)
Total cluster membership changes
shown as event
envoy.cluster.membership_healthy
(gauge)
Current cluster healthy total (inclusive of both health checking and outlier detection)
shown as node
envoy.cluster.membership_total
(gauge)
Current cluster membership total
shown as node
envoy.cluster.config_reload
(count)
Total API fetches that resulted in a config reload due to a different config
shown as request
envoy.cluster.update_attempt
(count)
Total cluster membership update attempts
shown as occurrence
envoy.cluster.update_success
(count)
Total cluster membership update successes
shown as success
envoy.cluster.update_failure
(count)
Total cluster membership update failures
shown as error
envoy.cluster.version
(gauge)
Hash of the contents from the last successful API fetch
shown as item
envoy.cluster.max_host_weight
(gauge)
Maximum weight of any host in the cluster
shown as item

Events

The Ambassador check does not include any events at this time.

Service Checks

The Ambassador check does not include any service checks at this time.

Troubleshooting

Need help? Contact Datadog Support.


Mistake in the docs? Feel free to contribute!