Skip to content

[eno] Prune input revisions for refs removed from the synthesizer  - #673

Draft
Ruinan Liu (ruinan-liu) wants to merge 1 commit into
mainfrom
users/ruinanliu/fix-remove-input-from-synthesizer
Draft

Ruinan Liu (ruinan-liu) wants to merge 1 commit into
mainfrom
users/ruinanliu/fix-remove-input-from-synthesizer

Conversation

@ruinan-liu

Copy link
Copy Markdown
Collaborator

Description:

Fixes Eno being unable to resynthesize after a synthesizer removes a ref.

Problem

• The pruning controller kept any input revision whose key still had a Composition binding, even after the synthesizer removed the ref. Bindings inherited from a Symphony keep it there.
• That leftover revision stops being updated. If it carries  eno.azure.io/synthesizer-generation  or  eno.azure.io/revision , the Composition stays out of lockstep ( MismatchedInputs ) and never resynthesizes.
• The pruner only watched Compositions, so a synthesizer change didn't trigger pruning directly.

Changes

• A revision is now kept only if the synthesizer still declares the ref and it is bound, either by a Composition binding or by the ref naming its own resource.
• All leftover revisions are removed in a single status update.
• Nothing is pruned when the synthesizer is missing.
• The pruning controller now watches Synthesizers and requeues their Compositions.

Tests

• Unit tests for  isInputBound  and the pruner's  Reconcile  ( pruning_test.go ).
• Integration test: a removed ref with its binding still present is pruned, and adding the ref back restores the revision.
• E2E test  TestSynthesizerInputRemoval : two inputs, one ref removed, then a new synthesis that outputs only the remaining input.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant