Catalogue / velan-2023-viper-online-services

Velan Studios' four network programmers wrote Knockout City's online services in C inside the game engine's codebase, on Postgres and Redis behind 32 backends

Velan Studios. Viper Online backend services for Knockout City.

Organisation
Velan Studios
Evidence
Reported from production
Source
Viper Online Services

Velan Studios blog, published 2023-12-15

Records

Decision#d1

Build the backend services in the same C codebase as the game client and game server, able to build into one executable

Decision#d2

Handle websocket messages as jobs in the engine's job system, so plain C code can wait on I/O without blocking a thread

Decision#d3

Send hand-written JSON over the websocket instead of a schema-based serialisation such as gRPC

Decision#d4

Move from an embedded SQLite prototype to Postgres and Redis, while keeping both runnable on developer machines

Decision#d5

Invest in load testing with stress clients that simulate real users, alongside unit tests for each new message handler

Sign in to read what was chosen, what was rejected and what it cost, each with its place in the source. An account is free. The job-queue cards are open without one.