2.3 KiB
2.3 KiB
Status System
Current Goal
The status system should tell the truth about a server's state without depending on stale marker files or query success alone.
Current Direction
The current codebase is moving toward agent-owned structured status.
Important files:
Panel/includes/lib_remote.phpPanel/modules/gamemanager/home_handling_functions.phpPanel/modules/gamemanager/server_monitor.phpAgent_Linux/ogp_agent.plAgent-Windows/ogp_agent.pl
Panel Display Behavior
Game Monitor should not convert ambiguous status into false offline.
Panel display mapping:
ONLINEdisplays green.STARTING,STOPPING, andUNRESPONSIVEdisplay yellow/active.OFFLINEdisplays red only when the agent confirms offline.UNKNOWNdisplays gray.
LGSL/GameQ query failure is not enough to mark a server offline. Query success may add player/map/hostname metadata, but query failure should only show a small unavailable note when the agent says the server is otherwise active.
Recommended State Model
| State | Meaning |
|---|---|
OFFLINE |
No managed session/process and no required port listening. |
STARTING |
Managed session/process exists but the required port is not ready yet. |
ONLINE |
Managed session/process exists and the required port is listening. |
STOPPING |
Stop is in progress and the session/process still exists. |
UNRESPONSIVE |
The server did not become ready in time or stop did not complete cleanly. |
UNKNOWN |
The agent cannot be reached or cannot determine state. |
What Should Be Checked
The agent should check, in this order:
- managed session or screen name
- process or PID tree when available
- required game port listening
- optional query/RCON port listening
- optional query metadata
Known Problems To Remember
- LGSL/GameQ may fail for supported games, blocked ports, or slow startups.
- Marker files can become stale after crashes or power loss.
- A game can be online even if query metadata is temporarily unavailable.
- Some games need long startup windows, so timeouts must be configurable per game.
Planned Improvement Shape
- make the agent the source of truth
- preserve optional query metadata
- use state hints for start/stop transitions
- expose clear messages for
STARTINGandUNRESPONSIVE - add precise log excerpts when startup fails