rdmbair15m5-changelog-20260923-0905-feat-20260905-23-tyrell-telemetry-and-bus-observation
rdmbair15m5-changelog-20260923-0905-feat-20260905-23-tyrell-telemetry-and-bus-observation
One-line summary: Implemented
FleetTelemetryCoordinator in TyrellCore absorbing host
state, health pass, agent status, and bus observation into native Swift,
resolving FEAT-20260905-23, ISSUE-20260901-27,
and ISSUE-20260905-04.
1. Scope
- Hosts Affected: Fleet-wide (
rdmsm4x,rdmbair13m5,rdmbair15m5,jdmbair13m5,rdmpw3265m,rdmpw3275m). - Repositories:
apps/Tyrell(SwiftPM package atgit.ecs0.net:git/apps/Tyrell.git). - Tickets:
FEAT-20260905-23(resolved),EPIC-20260905-03,ISSUE-20260901-27,ISSUE-20260905-04.
2. Exact Files Touched
Sources/TyrellCore/Telemetry/FleetTelemetryCoordinator.swift(new, 841 lines):HostHeartbeatRecord: Backward-compatible JSON schema matchingagent_status.zshandfleet_audit.zsh, including optionalmeasured_at, enrichedactive_sessions, system load, memory, swap, disk, health metrics, and dirty worktrees.- Coupled heartbeat writer + distributor + bus sync
(
syncHeartbeatsAndBus) preserving Constraint 1. - Pure Swift bus inbox evaluator (
evaluateBusWatch) actively monitoring maildir, managing~/.agent-coordination/UNREAD-HIGH-PRIORITY.mdlifecycle. - Host state report generator (
generateStateReport) writing to~/.agent-coordination/staging/fleetstate/<host>-<timestamp>.txt. - Fleet host aggregator (
aggregateFleetHosts) evaluating all 6 canonical fleet hosts with status and tag filtering.
Sources/tyrell/Tyrell.swift(modified, +149 lines):- Added CLI subcommands:
tyrell fleet hosts [--tag <tag>] [--json] [--verbose]tyrell fleet telemetry [--heartbeat] [--sync] [--bus-watch] [--state-report] [--all] [--json]
- Fixed argument parser positional subcommand handling in
ECS0CommandLineParser.
- Added CLI subcommands:
Sources/tyrelld/Daemon.swift(modified, +18 lines):- Added REST endpoint
GET /api/fleet/hostsacross both client and server data planes. - Added background 300s telemetry periodic task executing
FleetTelemetryCoordinator.shared.syncHeartbeatsAndBus().
- Added REST endpoint
Tests/TyrellCoreTests/FleetTelemetryCoordinatorTests.swift(new, 214 lines):- 6 unit test cases covering schema backward-compatibility, enriched heartbeats, bus watch alert file lifecycle, fleet host aggregation, and state report generation.
3. Commands Run
# Run unit tests locally
build_slot.zsh wrap swift test --package-path apps/Tyrell --filter FleetTelemetryCoordinatorTests
# Commit & push to remotes
git -C apps/Tyrell commit -m "feat(telemetry): absorb host state, health pass, agent status, and bus observation per FEAT-20260905-23"
git -C apps/Tyrell push origin main
git -C apps/Tyrell push backup main
# Fast-forward canonical on rdmsm4x
ssh rdmsm4x 'git -C ~/dev/apps/Tyrell fetch fleet && git -C ~/dev/apps/Tyrell merge --ff-only fleet/main'
# Test run on rdmsm4x
ssh rdmsm4x 'build_slot.zsh wrap swift test --package-path ~/dev/apps/Tyrell --filter FleetTelemetryCoordinatorTests'
ssh rdmsm4x 'build_slot.zsh wrap swift run --package-path ~/dev/apps/Tyrell tyrell fleet hosts'
ssh rdmsm4x 'build_slot.zsh wrap swift run --package-path ~/dev/apps/Tyrell tyrell fleet telemetry --bus-watch'
# Ticket resolution
ssh rdmsm4x 'ticket resolve FEAT-20260905-23 ...'4. Verification Evidence
- Local Tests:
Executed 6 tests, with 0 failures (0 unexpected) in 0.348 seconds. - Remote Tests on rdmsm4x:
Executed 6 tests, with 0 failures (0 unexpected) in 0.348 seconds. - CLI Output (
tyrell fleet hosts): Evaluated 6 nodes (rdmsm4x,rdmbair13m5,rdmbair15m5,jdmbair13m5,rdmpw3265m,rdmpw3275m), all reportingONLINEwith slot capacities, session counts, dirty worktrees, unread bus counts, and tags. - Bus Watch: Evaluated maildir in <10ms, detected
high-priority messages, and generated
UNREAD-HIGH-PRIORITY.md. - Commit:
3416dd2onmain.
5. Backup Locations & How to Undo
- Git Commit:
3416dd2inapps/Tyrell. - To Undo:
git -C apps/Tyrell revert 3416dd2git -C apps/Tyrell push origin main && git -C apps/Tyrell push backup main
6. Outstanding Owner Actions
- None. All changes are backward compatible with legacy shell cron
jobs (
agentstatus,buswatch,fleetstate,fleethealth). - After a 7-day observation period showing 100% agreement between Tyrell telemetry and shell scripts, legacy launchd jobs can be demoted and archived.