How jumpr15/simple-orchestrator works
Simple Orchestrator manages worker nodes and desired container counts from a master. Workers request cluster admission, then expose an RPC heartbeat endpoint; the master stores node addresses, schedules container configuration, and sends health checks that can trigger container creation. The README also describes client traffic through a reverse proxy and cluster state management. The load-balancer client exists, but sampled code does not wire it into health checks or show traffic routing; those links are therefore left separate. The worker container implementation is a stub, so container execution details are not shown.
Main entry points: healthService.go Health service · worker.go Worker startup · heartbeat.go Heartbeat handler · joinService.go Join service
Components 16
Master control
- Master startup
master/master.go - Join service
master/joinService/joinService.go - Node store
master/kvStore/kvStore.go - Health service
master/healthService/healthService.go - Container scheduler
master/scheduler/scheduler.go
Worker runtime
- Worker startup
worker/worker.go - Worker cache
- RPC listener
worker/listenerService/listenerService.go - Container service
worker/containerService/containerService.go
Shared contracts
- Heartbeat handler
common/heartbeat/heartbeat.go - Heartbeat contract
common/types/heartbeatTypes/heartbeatTypes.go
Traffic routing
- Load balancer client
master/loadBalancer/loadBalancer.go - Caddy config
caddy.json
Other components
- Joining worker
- Traffic client
- Caddy proxy
Connections 18
- Joining worker → Worker startup: starts
- Worker startup → Join service: requests join
- Join service → Node store: registers node
- Master startup → Join service: starts
- Master startup → Health service: starts
- Health service → Node store: reads nodes
- Health service → Container scheduler: requests config
- Health service → RPC listener: sends RPC check
- Worker startup → Worker cache: creates cache
- Worker startup → RPC listener: starts
- RPC listener → Heartbeat handler: dispatches RPC
- Heartbeat handler → Worker cache: reads and updates
- Heartbeat handler → Container service: starts containers
- Health service → Heartbeat contract: uses request types
- Heartbeat handler → Heartbeat contract: handles request types
- Load balancer client → Caddy proxy: updates upstreams
- Caddy config → Caddy proxy: configures
- Traffic client → Caddy proxy: sends traffic