Skip to content

Reconciliation plan - #13748

Closed
ndeloof wants to merge 0 commit into
docker:mainfrom
ndeloof:reconciliation_plan
Closed

Reconciliation plan#13748
ndeloof wants to merge 0 commit into
docker:mainfrom
ndeloof:reconciliation_plan

Conversation

@ndeloof

@ndeloofndeloof commented Apr 19, 2026

Copy link
Copy Markdown
Contributor

this is an alternative for #13641
based on previous work, I first generated an analysis an plan document, so AI work on this significant refactoring is better guided and impact is well understood

@ndeloof
ndeloofforce-pushed the reconciliation_plan branch 6 times, most recently from a057fa0 to 46e274eCompareApril 20, 2026 07:42
@ndeloof

Copy link
Copy Markdown
ContributorAuthor

/review

@ndeloof
ndeloof marked this pull request as ready for review April 20, 2026 08:06
@ndeloof
ndeloof requested a review from a team as a code ownerApril 20, 2026 08:06
@ndeloof
ndeloof requested review from Copilot and gloursApril 20, 2026 08:06

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Introduces a new “reconciliation plan” pipeline for docker compose create by replacing the legacy convergence flow with: observed state collection → plan generation (DAG) → parallel plan execution.

Changes:

  • Added new reconciliation components: ObservedState, Plan, reconcile logic, and a parallel executePlan executor with grouped progress events.
  • Refactored create() to use the new pipeline (including “Running” events for unchanged containers) and removed most of the old convergence implementation.
  • Updated run to resolve service: references without convergence, and added/updated unit tests for the new modules.

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.

Show a summary per file
FileDescription
reconciliation.mdArchitecture/design doc for the new reconciliation engine and pipeline.
pkg/compose/run.goReplaces convergence-based service-reference resolution for run with a new helper.
pkg/compose/reconcile_test.goAdds unit tests validating plan output for networks/volumes/containers/orphans.
pkg/compose/reconcile.goImplements reconciler producing a deterministic DAG plan for infra + containers.
pkg/compose/progress.goRemoves runningEvent helper (replaced by direct newEvent usage).
pkg/compose/plan_test.goAdds unit tests for Plan and OperationType stringification.
pkg/compose/plan.goIntroduces Plan, PlanNode, Operation, and OperationType abstractions.
pkg/compose/observed_state_test.goAdds tests for observed-state snapshot construction and classification.
pkg/compose/observed_state.goAdds snapshot types + collection logic; adds “Running” events emission helper.
pkg/compose/executor_test.goAdds executor tests using mocked API client calls.
pkg/compose/executor.goImplements parallel plan execution, operation handlers, and grouped progress events.
pkg/compose/create.goRefactors create() to build observed state → reconcile → emit running events → execute plan.
pkg/compose/convergence.goRemoves convergence struct/logic; keeps/exports service-reference resolution helpers.
pkg/compose/containers.goAdds getContainersByService() and removes Containers.names().

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment threadpkg/compose/executor.go Outdated
Comment threadpkg/compose/executor.go Outdated
Comment threadpkg/compose/reconcile.go Outdated
Comment threadpkg/compose/reconcile.go Outdated
Comment threadreconciliation.md Outdated
Comment on lines +8 to +10
ensureImagesExists -> ensureNetworks/Volumes -> collectObservedState -> reconcile -> executePlan
(inchange) (inchange) (1) (2) (3)
```

CopilotAIApr 20, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spelling: "inchange" should be "inchangé".

Copilot uses AI. Check for mistakes.
@ndeloof
ndeloofforce-pushed the reconciliation_plan branch from ff0c5cd to 136845bCompareMay 20, 2026 07:36
@glours

Copy link
Copy Markdown
Contributor

/review

@docker-agent

Copy link
Copy Markdown

PR Review Failed — The review agent encountered an error and could not complete the review. View logs.

@glours
gloursforce-pushed the reconciliation_plan branch 2 times, most recently from 8f2d032 to b812190CompareMay 28, 2026 13:58
@glours

Copy link
Copy Markdown
Contributor

/review

@docker-agent

Copy link
Copy Markdown

PR Review Failed — The review agent encountered an error and could not complete the review. View logs.

@ndeloof
ndeloofforce-pushed the reconciliation_plan branch from b812190 to f418dc4CompareMay 28, 2026 14:29
@glours
gloursforce-pushed the reconciliation_plan branch from f418dc4 to b812190CompareMay 28, 2026 14:31
@ndeloof
ndeloofforce-pushed the reconciliation_plan branch from b812190 to 08da1d5CompareMay 28, 2026 14:32
@glours
gloursforce-pushed the reconciliation_plan branch 3 times, most recently from f5336ce to 7bbbc77CompareMay 28, 2026 15:05
@glours
gloursforce-pushed the reconciliation_plan branch from 8ab1685 to 341ffc0CompareJune 3, 2026 18:13
@gloursglours closed this Jun 8, 2026
@glours
gloursforce-pushed the reconciliation_plan branch from 341ffc0 to 5d67ce6CompareJune 8, 2026 14:12
Sign up for freeto 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.

3 participants

@ndeloof@glours