Nice article, I just wish they went into more detail as to why TiKV was chosen over other distributed stores like: Cockroach, Yugabyte, or Foundation. It'd also be nice to know the size of those 40bn rows is it 10TB or 100TB?
For database selection, there is a blog post about why choose TiDB over CockroachDB and other MySQL-based solutions: https://pingcap.com/success-stories/why-we-chose-a-distribut...
You've got to wonder if simply sharding by either player or game would have worked well enough, even with MySQL. Worked well enough for Blizzard for over a decade!
Similarly, I wonder if a single active write server paired with a handful of readable secondaries could have taken this query volume in its stride if using something like MS SQL Server on high-spec bare metal kit. Think In-Memory processing on dual AMD EPYC 2 servers with 128 cores per box.
They mention billions of rows and terabytes of data, but I've heard of similar scale systems as far back as over decade ago! The Australian phone company Telstra did all their billing in a single IBM DB2 database, for example, and the incoming data in that system is just as real time.
I'm probably wrong, but this smells like the company missed some basic optimisation opportunities somewhere...