selfstart and log #2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
see skill /hero_proc_log_selfstart_check
Implementation Spec for Issue #2: Self-Start and Logging via hero_proc
Objective
Integrate hero_whiteboard's three daemon binaries (
hero_whiteboard_server,hero_whiteboard_web,hero_whiteboard_ui) with the hero_proc process supervisor so that:start/stop/status/logssubcommands via hero_proc_sdklogs.insertRPC callsrun/stoptargets use the self-start pattern instead ofnohup/pkillRequirements
clap:serve(default),start,stop,status,logsserve), logging goes through hero_proc'slogs.insertRPC endpointtracing_subscriberremains as fallback when hero_proc is unavailablerun/stoptargets use selfstart patternImplementation Plan (10 Steps)
hero_proc_sdkandclapto workspace dependencieshero_whiteboard_server/Cargo.tomlhero_whiteboard_web/Cargo.tomlhero_whiteboard_ui/Cargo.tomldependencieshero_whiteboard_server/src/main.rshero_whiteboard_web/src/main.rshero_whiteboard_ui/src/main.rsscripts/run.shfor selfstartscripts/stop.shfor selfstartscripts/rundev.shfor selfstartAcceptance Criteria
hero_whiteboard_server start/stop/status/logsall work via hero_prochero_whiteboard_webandhero_whiteboard_uiserve(backward compatible)logs.insertwith correctsrcfieldmake runandmake stopuse selfstart patterncargo build --releasesucceedscargo test --workspacepassesTest Results
cargo build— PASS (all crates compile successfully)cargo test --workspace— PASS (0 failures, all tests pass)Implementation Summary
Changes Made
Cargo.toml files (4 files)
hero_proc_sdkandclapto workspace dependencieshero_whiteboard_server,hero_whiteboard_web,hero_whiteboard_uihero_whiteboard_server/src/main.rs
serve,start,stop,status,logssubcommands via clapstart— registers with hero_proc via ServiceBuilder and starts the servicestop— stops the hero_proc-managed servicestatus— queries and prints service statuslogs— fetches and prints log entries from hero_procserve— runs the daemon (default, backward compatible), sends logs to hero_proc vialogs.inserthero_whiteboard_web/src/main.rs
hero_whiteboard_ui/src/main.rs
--hero-socketand--socketflags)scripts/run.sh
nohuplaunches with$binary start(hero_proc selfstart)$binary logsfor error output on failurescripts/stop.sh
pkill -fwith$binary stop(hero_proc managed stop)scripts/rundev.sh
Notes
serve— fully backward compatiblesrcfield (e.g.hero_whiteboard_server)Implementation committed:
ce59496Browse:
ce59496