derekkraan / horde

Horde is a distributed Supervisor and Registry backed by DeltaCrdt
MIT License
1.32k stars 106 forks source link

Supervisor: old child specs remained in CRDT after process handoff #263

Closed arjan closed 9 months ago

arjan commented 1 year ago

When an existing child spec was added to the CRDT during process handoff, the old child spec is never removed from the CRDT, creating lingering child specs which results in "zombie" processes spawning when a new supervisor is started.

Fixes #262

derekkraan commented 1 year ago

Sorry for taking so long to respond, but should we add before we delete? In reality I doubt it will matter a whole lot, but could result in lost data under special circumstances(?)

arjan commented 1 year ago

Why add before the delete? The child already existed in the child spec in the first place? (as we are iterating over state.processes_by_id which is filled primarily from the CRDT update messages)