feat: curves + receiver observations follow the breeder purge cascade - #67
Merged
Merged
Conversation
The purge cascade is the association owner. cleanup_coordination_state
now also deletes the breeder's receiver_observations and curve_points
rows, and delete_breeder calls causal DELETE /curves/{id} (best-effort,
logged) to clear its in-memory registry — rows alone would replay back
on restart. Replaces the api-layer hook (reverted in godon-images);
causal's endpoint is unchanged.
Co-authored-by: cherusk <10729954+cherusk@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The purge cascade is the association owner — it already cleans coordination tables (interference_active_breeders, detection_readiness), the breeder's archive DB, and the group lease. Measurement state belongs in the same cascade:
cleanup_coordination_statealso deletes the breeder'sreceiver_observationsandcurve_pointsrows (the observations table previously had NO cleaner at all — rows from purged breeders accumulated forever).delete_breedercalls causalDELETE /curves/{id}(best-effort, logged, 10s timeout,GODON_CAUSAL_URLoverridable) — required because causal holds curves in memory too; rows alone would replay back into the registry on restart.Replaces the api-layer hook (reverted in godon-images PR
revert/api-purge-hook-only— wrong layer). Causal's endpoint (godon-images #281) is unchanged; the controller becomes its caller.Deploy
Ships via
CONTROLLER_VERSIONbump in the chart (seeder-managed, like breeders). Part of the same restack as breeder 0.151.0 + causal image.Co-authored-by: cherusk 10729954+cherusk@users.noreply.github.com