Registries
Shared file
The default registry. List every server in link.json and put the same file on each one.
With "backend": "static", the network is simply the servers list in
link.json. Nothing else runs, and nothing leaves your servers.
{
"serverId": "lobby-1",
"backend": "static",
"secret": "k3Jd9...generated on first boot",
"strategy": "spread",
"servers": [
{ "id": "lobby-1", "group": "lobby", "host": "play.example.com", "port": 5520 },
{ "id": "lobby-2", "group": "lobby", "host": "play.example.com", "port": 5530 },
{ "id": "sw-1", "group": "skywars", "host": "10.0.0.2", "port": 5521 },
{ "id": "sw-2", "group": "skywars", "host": "10.0.0.2", "port": 5522 }
]
}Set it up
- Start one server once. It writes
link.jsonwith a new randomsecret. - Add every server to
servers, with itsid,group,hostandport. - Copy the file to every server, including the
secret. - On each server, change
serverIdto that server’sid, or setLINK_SERVER_ID.
Each server must find its own serverId in the list. If it doesn’t, it logs a
warning and turns transfers off.
Adding a server
Add it to the list and copy the file to every server again, then restart them. A server that is missing from another server’s list can’t be reached from there.
Limits
- No live player counts. Nothing reports load, so
/playtakes turns between the servers in a group instead of looking at how full they are./serversshows no counts. - No shared player lists.
/players,/findandLinkPlugin.players()only know the players on the server you ask. - No offline detection. Link doesn’t know if a listed server is down. A player sent there gets Hytale’s normal connection error.
When these start to matter, move to Redis or
Cloudflare. Only the backend block changes.