Login Server
The Login Server is the master server and sole entry point into the Imlight network.
Alongside the patch server, it is one of the highest actors in the Imlight actor hierarchy. It is responsible for authenticating players, managing character data, and orchestrating game servers.
Architecture Overview
Built on Imlight's actor model, the login server maintains a hierarchical structure with the GameServerPool as its primary child actor, which in turn supervises all game servers in the network.
Game Server Management
The login server's most critical responsibility is managing the pool of available game servers.
TIP
This is a very high-level overview. Please review the server discovery documentation for a more in-depth look at how game servers register and communicate with the login server.
Registration Process
When a game server starts up:
- Game server sends
MSG_CREATEGAMESERVERto login server - LoginServer forwards the message to
GameServerPool GameServerPoolvalidates server parameters (name, port, capacity limits)- If valid,
GameServerPoolcreates and tracks the new server reference - Game server is now available for client connections
Load Balancing
The GameServerPool has its own load balancer:
- Monitors player count across all registered game servers
- Considers server capacity limits from configuration
- Uses health checks with configurable timeouts
- Selects servers based on current load and availability
Health Monitoring
Regular health checks ensure game server availability:
- Periodic
MSG_QUERYSERVERmessages sent to each game server - Timeout-based detection of unresponsive servers
- Automatic removal of failed servers from the pool
- Graceful handling of server failures without affecting other servers
Imlight