Cloudflare Cuts DNS Update Delays by Half and Reduces Memory Usage by 85% With New Optimizations

news
Cloudflare Cuts DNS Update Delays by Half and Reduces Memory Usage by 85% With New Optimizations

Cloudflare has improved the efficiency of its DNS infrastructure, reducing the time required to process domain changes by more than half while cutting peak memory consumption by approximately 85%.

The improvements come from changes to the company's Zone Builder system, which processes DNS records and settings before distributing updated information across its network.

According to Cloudflare's engineering results, median processing delays have fallen from 7.7 seconds to 3.3 seconds, while average memory usage has dropped from 49 GiB to approximately 7 GiB.

These changes are particularly important as Cloudflare handles approximately 800 DNS related events every second, compared with roughly 250 record changes per second in 2022.

Cloudflare Reduces Unnecessary DNS Rebuilding

Previously, changing certain domain settings could trigger a complete rebuild of the domain's DNS information.

For large domains containing millions of records, this process required considerable memory and processing resources, even when only a small amount of information had changed.

Cloudflare has introduced a targeted rebuilding system that identifies which records and settings actually require updating.

For example, changing SSL settings can now trigger updates to specific records and metadata instead of rebuilding the entire domain.

The company has also improved how its system identifies changes, allowing it to select smaller operations when their correctness can be established.

Over a 24 hour measurement period, approximately 93% of builds avoided rebuilding the complete zone.

DNS Processing Becomes Faster With Lower Memory Requirements

Cloudflare also combined its previous scheduling systems into a unified scheduler capable of managing several changes to the same domain together.

This reduces repeated processing while allowing unrelated operations to continue without unnecessary delays.

The improvements produced measurable results.

MetricPrevious systemOptimized system
Median processing delay7.7 seconds3.3 seconds
Average memory usage49 GiB7 GiB
Peak memory usage79 GiB12 GiB
Largest observed high latency spike14.6 minutes1.21 minutes

The changes also improve consistency when processing large numbers of DNS updates.

Cloudflare continues using complete zone rebuilds when necessary, particularly when a domain is first published or when the system cannot safely identify a smaller operation.

Importantly, these measurements cover processing until data is written to Cloudflare's Quicksilver system, not final distribution across its entire network.

The optimizations demonstrate how reducing unnecessary processing can improve infrastructure performance without requiring additional hardware.

Discover: News

Discussion (0)

Be the first to comment.