Repository navigation
Docs: ADR-011 + Step Builder Phase 2 async doc sync - #330
Conversation
Keep ADR-010 as the type-state decision and document the BuildAsync exit already shipped so Phase 2 async is no longer listed as an open non-goal.
Skymly
left a comment
There was a problem hiding this comment.
Auto review (docs-only)
Overall this is a coherent maintainer-doc sync for Step Builder Phase 2 async: ADR-011, Design Doc, ROADMAP, indexes, CHANGELOG, and the DP086 registry line all tell the same story (exclusive Build / BuildAsync exit, product type = inner T, CT forwarding rules, no new diagnostic IDs). Scope matches the Docs module checkbox and the #325 → #326 → #327 slice order.
Findings
-
ADR-010 vs ADR-011 process tension (should fix or explicitly decide) —
docs/DOCUMENTATION.md§2 says Accepted ADR bodies are immutable and later changes go throughSuperseded by ADR-NNN. ADR-010 still states (decision §1/§5/§6) that onlyBuild()is gated, product type = assemble return type, and asyncBuild/assemble is an MVP non-goal. ADR-011 says it does not supersede ADR-010 while also “lifting” §6 and narrowing §5 for async. A reader who opens ADR-010 alone still gets the old contract. Prefer one of:- mark ADR-010’s status line as partially superseded for the async / product-type bullets (if status metadata is allowed to change), or
- have ADR-011 explicitly supersede those bullets and restate that type-state / the required-step cap remain from ADR-010.
Leaving both as Accepted with contradictory async wording is the main doc risk in this PR.
-
AGENTS.mdDP080 row not updated — DP086’s registry line was tightened forTask<T>/ValueTask<T>/ bare task / multipleCancellationToken, but DP080 still reads only as “assemble 参数无法绑定到步骤”.docs/design/StepBuilder.mdalready notes the asyncCancellationTokenexemption; the AGENTS diagnostic table should match so the registry stays the single source of truth. -
Nit (non-blocking) — Design Doc header version stays
v0.2.4-preview1while Phase 2 async content lands. Fine if you intentionally tie the doc stamp to the package train; otherwise a small doc revision note would make the Phase 2 sync obvious.
Looks good
- ADR index next number → ADR-012; design index links both ADR-010 and ADR-011.
- ROADMAP Top-2 and “已完成” bullets correctly move async out of open Phase 2 while leaving DI / step validation and Samples#29 open.
- WorkGraph comparison row updated for
BuildAsync. - Negative consequences in ADR-011 (split holder for dual exits; custom awaitable stays sync-shaped; token accepted but maybe not observed) are documented honestly.
No code or packaging changes; skipping CI for docs-only is reasonable. Not a merge blocker if you resolve (1) deliberately; (2) is a small follow-up in this PR or a tiny docs fix.
| ## 决策 | ||
|
|
||
| Step Builder 的 **async 只发生在 assemble 出口**。ADR-010 仍是 type-state 与必填上限的决策,**不**被本 ADR 取代。本 ADR 解除 ADR-010 第 6 点里的 async `Build` / assemble 非目标,并只在 async 出口上收窄「产品类型 = assemble 返回类型」的表述。 | ||
|
|
There was a problem hiding this comment.
This paragraph both keeps ADR-010 as the type-state decision and “lifts” its §6 async non-goal / narrows §5 product-type wording. Under docs/DOCUMENTATION.md §2, Accepted ADR bodies are immutable and later changes are supposed to go through Superseded by. As written, ADR-010 §1/§5/§6 still contradict this page for anyone who does not also open ADR-011.
Please either (a) mark ADR-010’s status as partially superseded for those bullets, or (b) state here explicitly which ADR-010 bullets this ADR supersedes while type-state / the required-step cap remain. Silent coexistence of two Accepted ADRs with opposite async guidance is the main consistency risk.
| @@ -177,7 +177,7 @@ dotnet test DesignPatterns.slnx -c Release | |||
| | DP083 | GenerateBuilder 重复步骤(生成器;同名 `[BuilderStep]` 重复) | | |||
There was a problem hiding this comment.
DP086 is updated for the Phase 2 assemble contract, but the DP080 row a few lines above still omits the async CancellationToken exemption that ADR-011 and docs/design/StepBuilder.md now document. Please align the DP080 registry wording (token skipped for step-name binding on async assemble) so AGENTS stays the single diagnostic registry.
Summary
Record Step Builder Phase 2 async assemble as ADR-011 and sync maintainer docs with the
BuildAsyncexit already shipped in #326 / #329.ADR-010 remains the type-state decision and is not superseded. Async is assemble-exit only: sync
Tstill emitsBuild(); BCLTask<T>/ValueTask<T>emit onlyBuildAsync. Product type is the innerT. Cancellation-token rules and the tightened DP086 contract are documented. ROADMAP no longer lists async as an open Phase 2 item; DI and step validation remain.Related Issue
Closes #327
Relates to #324
Solution module
DesignPatterns/)DesignPatterns.Diagnostics/)DesignPatterns.SourceGenerators/)DesignPatterns.Analyzers/+DesignPatterns.CodeFixes/)DesignPatterns.Extensions.DependencyInjection/)DesignPatterns.Package/)docs/,.github/,AGENTS.md,build/)Type of change
Test plan
docs/design/StepBuilder.mdagainst the merged generator behavior in SourceGenerators: Emit BuildAsync for async assemble #329: exclusive exit, direct task return, optionalCancellationTokenforwarding, DP086 illegal contracts./build.ps1 --target Ci --configuration Release— not run; docs and registry text only, no code or packaging changeBreaking changes
Checklist
CURSOR_SUMMARY, "Made with …")Documentation checklist