finds.dev

xtaci/gonet

A Game Server Skeleton in golang.

View on GitHub

★ 1,285GoMITupdated Jul 2024

// the take

A reference architecture for a sharded MMO-style game server in Go, split into a Game Server (handles players), a Hub (routes messages between game servers), and a Stats server (analytics). The author explicitly abandoned it in favor of gonet2, so this is really a historical blueprint rather than something to run in production.

The GS/HUB/SS split is a clean, well-reasoned answer to a real scaling problem — stateful player connections separated from cross-server routing separated from analytics, with explicit rules about which calls are synchronous (GS->HUB/SS) versus fire-and-forget (HUB->GS). The misc/ package has genuinely useful standalone pieces: consistent hashing, an interval tree, a Diffie-Hellman key exchange, bitset — each with its own test file. The proto/API layer is generated from plain-text spec files via awk scripts, which is a pragmatic way to keep client and server protocol definitions in sync without a full IDL toolchain.

It's pre-Go-modules (GOPATH-based build, no go.mod anywhere in the tree), so it won't build cleanly on any current Go toolchain without manual porting. It depends on mgo.v2, a MongoDB driver that's been unmaintained for years with known compatibility issues against modern MongoDB versions. There's no CI, no Docker setup, and persistence is MongoDB-only with no abstraction if you wanted something else. Most damningly, the README itself says not to use this and points to gonet2 instead — last meaningful commit is from 2024 but the architecture and tooling choices are much older than that.

We read the README, the directory tree and a key source file in October 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
1,285
Forks
289
Language
Go
License
MIT
Last commit
25 Jul 2024

// nearby

If gonet isn't quite it.

All repos →