
Battle Questions · Gaming
Ten thousand simultaneous battles, decided in under 50ms
A competitive trivia platform where timing is a gameplay mechanic — so the game engine is server-authoritative, sub-50ms at p99, and treats a 500ms discrepancy as a fairness bug rather than a performance one.
لمحة سريعة
- المدة
- 43 أسبوعاً
- حجم الفريق
- 5 أشخاص
- نوع التعاقد
- بناء جديد
- نوع المشروع
- تطبيق ويب
- القطاع
- الإعلام والترفيه
الوضع
التحدي
In a game where timing decides the winner, a 500ms difference in when two players receive a question is not a performance problem, it is a fairness problem. On top of that, anti-cheat had to stop answer lookup and bots without punishing legitimate players for being fast.
ما الذي فعلناه
Every timing decision moved to the server, and every battle became a small in-memory state machine rather than a database transaction.
القرارات التي صنعت الفارق
Battles live in Redis, not Postgres
Each battle is a Redis hash driven by Lua scripts for atomic operations. A relational transaction per answer would have made the database the referee, and the referee would have been the slowest participant.
Client timings are rejected outright
Server-authoritative timestamps with synchronised delivery via keyspace notifications. Any protocol that trusts the client's clock is a protocol that rewards tampering with the client's clock.
Shadow mode instead of bans
Statistical timing analysis flags sub-150ms responses and suspiciously low variance; confirmed cheats are matched against each other rather than told. Deterrence took the flag rate from 2.1% to 0.4%.
ما الذي تغيّر
- simultaneous battles
- 10K+simultaneous battles
- p99 game engine latency
- <50msp99 game engine latency
- daily active users
- 75K+daily active users
- cheat flag rate
- 0.4%cheat flag rate
- 75K+ — 38-minute average session
- 0.4% — down from 2.1% in the first month
10,000+ concurrent battles at sub-50ms p99, 75,000+ daily active users averaging 38-minute sessions, and a cheat rate down to 0.4% — at $0.0003 of infrastructure per battle.
الخدمات المستخدمة
- Redis-backed game engine with atomic Lua operations
- Server-authoritative timing and synchronised question delivery
- Layered anti-cheat with statistical analysis and shadow mode
- Matchmaking and Elo-adjusted accuracy tracking
ما الذي كنا سنفعله بشكل مختلف
لكل مشروع واحدة من هذه. ونشرها هو المقصد — فدراسة حالة بلا ندم فيها تسويق لا دليل.
Game backends have a different performance contract from typical web APIs. Redis Lua scripts, pre-loading and server-authoritative timing are not over-engineering for a trivia game; they are the minimum viable correctness. We would reach for them on day one next time rather than proving the need first.
الخدمات المستخدمة
تطوير الويب
مواقع تركّز على التحويل، سريعة التحميل ومتصدّرة في نتائج البحث.
استكشف الخدمةتطوير التطبيقات
منتجات جوّال جاهزة للمستثمرين بمسار تسجيل قابل للقياس.
استكشف الخدمةالسحابة وDevOps
أطلق كل يوم، على بنية تحتية تكلّف ما ينبغي لها.
استكشف الخدمةالبيانات والتحليلات
أرقام يثق بها الجميع، في مكان واحد، تُحدَّث ليلاً.
استكشف الخدمة
أعمال أخرى
- Internet Money · Crypto financial services$10M+monthly transaction volume
One wallet interface across five blockchains
A multi-chain crypto platform where every chain hides behind one interface, with a tamper-evident audit trail underneath it. $10M+ moves through it monthly.
اقرأ دراسة الحالة - MagicTask · Project management SaaS100K+concurrent users
From latency spikes at 5,000 users to 100,000 concurrent
A gamified project management platform re-architected from a single Node server into an event-driven system that holds 100,000+ concurrent connections without the reward engine touching the critical path.
اقرأ دراسة الحالة