Blog
More compute, less state: Why bursts break predictable systems
Traffic bursts can break systems that have plenty of capacity. Learn how cold caches, data movement, and hotspots hurt latency. See how to prepare.
Blog
Traffic bursts can break systems that have plenty of capacity. Learn how cold caches, data movement, and hotspots hurt latency. See how to prepare.
A vendor batch load starts earlier than expected. A market data feed spikes suddenly. An autoscaling policy adds another compute tier when demand crosses a threshold.
The capacity plan says the system should handle the traffic, and load testing appears to confirm it. Yet as the burst arrives, latency climbs, cache hit rates fall, and nodes begin moving data around the cluster while trying to serve requests. Recovery and background operations compete with live traffic, making performance increasingly difficult to predict. The system may have enough capacity to handle the workload, but a sudden increase in demand can change how effectively that capacity is used.
Under normal conditions, performance benefits from warm caches, stable data distribution, familiar access patterns, and enough available resources to accommodate routine fluctuations. During a burst, several of those conditions can change at once. New compute instances arrive without cached data, requests become concentrated on a handful of records, and background operations consume resources that applications need to process incoming traffic.
For infrastructure and application teams, the challenge is maintaining predictable performance while the system adjusts to increased demand. Capacity planning is a start, but understanding the behavior of the underlying data architecture during these transitions is just as important to maintaining performance.
Most systems are evaluated against a known workload. Teams establish a baseline, measure throughput and latency, add capacity, and run increasingly demanding tests. The results provide useful information about what the system can handle, although the tests often begin with conditions that are already favorable to performance. Caches are warm, data has settled across the cluster, and nodes are operating within their normal utilization range. Applications are accessing familiar data, often repeatedly, so the system benefits from locality and relatively predictable resource consumption.
A sudden surge in demand can change those conditions almost immediately.
Consider a trading firm whose models score market data as it arrives. A sharp market movement triggers an influx of pricing updates, market data, and trading activity. More calculations need to run, and trading systems begin issuing additional requests against shared data services. Autoscaling responds by provisioning compute instances to handle the increased workload. These instances may have plenty of processing capacity, but they arrive without the pricing data, historical market information, and other frequently accessed records that existing instances have accumulated in their caches.
As the new instances begin processing requests, they fetch data from shared services that are already handling increased traffic. At the same time, multiple trading strategies may be querying the same securities or position records. Contention grows, and the extra compute capacity doesn't necessarily translate into a proportional increase in useful throughput. The firm added processing resources, yet its models wait longer for data when timely market data matters most. That leaves its strategies trading on information that's already stale.
Conventional load testing can miss this behavior because they usually run after caches have warmed and data distribution has stabilized. A test that ramps up traffic gradually may produce very different results from one that introduces new compute capacity, changes the requested data, and increases traffic over a short interval. Both tests can reach the same request rate, but the system has considerably more work to do during the transition.
A system's performance under normal load depends partly on conditions that have developed over time.
Consider the role of caching. When frequently requested data is already in memory, applications avoid repeated trips to the underlying data store. High cache hit rates keep downstream traffic relatively low, and response times benefit from the shorter access path.
Data placement matters, too. Once a distributed system has settled into a stable configuration, it can spend most of its resources serving application requests. If nodes are added or removed, however, the cluster may need to redistribute records or partitions, consuming resources that would otherwise be available for incoming traffic.
Resource utilization adds another variable. A cluster operating comfortably below its limits has room for normal fluctuations and background maintenance. As utilization increases, queues and contention can cause response times to rise much faster than request volume. An individual storage device, network connection, or partition may become saturated even when aggregate utilization looks acceptable.
Predictable data access also contributes to steady-state performance. When applications repeatedly request the same records or objects, caches can serve more requests from memory, reducing traffic to the underlying data store and helping maintain consistent response times.
These conditions can become so familiar that teams stop accounting for them when evaluating performance. If every benchmark begins with a warm cache, the cost of populating that cache disappears from the measurements. Likewise, if data rarely moves during testing, the resource demands of rebalancing might not get much attention.
A burst can expose these dependencies because the workload changes while the system is still adjusting to its new operating conditions.
The effects of a sudden increase in demand extend beyond the additional requests themselves. Scaling activity, cache misses, resource contention, and changes in data access can all increase the amount of work the system has to perform.
Autoscaling adds resources when demand increases, but newly provisioned instances aren't necessarily ready to serve requests as efficiently as existing ones. An application instance with an empty local cache has to retrieve data that another instance might already have in memory. Those requests may go to a shared cache, a database, or another backing service.
When many instances start at once, their combined cache misses can create a substantial increase in downstream traffic. The backing service has to handle the original workload along with the additional requests generated as new instances populate their caches. This can produce a painful scaling transition. The infrastructure adds compute capacity to handle increased demand, but the new instances initially generate more work for services that may already be under pressure.
Eventually, frequently requested data becomes cached, hit rates improve, and downstream traffic settles. Until then, the system has to serve the burst while building the state that makes the additional capacity useful. The duration and cost of this transition depend on the cache architecture, the working set, and how much data the new instances need before they can operate efficiently.
Adding or removing nodes can also change where data resides. In distributed systems that partition data across nodes, membership changes can trigger rebalancing or redistribution. Records or partitions move to new locations, replicas may need to be created, and metadata needs to be updated to account for the new cluster configuration. These operations consume CPU, network bandwidth, storage I/O, and other resources.
During normal traffic, a cluster might have enough spare capacity to complete this work with minimal effect on application latency. During a burst, the same operations compete with a much larger volume of incoming requests.
The timing can make scaling more expensive than expected. The system adds resources because demand has increased, but then has to spend part of its available capacity reorganizing data to accommodate those resources.
How much work is required depends on the architecture. Some systems can add compute without redistributing stored data, while others need to move substantial amounts of information before the new nodes can carry their full share of traffic. For the latter, rebalancing behavior and its effect on foreground requests deserve attention during capacity planning.
As traffic increases, components that previously had ample headroom can approach their operating limits. CPU utilization may climb, network connections become busier, and storage devices receive more concurrent requests. Memory bandwidth and internal queues can also become points of contention.
The resulting latency increase isn't always proportional to the increase in traffic. A component operating near saturation can develop growing queues as requests arrive faster than it can process them. Even a modest increase in demand may cause substantially longer wait times, particularly at the tail of the latency distribution.
Aggregate utilization figures can hide these problems. A cluster might report acceptable average CPU usage while a subset of nodes or partitions is overloaded. Similarly, an application may have spare compute capacity while its database or network path has reached a limit.
Background activity complicates matters further. Replication, compaction, rebalancing, and recovery operations need resources of their own, and their scheduling can affect how quickly application requests are processed. The system may still have unused capacity somewhere, but unless it sits where requests are queued, it won't shorten the wait.
A burst can also change which data receives the most traffic. Returning to the trading example, a sharp market movement might cause several trading strategies to request pricing data, market information, and position records for the same securities. Under ordinary conditions, queries might be spread across thousands of instruments. But during a volatile trading period, attention can concentrate on a relatively small number of assets. This concentration can overload individual records, partitions, or nodes, even if the overall request volume remains within the system's tested limits.
Hotspots can also impact caching behavior. A workload that suddenly accesses previously cold records generates additional misses, while a concentrated workload can place unusual pressure on a small portion of the data infrastructure. The result depends on how the system distributes requests, manages concurrent access, and handles heavily requested data.
Two workloads with identical throughput can produce very different latency measurements when one distributes requests evenly, and the other concentrates them on a few heavily accessed records.
Failures are more difficult to handle when a system is already busy serving elevated traffic.
Imagine a node going offline while utilization is high, new instances are populating their caches, and the cluster is redistributing data. The remaining nodes have to keep processing application requests while also taking over work the failed node was handling. Depending on the architecture, recovery could involve rebuilding replicas, restoring data placement, reconnecting clients, or reconstructing application state. These activities require resources that are already under high demand.
A system with enough aggregate capacity for normal load may struggle because its remaining resources are committed to serving the burst. Recovery can increase contention further, extending the period of elevated latency.
The problem becomes more complicated in multi-site deployments. If an entire site becomes unavailable, another location may have to accept additional traffic. The effectiveness of that transition depends on where application state resides, whether the surviving site has access to the necessary data, and how much additional work is required before it can serve the displaced workload. A secondary site with available compute resources may still have delays if it has to populate caches or retrieve data before processing requests efficiently.
These scenarios are worth testing under burst conditions rather than assuming that recovery behavior observed during normal operation will hold during peak demand.
Adding capacity is a common response to performance problems, and often a useful one. Larger instances, additional cache nodes, and more spare resources can reduce the likelihood that a burst will push components into saturation. But each approach has limits:
Provisioning larger instances gives the system more headroom, but it doesn't eliminate the possibility of concentrated demand overwhelming an individual component. Nor does it necessarily address the additional work associated with moving data or rebuilding state.
Adding cache nodes increases available memory, for example, although the new nodes may initially be cold. Depending on the caching architecture, expanding the cache tier can also trigger redistribution or require additional coordination.
Cache warming can help new instances become productive sooner. Teams might preload frequently requested records, reuse historical access information, or gradually introduce traffic as caches fill.
The difficulty is predicting which data will be needed and when. Preloading the wrong records wastes resources, while aggressive warming can generate enough traffic to interfere with the workload the system is preparing to serve.
Operational procedures can grow around these limitations. For known peak events, teams can provision capacity ahead of time, restrict deployments, adjust traffic controls, or assign additional engineers to monitor the system. Financial trading platforms, retail systems during major sales, and applications with scheduled batch workloads may all benefit from this preparation.
Those measures can reduce risk, but they also add operational work for engineering teams. Engineers have to maintain separate procedures for peak events, test those procedures, and account for the possibility that demand will arrive earlier or behave differently than expected. Over time, the infrastructure may become dependent on excessive preparation to deliver consistent performance.
Caching illustrates the tradeoff particularly well. It can reduce latency and database load substantially, but applications that depend on high cache hit rates remain sensitive to changes in cache state. Adding more cache capacity helps with working-set size and throughput, although it doesn't eliminate cold-start behavior or the need to manage another layer.
The more components involved in serving a request, the more interactions teams need to consider when testing scaling and recovery.
Evaluating infrastructure for bursty workloads requires testing how the system behaves while conditions are changing.
Teams need to consider several questions when designing for this:
Cold capacity: How quickly can new instances begin serving requests at acceptable latency? What happens to downstream traffic when many instances start with empty caches?
Data movement: Does scaling require records or partitions to be redistributed? How much network, CPU, and storage capacity does that work consume while applications continue serving requests?
Resource contention: How do average and tail latency change as utilization rises? Can background operations proceed without causing unacceptable delays for application traffic?
Changing access patterns: What happens when traffic becomes concentrated on a small number of records or when requests suddenly target data that hasn't been cached?
Failure recovery: How quickly can the system recover from node or site failures while serving elevated traffic, and what happens to latency during recovery?
These questions call for tests that include scaling events, cold starts, changes in data access, and failures under load. Measuring throughput after the system has stabilized remains useful, but it provides only part of the information needed to understand peak performance.
Database architecture also affects how much additional work accompanies these transitions. Aerospike uses a distributed architecture for low-latency data access, with data partitioning, replication, and storage management handled within the database. When nodes join or leave, the database rebalances partitions itself, rather than relying on procedures the team has to plan and staff.
By default, it keeps indexes in memory and the data on flash, so teams can manage large datasets without relying on a separate external cache for every low-latency access requirement.
This approach can simplify the data path for applications that would otherwise depend on an external cache in front of a database. It also reduces the number of independently managed components whose state must be considered during scaling and recovery.
However, teams should still test Aerospike under the conditions their applications will encounter, including uneven access distributions, elevated utilization, node changes, and recovery activity. Performance during these events depends on workload characteristics, cluster configuration, and available resources.
For applications with sudden increases in demand, the most useful measurements are often taken during the transition itself: how quickly new capacity becomes productive, how much background work scaling creates, and whether tail latency remains within the application's requirements while the system adjusts.
For a deeper understanding and more insights, explore these additional resources.
See moreBlog
Blog
Blog
Blog