Discovery Server
The Discovery Server (also called the "Discovery") is the central component that aggregates and masks multiplayer rooms.
Main Responsibilities
- Catalog aggregation: keep an up-to-date registry of all active rooms
- Address masking: hide real IPs and ports during listing
- Join ticket issuance: generate signed credentials so clients can join rooms
- mTLS authentication: validate the identity of registered rooms
- JWT validation: validate client identity against the IdP's JWKS
- Filtering and search: let clients filter rooms by tags (game mode, language, region, and so on)
High-Level Architecture
Room Lifecycle
Main Endpoints
Client-facing (HTTPS + JWT)
GET /v1/rooms: list masked rooms with filtersPOST /v1/rooms/resolve: resolve the chosen room and issue a join ticket
Room-facing (HTTPS + mTLS)
POST /v1/discovery/register: self-registration of a new roomPOST /v1/discovery/heartbeat: renew the lease and report statePOST /v1/discovery/drain: signal the end of the room's life
Discovery Flow
Continue with Room Registration, Room Listing, and Ticket Resolution.