Air traffic control
Voice servers that don't drop a call
A radio server reworked to carry far more simultaneous calls on the same hardware, with memory use cut from 70% to 12%.
Results
- simultaneous calls, up from 600
- 1,000+
- faster overall
- 2×
- memory use, down from 70%
- 12%
The challenge
A supplier of air traffic communication systems couldn't meet the demands of a major customer: its radio server ran out of capacity when too many voice streams arrived at once.
Finding where the time went
A server that falls over under load is rarely slow everywhere. It's slow in one path that every call goes through. Before changing a line, we read through the source and measured where the server actually spent its time and memory. Most of the cost sat in the routines that mix audio for conference calls, which run for every active stream, many times a second.
Rebuilding the hot path
We redesigned those conferencing routines so the work per stream grows far more gently as calls are added, and rebuilt the internal data structures around how the server really uses them. Memory had been reserved for worst cases that rarely happened. Allocating it only when a condition called for it took usage from 70% of the machine down to 12%.
Making failure boring
Air traffic voice can't afford a crash at the busiest moment of the day. We added more than 120 failure-control mechanisms, so a bad stream or an unexpected state is contained and handled instead of taking the whole server down with it.
What changed
The same hardware now carries more than 1,000 simultaneous calls instead of 600, runs twice as fast overall and keeps most of its memory free for growth. The customer's demands were met without buying a single new machine.
What we built
- An in-depth analysis of the server's source code to find the real bottlenecks
- Redesigned audio conferencing routines, the hottest path in the system
- More than 120 new failure-control mechanisms
- Rebuilt internal data structures and smarter memory allocation
Built with
- C
- Linux
- Data structures
Have something similar in mind?
Tell us what you're working on and we'll come back with a clear next step.