Skip to content

feat: Hot Runner Protocol — persistent process-based build/test providers #789

@frostebite

Description

@frostebite

Summary

Add support for persistent, actively-running Unity editor processes as build/test providers. Hot runners are long-lived processes that accept jobs immediately without cold-start overhead.

Motivation

Current providers follow a cold-start model: provision → clone → cache restore → build → tear down. Hot runners eliminate startup latency by keeping Unity editors warm and ready to accept work.

A hot runner is fundamentally a process-based provider — an actively running Unity editor (or other tool) that:

  • Stays alive between jobs
  • Accepts work via a registration/dispatch protocol
  • Returns structured results
  • Can run on any machine (local, server, cloud, container)

Core Concepts

Runner = Active Process + Transport

A hot runner is any process that:

  1. Registers itself as available (with labels describing its capabilities)
  2. Receives job dispatches via a transport protocol
  3. Executes the job in its warm environment
  4. Returns results (artifacts, test results, metrics, etc.)

Extensible Transport Registration

Any machine can become a labeled runner via pluggable transports:

Transport Description Use Case
GitHub Runner Register as self-hosted GitHub Actions runner Standard CI, existing infrastructure
WebSocket/SignalR Real-time bidirectional connection to coordinator Custom dashboards, game platforms
File-based Watch shared directory for job files Simple setups, NAS-based farms
Local Network mDNS/Bonjour discovery + HTTP API LAN build farms, office setups
Custom Implement the runner interface in any language Any transport

Editor Modes

Mode Description
Ephemeral Editor launches per job and exits (current behavior)
Persistent Editor stays running, accepts multiple jobs
Hybrid Pool of persistent editors, burst with ephemeral

Runner Labels

Runners self-describe with labels for job routing:

runnerLabels: unity-2022,linux,gpu,hot

Jobs are dispatched to runners matching required labels.

Runner Registration Protocol

{
  "type": "register",
  "labels": ["unity-2022", "linux", "gpu"],
  "capabilities": {
    "unityVersion": "2022.3.20f1",
    "platform": "StandaloneLinux64",
    "gpu": true
  }
}

Heartbeat, job dispatch, and result reporting follow the same JSON protocol over any transport.

Relationship to Other Features

New Inputs

Input Description
runnerTransport Transport protocol (github, websocket, file, local-network, custom)
runnerEndpoint Connection endpoint for the transport
runnerLabels Comma-separated labels for job routing
editorMode Editor lifecycle (ephemeral, persistent, hybrid)

Implementation Notes

  • New module: src/model/orchestrator/runners/
  • Runner interface as a protocol (like CLI provider) — any language can implement
  • Hot editor communication via a small Unity-side package
  • File-based transport is simplest: drop JSON job file, watch for result file
  • GitHub runner transport uses existing actions/runner mechanism

Implementation

PR Description Status
#791 feat(orchestrator): hot runner protocol Draft — 35 tests
game-ci/documentation#538 docs: hot runner protocol page Draft
game-ci/game-ci-editor-tools#1 Hot runner worker — 5 transports Complete

Tracking

Metadata

Metadata

Assignees

No one assigned

    Labels

    Next-GenOrchestrator Next-Gen experimental featuresenhancementNew feature or requestorchestratorOrchestrator module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions