Skip to content

feat: register DNS in the service catalog #44

Description

@kevwilliams

Summary

The DNS component needs to be integrated into the Datum Cloud service catalog to enable discovery, activation, and billing. Mirrors the work done for Network Services (datum-cloud/network-services-operator#155), but with metering tailored to DNS consumption signals. Three core components:

1. Service Registration

Create a Service resource establishing DNS visibility in the catalog with relevant metadata — display name, description, and Published phase designation. Group/resources live under dns.networking.miloapis.com/v1alpha1 (DNSZone, DNSRecordSet, DNSZoneClass).

2. Metering Configuration

Establish a ServiceConfiguration resource specifying billable metrics for DNS. Unlike the edge proxy (request/byte counts), DNS consumption is driven by authoritative query traffic and managed inventory:

  • DNS queries resolved — primary consumption metric; count of authoritative queries answered by the backend (PowerDNS), ideally broken down by rcode (NOERROR / NXDOMAIN / SERVFAIL) and optionally by record type.
  • Hosted zones — number of active DNSZone resources (per-zone footprint charge).
  • Record sets managed — count of DNSRecordSet resources (inventory metric).
  • Query types / advanced routing (future / optional) — distinguish standard lookups from any premium routing (geo/latency/alias-style) if/when introduced.

We already emit zone/recordset inventory and status metrics via config/milo/resource-metrics/policies/dns-metrics.yaml (dns_zone_info, dns_record_set_info, etc.). The inventory metrics here can build on that; the query-volume metric is the new signal that needs a source (see below).

3. Usage Pipeline Integration

Investigate mechanisms for extracting DNS query signals and integrating with the billing pipeline:

  • Query-volume source: PowerDNS exposes query statistics via its API (/api/v1/servers/localhost/statistics) and Prometheus metrics; evaluate scraping these from the agent sidecar vs. a dedicated exporter. Determine how to attribute queries back to a tenant/zone (per-zone counters, log-based attribution, or dnsdist tagging).
  • CloudEvents emission for billing-pipeline compatibility.
  • Buffering, batching, and reliability for data-plane-to-pipeline transmission (the authoritative servers are in the downstream/agent role).

Both resources should be packaged as a Kustomize component following existing compute/network-services patterns, located in config/components/ (this repo does not have a config/components/ dir yet — it will be created).


Acceptance Criteria

  • DNS service appears in the platform catalog in Published phase
  • Metering covers query volume + hosted-zone and record-set inventory
  • Resources packaged as a service-catalog Kustomize component under config/components/
  • DNS query-usage collection source (PowerDNS stats/exporter) identified and per-tenant attribution approach documented
  • Usage event collection and CloudEvents emission approach documented

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions