FlareStart
HomeNewsHow ToSources
FlareStart

Where developers start their day. All the tech news & tutorials that matter, in one place.

Quick Links

  • Home
  • News
  • Tutorials
  • Sources
  • Privacy Policy

Connect

© 2026 FlareStart. All rights reserved.

Back to articles
The API Was “Fast” — Until One User Made It Slow for Everyone
How-ToWeb Development

The API Was “Fast” — Until One User Made It Slow for Everyone

via Dev.to WebdevFrozen Blood4h ago

We had an API that was consistently fast. ~80ms average response time. No complaints. Then one day, everything slowed down. Not crashed. Not broken. Just… slow. And the weird part? It was caused by one user . The Symptom: Latency Gradually Creeping Up At first: p95 latency increased slightly CPU was fine Memory was stable No obvious errors Then: Requests started taking 500ms+ Some hit 2–3 seconds But only during certain times It wasn’t global traffic. It was something more subtle. The Clue: One Endpoint, One Pattern After digging into logs, we noticed: Almost all slow requests hit the same endpoint Same query pattern Same user ID appearing frequently That user had… a lot of data. Way more than anyone else. The Root Cause: “Works Fine” Query That Didn’t Scale Here’s the query (simplified): SQL: SELECT * FROM orders WHERE user_id = $ 1 ORDER BY created_at DESC ; Looks harmless, right? Except: No pagination No limit That user had 120,000+ rows Every request: Pulled all rows Sorted them Se

Continue reading on Dev.to Webdev

Opens in a new tab

Read Full Article
2 views

Related Articles

Pokémon Champions is coming to the Nintendo Switch on April 8th
How-To

Pokémon Champions is coming to the Nintendo Switch on April 8th

The Verge • 5h ago

Why You Should Start Using Negative If Statements in Your Code
How-To

Why You Should Start Using Negative If Statements in Your Code

Dev.to • 8h ago

How-To

Most Developers Build Software Wrong — Here’s What Actually Matters

Medium Programming • 9h ago

DARVO in Text Messages: Real Examples and How to Spot It
How-To

DARVO in Text Messages: Real Examples and How to Spot It

Dev.to Beginners • 9h ago

How to Recognize Guilt-Tripping in Text Messages
How-To

How to Recognize Guilt-Tripping in Text Messages

Dev.to Beginners • 9h ago

Discover More Articles