Enterprise Telemetry Optimisation Strategies for Hybrid South African Estates
The billing email from the cloud provider landed five minutes before the incident report. R120k over budget on observability last month, and at the same time a major outage where alerts never fired because someone had quietly disabled…
Enterprise Telemetry Optimisation Strategies for Hybrid South African Estates
The billing email from the cloud provider landed five minutes before the incident report. R120k over budget on observability last month, and at the same time a major outage where alerts never fired because someone had quietly disabled a noisy rule. That combination — runaway telemetry costs and unreliable signals — is what forces teams to take Enterprise Telemetry Optimisation Strategies seriously instead of treating them as a “nice to have”.
This article walks through a practical optimisation approach for South African DevOps and SRE teams running hybrid estates: a mix of Prometheus, Loki, Tempo and Mimir, some legacy on-prem kit in Midrand or Durban, a bit of AWS in eu-west-1, possibly a local cloud provider, and a network that still has to deal with load-shedding and flaky last-mile connectivity.
Why Enterprise Telemetry Optimisation Strategies Matter Right Now
Telemetry volumes have exploded over the past few years. CNCF’s 2024 observability survey highlights that organisations are collecting more metrics, logs and traces than ever, and many report rising costs and complexity as a result.[1] At the same time, teams are under pressure to prove value: every rand spent on storing logs in Loki or high-cardinality metrics in Mimir needs to justify itself against POPIA compliance projects or business feature work.
Recent trends that make optimisation urgent in a South African context:
- ZAR cost pressure: Exchange rate volatility amplifies imported cloud costs. A noisy metrics label in eu-west-1 doesn’t just cost more storage; it costs more in rands.
- Data sovereignty and POPIA: Centralising telemetry in Europe is tempting, but personally identifiable information in logs and traces can’t casually cross borders.
- Load-shedding-aware operations: When data centres or office connectivity flap, your telemetry strategy must degrade gracefully, not fall over.
- Multi-tool complexity: Most enterprises now juggle Prometheus metrics, Loki logs, Tempo traces and Mimir for long-term retention, often via Grafana dashboards.
Optimisation in this world is not just “collect less”. It’s about making sure telemetry is:
- Designed around real decision points.
- Routed and stored in the right place at the right cost.
- Consumable under real network and power constraints.
Step 1: Start with the Incident, Not the Tool
An effective strategy starts by working backwards from incidents. Pick three recent production issues — one related to performance, one reliability, one security/compliance. For each, answer three questions:
- Which metrics, logs and traces actually helped us detect and resolve the issue?
- Which signals were missing or too noisy to be useful?
- Where did telemetry fail us (e.g. gaps due to network, power, or ingestion limits)?
In one Johannesburg payments platform, a card auth latency spike went undetected because the team had dashboards, but alerts were tied to a generic “http_request_duration_seconds” metric with no distinction between internal admin traffic and critical customer flows. After a nasty incident, they reworked telemetry around three core flows: card authorisation, wallet load, wallet cash-out.
From this sort of review, build a simple telemetry “bill of materials” per critical flow:
- Metrics: SLO-aligned, low-cardinality signals (e.g. success/fail, p95 latency, errors per second).
- Logs: Structured events for business operations and error conditions, scrubbed for PII.
- Traces: End-to-end paths for customer journeys, with sampling tuned to the flow’s risk.
This incident-first inventory becomes the baseline for all subsequent optimisation work. Anything you collect that is not clearly connected to at least one critical incident or SLO becomes a candidate for downsampling, deletion, or shorter retention.
Step 2: Taming Metrics Cardinality in Prometheus and Mimir
Metrics are often the quiet culprit behind exploding telemetry bills. A few unbounded labels (user ID, request path, free-form “tenant” strings) can multiply series counts and push Prometheus and Mimir into expensive territory.
Practical metrics optimisation strategies for a hybrid South African estate:
- Enforce label discipline: Ban user IDs, session IDs and raw URLs as labels. Route them to logs or traces instead.
- Bucket where possible: Bucket latency, sizes and monetary values instead of emitting raw numbers with ad-hoc labels.
- Split operational and business metrics: Business KPIs belong in a curated, low-volume namespace; operational telemetry can be more granular but bounded.
One pattern that works well is to explicitly mark SLO-related metrics with a label and then build aggregation rules in Mimir to store only the SLO slices long term:
groups:
- name: slo-recording-rules
interval: 60s
rules:
- record: http_request_duration_seconds:slo_bucket
expr: sum by (service, route, le) (
rate(http_request_duration_seconds_bucket{slo="true"}[5m])
)
This approach lets the team keep raw “slo=true” metrics in Prometheus for short-term detailed debugging (say 7–14 days) while Mimir stores only the aggregated buckets for 13 months to support trend analysis and annual reviews.
Another trick, especially when cross-region latency to eu-west-1 makes scraping remote targets flaky, is to introduce regional Prometheus instances (e.g. one in a Cape Town DC, one in Johannesburg) that feed an upstream Mimir cluster. If the link to Europe drops during load-shedding, local Prometheus still holds recent data and alerts fire via a local Alertmanager, while remote Mimir eventually backfills when connectivity returns.
Step 3: Log Volume and POPIA-aware Retention in Loki
Logs can easily dominate observability costs, especially in microservices-heavy architectures. At the same time, POPIA puts pressure on teams to avoid storing personal information indefinitely.
Enterprise Telemetry Optimisation Strategies for logs should cover three axes:
- Ingestion: Stop logging junk. Reduce verbosity in hot paths. Switch to structured logs with clear fields.
- Routing: Send high-value security and audit logs to high-retention storage; send noisy debug logs to short-term or cheaper storage classes.
- Retention: Retain different log streams for different durations, based on risk and regulatory requirements.
With Loki, a common setup is to define multiple tenants or streams corresponding to log classes: “app-prod”, “audit”, “security”, “debug”. Then apply different retention policies per tenant. For example, “audit” logs might need 5 years; “debug” logs can be safely dropped after 7 days.
Teams should also introduce POPIA-aware log scrubbing at ingestion — stripping or hashing IDs, card numbers, personal references. Any log line containing PII should either be redacted or routed to a compliant, access-controlled store.
On the query side, optimisation is as much about operators as data. A common anti-pattern during incident debugging is to run wide, unfiltered regex queries across massive log streams. Encourage engineers to design Loki queries that lean on labels first, regex second:
{app="payments", level="error"} |= "AUTH_FAILED"
This pattern is materially cheaper than:
{cluster="prod"} |~ "AUTH_FAILED|DECLINED|ERROR"
Tagging and filtering, combined with disciplined sampling of debug logs, keeps Loki usable and affordable under ZAR cost pressure.
Step 4: Traces as a Scalpel, Not a Fire Hose, in Tempo
Full-fidelity tracing across all services and all requests is rarely necessary and often unaffordable. For Tempo, optimisation revolves around sampling, enrichment, and access patterns.
Some practical strategies:
- Adaptive sampling: Increase sampling rates for erroring or high-latency paths, decrease for clean, low-risk flows.
- Business-key annotations: Tag traces with business identifiers (e.g. “transaction_type=card_auth”, “region=ZA”) but avoid personal data.
- Split cold and hot storage: Keep “hot” traces (recent, error-heavy) in higher-performance storage; archive the rest to cheaper backends.
Modern tracing libraries and OpenTelemetry-based setups support head-based sampling and tail