Skip to content

Resolve a documentation set into a domain record - #4937

Open
Mpdreamz wants to merge 5 commits into
split/06b-docset-definitionfrom
split/06c1-resolved-set
Open

Mpdreamz wants to merge 5 commits into
split/06b-docset-definitionfrom
split/06c1-resolved-set

Conversation

@Mpdreamz

@Mpdreamz Mpdreamz commented Nov 18, 2026 •

Copy link
Copy Markdown
Member

ConfigurationFile now reads a ResolvedDocumentationSet in the domain assembly. The code that joined docset.yml with the catalog moves out of its constructor into DocumentationSetResolver, unchanged. What is accepted and reported does not change.

Affects: Configuration, Navigation

Why

The documentation set is the build, and its resolved form still lives as fields of a Configuration class. The domain record is the target for the rules that follow (next PR in the stack).

What

The resolved record

ResolvedDocumentationSet holds the resolved settings: exclusions, registry, cross-links, release-notes products, extensions, products, substitutions, feature toggles, storybook, API configurations, suppressed hints, branding and CTAs. Redirects and the table of contents stay out, as agreed in the previous PR.

The resolver is a move

DocumentationSetResolver holds the body of the old constructor with the same calls in the same order: findings reach the context as before, and an exception still propagates after the Could not load docset.yml: error. It is not a Loader.For declaration, so no exception becomes a finding. The missing-file warning and the redirect read stay in ConfigurationFile, in their old order.

Types move with it

Cta, CrossLinkEntry, DocSetRegistry, EnabledExtensions and ResolvedApiConfiguration move to Elastic.Documentation.DocumentationSets; consumers add one using. The mutable BrandingConfiguration result becomes the record Branding; the YAML-shaped BrandingConfiguration DTO stays. The public members of ConfigurationFile keep their types.

Verify

mise run build && mise run test && mise run lint && mise run snap:status && mise run snap:orphans
git diff origin/split/06b-docset-definition --stat -- '*.verified.*'   # one line: Branding <BrandingConfiguration> is now Branding <Branding>

CI=true dotnet test of Configuration.Tests, Navigation.Tests and Markdown.Tests pass. The S2 golden snapshots (exceptions, diagnostics order) are unchanged. Mutation check: MaxTocDepth = docSetFile.MaxTocDepth + 1 in the resolver fails the new Resolve_EveryDocsetKey_IsOnTheResolvedSet and the golden tests.

Deferred behaviour changes: none in this PR. Left for later behaviour PRs: D108, .. in file entries, registry rules, dev_docs, api slug tags, redirect many targets, the toc cycle error, hidden: true crosslink, max_toc_depth rules.

Stack: 3 of 4 (06c1), on top of #4931 (06b) and #4926 (06a). Wave-1: split/integration-wave1. Part of #4530 (foundation #4888).

🤖 Generated with Claude Code

Golden compare

Local builds of the isolated docs, the prod assembler site and the codex example site, this branch's head against the wave-1 integration branch (split/integration-wave1: current main plus the nine wave-1 PRs); aggregate counts, the output stays local.

22 paths differ across the three sites. All also differ between two captures of that baseline taken hours apart (159 paths: live OpenAPI specs, the release-notes CDN and the generated llms files), so none of these can be attributed to this change.

Limit: golden cannot show a real change inside those drifting pages.

ConfigurationFile now reads a ResolvedDocumentationSet in the domain assembly. The resolver holds the code that used to sit in the ConfigurationFile constructor, unchanged: same findings, same order, same exceptions. Cta, Branding, CrossLinkEntry, DocSetRegistry, EnabledExtensions and ResolvedApiConfiguration move with it.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Mpdreamz and others added 2 commits November 19, 2026 18:15
…o split/06c1-resolved-set

# Conflicts:
#	src/Elastic.Documentation.Configuration/Builder/ConfigurationFile.cs
… is missing

The default maps of ResolvedDocumentationSet used the ordinal comparer, so a
page with cta: Trial warned about an unknown template when there was no
docset.yml, where the old case-insensitive map found it. Also drop a license
header that was pasted into the using block of ReloadableGeneratorState.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A docset.yml with extensions written with no value used to stop the load
right after release_notes, before the substitutions, api, branding and cta
were processed. The resolver built the extensions last, so those steps
reported or failed first. Build them at the same step and keep the
NullReferenceException.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The resolver parsed the exclude globs to fail the load on an invalid one and
discarded them, and ConfigurationFile parsed them again. Resolve now returns
the parsed globs with the set; the failure path is unchanged.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

This branch was successfully deployed

1 active deployment
assembler-preview — d9b5a3f6 Deployed Nov 20, 2026 by github-actions[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant