This resource is part of the v1alpha1 API and is subject to change. Fields and behavior may change in future releases.
Identity
| |
|---|
| Group | telemetry.miloapis.com |
| Version | v1alpha1 |
| Kind | ExportPolicy |
| Scope | Project |
Overview
An ExportPolicy sends telemetry data collected on the Datum Cloud platform to a third-party telemetry platform. You define one or more sources that select which telemetry data to publish, and one or more sinks that describe where to send it and how to authenticate. Each sink references the sources it should forward.
Use an ExportPolicy when you want your platform metrics to land in an external observability system, for example by pushing them to an endpoint that speaks the Prometheus Remote Write protocol. The control plane continuously evaluates the deployed exporters and reconciles them to match the policy. Note that delivery is not guaranteed, especially when a sink’s endpoint is unavailable, and telemetry matching multiple sources is not de-duplicated.
Spec fields
| Field | Type | Required | Description |
|---|
spec.sources | []Object | Yes | The telemetry sources to publish to the configured sinks. Multiple sources may be defined; matching data is not de-duplicated across sources. |
spec.sources[].name | string | Yes | A unique name for the source within the policy. Must be a valid DNS label. |
spec.sources[].metrics | Object | No | Selects metric data to retrieve from the Datum Cloud platform. |
spec.sources[].metrics.metricsql | string | No | A MetricSQL query used to select and filter metric data to publish (e.g. {service_name="networking.miloapis.com", resource_kind="Gateway"}). See the MetricSQL reference. |
spec.sinks | []Object | Yes | How telemetry data should be sent to third-party platforms. |
spec.sinks[].name | string | Yes | A name for the sink that is unique within the policy. |
spec.sinks[].sources | []string | Yes | The names of the sources whose data should be sent to this sink. |
spec.sinks[].target | Object | Yes | The target the sink delivers telemetry to. |
spec.sinks[].target.prometheusRemoteWrite | Object | No | Publishes telemetry using the Prometheus Remote Write protocol. |
spec.sinks[].target.prometheusRemoteWrite.endpoint | string | Yes | The HTTP endpoint to publish telemetry data to. |
spec.sinks[].target.prometheusRemoteWrite.authentication | Object | No | How the sink authenticates with the endpoint (e.g. basicAuth). |
spec.sinks[].target.prometheusRemoteWrite.batch | Object | Yes | How telemetry is batched before sending. Defaults to every 5 seconds or 500 entries, whichever comes first. |
spec.sinks[].target.prometheusRemoteWrite.retry | Object | Yes | Retry behavior when requests to the endpoint fail. Retries are not guaranteed to succeed if the endpoint is unavailable or misconfigured. |
Status fields (read-only)
| Field | Type | Description |
|---|
status.conditions | []Object | Summary status for the policy as a whole. Known condition types: Ready. |
status.sinks | []Object | Per-sink status information for each configured sink. |
Usage
apiVersion: telemetry.miloapis.com/v1alpha1
kind: ExportPolicy
metadata:
name: gateway-metrics
spec:
sources:
- name: gateway-metrics
metrics:
metricsql: '{service_name="networking.miloapis.com", resource_kind="Gateway"}'
sinks:
- name: prometheus
sources:
- gateway-metrics
target:
prometheusRemoteWrite:
endpoint: https://metrics.example.com/api/v1/write
datumctl apply -f exportpolicy.yaml --project my-project
datumctl get exportpolicies --project my-project
datumctl describe exportpolicy gateway-metrics --project my-project
Run datumctl explain exportpolicies --recursive to see the full, live field tree for this resource.