← Back to Blog

How I Built a Performance Testing Framework That Scales to 75K Devices

When you’re building a digital surgery platform, performance isn’t a nice-to-have — it’s a safety requirement. Devices in operating rooms need to sync reliably, workflows need to complete within strict time windows, and the system needs to handle scale without degradation.

I was tasked with building an end-to-end performance testing framework from scratch. Here’s how it went.

The Problem

The existing performance testing setup had three critical gaps:

The result was a performance testing system that gave false confidence. Tests passed, but nobody knew if the system would hold under real load.

The Solution

I rebuilt the framework around three core principles:

Realistic SQLite Workload Generation

Instead of firing raw API calls, the framework generates realistic SQLite databases that mirror actual device data. Each simulated device has a complete data profile — configuration, surgical records, sync history, and metadata. This means the system under test processes the same data shapes and volumes it sees in production.

Adaptive Concurrency with Parallel Device Workers

The framework runs parallel device workers that simulate concurrent device operations. Concurrency levels are configurable and can ramp up dynamically to stress specific subsystems. Each worker operates independently, maintaining its own state and sync cycle, just like real devices.

DB-Primary Polling with API Fallback

One of the biggest wins was rethinking how the framework checks workflow progress. Instead of polling the API for status updates (which itself creates load), the framework queries the database directly for state changes and falls back to API calls only when necessary. This reduced API calls during test execution by 95%, meaning the framework measures the system’s actual performance without inflating it with monitoring overhead.

What We Measure

Every test run produces detailed metrics:

The Result

The framework scaled the platform’s validated capacity from 30 devices to 75,000+ devices. Key outcomes:

The framework didn’t just test performance — it became the system of record for capacity planning decisions.

“The best performance test is one that actually simulates production. Everything else is guessing.”