[SIGNIFICANT] kill_others fires before service start -- race with port binding #23
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
kill_othersruns BEFORE spawning the service inspawn_service. Ifkill_othersfails to kill some processes (partial failure), the service proceeds to start anyway.The service may then fail to bind its declared ports because the conflicting processes are still running. However, since the spawn itself succeeded, the service is marked as
Running-- it's actually broken but the supervisor doesn't know.Impact
Services appear healthy but are non-functional because they couldn't bind to their ports. The supervisor reports success while the service is silently broken.
Files
crates/my_init_server/src/supervisor/spawning.rs--kill_othershandling inspawn_serviceSuggested Fix
kill_othershas partial failures, abort the spawn and mark the service as FailedPer the issue description referencing crates/my_init_server/src/supervisor/spawning.rs: kill_others runs before spawn_service completes. A partial failure where conflicting processes survive means the spawned service cannot bind declared ports, but since spawn succeeded, the supervisor marks it Running.