Plugin Reference

RKServer

The standalone backend process (RKBackend). One instance, every game server connects to it. Owns the database — nothing else in the system ever gets a connection string.

Dependencies

Private Libs/ jarsGenuinely local, no cross-process contract: gson-2.10.1.jar, sqlite-jdbc-3.53.2.1.jar.
Redirected (not local)RKPackets.jar, RKUpdatePackets.jar — serialization contracts, manifest Class-Path points directly at their canonical copy under Updates/Plugins/<owner>/... rather than keeping a separately-synced local copy.

Backend module registration

A feature's backend-side logic registers itself into the shared packet dispatch without touching RKBackend's or ClientHandler's core code:

public interface BackendModule {
    void registerHandlers(PacketRegistry registry);
}

Add one line to the module list in RKBackend.start():

List<BackendModule> modules = List.of(new MyModule(dependencies...));

No dynamic discovery — this is a plain, explicit list, edited by hand. One person builds and deploys this process.

Database access

Connection conn = database.getConnection();
try (Statement s = conn.createStatement()) {
    s.execute("CREATE TABLE IF NOT EXISTS my_table (...)");
}

Same pattern as the existing TransferManager/FreetravelManager — a manager class constructed with the shared Database, owning its own table. No generic table-registration API.

HTTP routes

Four independent HttpServer instances, deliberately not sharing a port — so exposing one externally (docs, or updates for a remote server) never also exposes the others. The reverse proxy is an additional front door layered on top of the other three, not a replacement — direct port access keeps working whether or not it's enabled. Full settings reference (every field, every file) lives on the Settings page.

PortRouteServesAuthExposure
admin_port (8000)/adminServer registry grid dashboard — register/edit/unregister, claim codes.Basic AuthFirewalled/local-only — never expose this one.
updates_http_port (8002)/The whole Updates/ tree, static file serving with byte-range support for large assets.NoneNeeds external reachability for a remote server's RKUpdater to fetch updates.
documentation_port (8001)/documentationThis documentation site — static pages read live from Web/.NoneSafe to expose fully public.
reverse_proxy_port (80)Host-header based, per subdomainRoutingSubdomain-routed access to the servers above (e.g. Documentation.<domain>) — internal routes dispatch in-process, no network hop.Per-route access (any/local)Only if reverseProxyEnabled is true; off by default.

updates_http_port is distinct from update_port (the socket-based manifest/claim protocol port) — this one is purely the HTTP byte-range file download side.

Deployed layout

RKServer/
├── RKServer.jar
├── Libs/{gson-2.10.1,sqlite-jdbc-3.53.2.1}.jar
├── Settings/{Connection,Http,Cluster,Admin,Logging,Navigation,WorldState}.json
├── Data/, Logs/, Updates/{Plugins,Assets}/

Packet jars (RKPackets, RKUpdatePackets, and any per-plugin packets jar) redirect via the manifest Class-Path to their canonical copy under Updates/Plugins/<owner>/... rather than keeping a separately-synced local copy — see deployment conventions.