[SIGNIFICANT] Config reload restarts intentionally stopped services #25
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?
Problem
In the
reloadhandler inapi.rs, for changed services,try_start_serviceis called unconditionally. If a service was intentionally stopped by the user (status = "stop" or user ranmy_init stop <name>), a config reload will restart it.Impact
Violates user intent. An operator who stopped a service for maintenance finds it restarted after a config reload, potentially causing data corruption or service disruption.
Files
crates/my_init_server/src/supervisor/api.rs--reloadmethod, "changed services" handlingSuggested Fix
status = "stop"configuration during reloadPer the issue description referencing crates/my_init_server/src/supervisor/api.rs reload method: try_start_service is called unconditionally for changed services without checking current state (stopped by user).