Skip to content

AIFACTORY-FEAT-158: Base template: open consumer findings closed before the first scaffold

Generated from the architecture model

This page is rendered from model/**/*.yaml by tools/docs_model during mkdocs build. Edit the YAML, not this page; hand-written design lives on the linked service, platform and plane pages.

A design artefact, not a tracker

This backlog is generated from model/backlog/ and validated against the architecture model. No work item exists in any tracker, and no item carries a date, an estimate or an assignee (ADR-0029).

Epic Ecosystem component extensions · Increment I0 Readiness · State elaborated · Route backend-developer · Phase before development · Build order 10 of 185 (Templates and libraries)

Before development

Template or library work: every task of this feature changes a template or a shared library the Factory builds on, and it lands before the Factory's own repositories of I0 are developed. The mark travels with every task (tag phase:before-development).

The base template keeps a register of findings reported by its consuming templates (Docs/Consumer-Reported-Findings.md). Four are open: a test session timeout that can silently truncate a run, so that every green result is suspect until it is audited; three vulnerable transitive dependencies, one of them High, carried by Hangfire and Pulumi; the QueryModel symbol without an update path for the consuming templates; and no sync path for the Scripts folder into them. The agent host template also records a generation defect inherited from the base template (a persistence provider substitution that drops a closing quote). The Factory scaffolds from the base template only after these are closed. Component: BaseTemplate (extend).

Delivers —
Stubs —
Realizes components: cmp-base-template
adrs: ADR-0028
Requirements —
Depends on —
Sources model/components.yaml, ConnectSoft.BaseTemplate/Docs/Consumer-Reported-Findings.md, ConnectSoft.AI.SoftwareFactory.AgentTemplate/Docs/AgentTemplate-Alignment-Verification.md

AIFACTORY-US-231: Base template: the persistence provider substitution keeps its closing quote and the generated configuration of every provider parses

enabling · persona asset-maintainer As an asset maintainer, I want the persistence provider constants of the template to be substituted into a terminated string for every provider, so that no solution generated from the base template or from a template composed on it starts with a configuration that does not parse.

The alignment verification page of the agent host template (Docs/AgentTemplate-Alignment-Verification.md of that template) records a blocking generation defect that it inherits from the base template: the Dapper, PostgreSQL and MySQL persistence substitutions share a replacement marker and drop its closing quote, so the generated provider becomes an unterminated JSON string in the configuration even for the default NHibernate generation. The page states the order of the repair: the standalone base template source is fixed and verified first, the consuming template then moves its submodule, and neither the submodule contents are patched nor the configuration regression tests removed to bypass the failure. This PBI is that first step. It gives each provider constant its own replacement so that the generated value is a terminated string for every persistence choice and dialect, adds configuration smoke tests that parse every generated configuration root to the preset matrix of the template, and records the defect as an item of the findings register with its cause and its closure, because the register does not list it yet. A generation whose configuration does not parse fails the matrix with the preset and the file named. The agent host template consumes the fix through the feature component-agent-template-release.

Acceptance criteria

AC1 Given the default generation of the base template with the NHibernate persistence model, when the generated configuration files are read, then each parses as JSON and the persistence provider value is a terminated string (ADR-0028 amendment on scaffolding from the base template; defect recorded in Docs/AgentTemplate-Alignment-Verification.md of the agent host template; docs/architecture/ecosystem-composition.md names the open findings as a need of this component).
AC2 Given every persistence choice of PersistenceModelType and every dialect of the preset matrix, including the Dapper, PostgreSQL and MySQL cases, when the matrix generates them, then the configuration smoke tests parse every configuration root of every case and pass, and a case whose configuration does not parse fails the matrix with the preset and the file named (model/template-parameters/connectsoft-base.yaml lists the choices, ADR-0028).
AC3 Given the fixed template, when the findings register is read, then it holds an item for the substitution defect with its cause, the commit that closes it and the smoke tests that guard it, and the agent host template can move its submodule to that commit without patching submodule contents (ADR-0028, model/components.yaml).
Traces: adrs ADR-0028
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md, model/template-parameters/connectsoft-base.yaml

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-584 Persistence provider substitution fixed in the generated configuration implementation The PostgreSQL and MySQL constant substitutions keep their closing quote; the generated configuration of every provider parses; the configuration smoke tests of the generated matrix pass for all providers. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1088 Configuration smoke tests for every persistence choice in the preset matrix fixture The preset matrix of the template, build/Test-BaseTemplateRegressions.ps1 until the cases of build/template-ci.json replace it in AIFACTORY-US-235, runs smoke tests that parse every generated configuration root for each persistence choice and dialect; a planted unterminated provider string fails the matrix with the preset and the file named. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1089 Register item for the substitution defect documentation Docs/Consumer-Reported-Findings.md of the template holds an item for the persistence substitution defect with cause, closing commit and guarding tests, and its status table marks the item fixed. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1090 Verify the generated configuration of every provider verification Run the preset matrix from the packed template; every case generates, builds in Release and passes its configuration smoke tests, and the planted case fails, which proves AC1 to AC3 of AIFACTORY-US-231 (ADR-0028). ConnectSoft.BaseTemplate

AIFACTORY-US-232: Base template: the test session timeout is audited and the template adopts the shared template pipeline, so that a truncated test run fails instead of passing

enabling · persona asset-maintainer As an asset maintainer, I want every test run of the template to be compared with the tests that were discovered, by the one implementation the estate has, so that a green result of the base template means that every test ran and no second completeness script exists.

Item 7 of the findings register of the template (Docs/Consumer-Reported-Findings.md of the template) reports that a test session which reaches TestSessionTimeout is cut off without a failure: tests that never ran are not failures, so the run prints a pass over an incomplete run, in the pipeline as well as locally. The base template sets the ceiling to 900000 milliseconds in ConnectSoft.BaseTemplate.runsettings and to 600000 in the Docker variant, both lower than the value that truncated a consuming suite, and the register states that until the audit is done every other green result in the repository is suspect. Item 5 of the findings page of the authorization server template (Docs/Consumer-Reported-Findings.md of that template) records the stronger repair: a runner that compares the discovery list with what executed and fails on a difference, which holds when a suite outgrows any ceiling. The estate already owns that repair once, in the shared template pipeline tooling of ConnectSoft.AzurePipelines: template-ci/v1/scripts/Invoke-ApplicationTests.ps1 and Test-TestResults.ps1 reject missing, aborted and incomplete reports, Test-ApplicationTooling.SelfTest.ps1 holds their fixtures, and the authorization server and identity templates consume them through build/template-ci.json and template-ci/v1/application-steps.yml. The rollout ledger of that tooling (template-ci/rollout-status.md) lists the base template as pending, with the checkpoint to migrate the standalone base template. This PBI does the audit and that migration. It measures the wall-clock runtime of the unit, architecture and acceptance suites and sets both ceilings well above a healthy run. It gives the base template a build/template-ci.json manifest that names its solution, test projects, runsettings, required services and scaffold cases, and imports the shared application steps in azure-pipelines.yml. The base template gains no completeness script of its own: the shared scripts own execution and gates, tooling is never composed into a package, and a copy in the base template would ship inside every consumer submodule. A rejection case the shared Test-TestResults.ps1 lacks, a truncated or a mismatched report, is added in the shared tooling with its self-test and not in a template. ConnectSoft.AzurePipelines is a before-development repository (D114), so that change is a task of this PBI in that repository, and the base template proves the four rejections from the consumer side at the tooling commit that carries it. The audit with its measured numbers closes the item in the register. The same repository holds the shared template installer steps, template/dotnet-template-installer-steps.yaml and the job template/dotnet-template-installer-job.yaml that calls them, by which the templates outside template-ci/v1 pack, validate one instantiation and push. The template gates of the next increment already rely on a gate between the pack and the push, so this PBI delivers it in the first increment. A gate hook, off by default, runs a command of the consumer against the installed candidate after the pack and before the push and stops the run on a non-zero exit. A version guard, opt-in and off by default, refuses a version that is already on the feed. The allowPackageConflicts parameter stays for a consumer that does not switch the guard on, so no existing consumer of the shared job changes.

Acceptance criteria

AC1 Given the unit, architecture and acceptance suites of the base template, when the audit measures their wall-clock runtime, then the ceilings of ConnectSoft.BaseTemplate.runsettings and of the Docker variant are set above the measured runtime with a recorded margin and the measured numbers are written into item 7 of the findings register (ADR-0028, docs/architecture/ecosystem-composition.md names the open findings as a need of this component).
AC2 Given a test run of any suite through the shared application steps, when Test-TestResults.ps1 of the shared tooling compares the discovery list with the executed tests of the result files, then a run with fewer executed than discovered tests fails with the missing tests named, and synthetic missing, aborted, truncated and mismatched result files are each rejected while a complete one is accepted (FR-11, ADR-0028).
AC3 Given the pipeline of the base template, when it runs the three suites, then azure-pipelines.yml imports template-ci/v1/application-steps.yml with build/template-ci.json, each suite passes through the shared completeness check before its result counts, a truncated run fails the stage, the base template holds no completeness script of its own, and item 7 is marked fixed in the status table of the register (FR-11, model/components.yaml).
AC4 Given a consumer of the shared installer job template/dotnet-template-installer-job.yaml, when it switches the gate hook on and its command exits with a failure, then the run stops before the push; when it switches the version guard on and the version is already on the feed, then the push is refused with the reason; and a consumer that sets neither switch packs, validates one instantiation and pushes as before, with allowPackageConflicts as it was (ADR-0028 amendment on scaffolding from the published templates; model/backlog/epics.yaml states the generated-solution gate as the completion of the epic).
Traces: adrs ADR-0028
Traces: requirements FR-11
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-585 Test session timeout audited verification The measured runtime of each suite and the margin are recorded in item 7 of the findings register, a run of the three suites through the shared application steps is complete, a synthetic truncated run fails instead of passing, and the finding is closed in the register, which proves AC1 to AC3 of AIFACTORY-US-232. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1167 Test session ceilings of both runsettings files set from the measured runtimes implementation TestSessionTimeout of ConnectSoft.BaseTemplate.runsettings and of the Docker variant is set above the measured wall-clock runtime of the slowest suite with the margin the audit records, and a comment beside each value names the measurement it derives from. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1091 Shared template pipeline manifest of the base template operations build/template-ci.json of the base template names its identity, solution, package source configuration, test projects, runsettings, concurrency, coverage threshold, required services and scaffold cases, validates with the manifest action of the shared tooling, and holds no credential; the base template holds no completeness script. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1461 Rejection of a truncated and of a mismatched report in the shared result validation implementation Test-TestResults.ps1 of template-ci/v1 rejects a truncated result file and a result file whose executed tests differ from the discovery list, each with the missing tests named, beside the missing and the aborted report it rejects today; Test-ApplicationTooling.SelfTest.ps1 holds a synthetic truncated and a synthetic mismatched report that are rejected and a complete one that is accepted. ConnectSoft.AzurePipelines
AIFACTORY-TASK-1092 Consumer proof of the four rejected result files fixture A self-test of the base template runs the result validation of the shared tooling, at the tooling commit the manifest resolves, on a missing, an aborted, a truncated and a mismatched result file and on a complete one, and asserts four rejections and one acceptance; the tooling commit is one that carries the truncated and the mismatched rejection of AIFACTORY-TASK-1461. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1093 Shared application steps imported in the pipeline of the base template operations azure-pipelines.yml of the base template declares the shared tooling resource, imports its runtime variables and setup steps and runs the unit, architecture and acceptance suites through template-ci/v1/application-steps.yml with build/template-ci.json; the stage output names the counts of discovered and executed tests and a difference fails the stage. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1426 Gate hook and version guard in the shared template installer steps operations The shared installer steps template/dotnet-template-installer-steps.yaml and the job that calls them gain a gate hook, off by default, that runs a command of the consumer against the installed candidate after the pack and before the push and stops the run on a non-zero exit, and a version guard, opt-in and off by default, that refuses a version already on the feed with the reason; the allowPackageConflicts parameter stays with its default for a consumer that does not switch the guard on, and a consumer that sets neither switch keeps its single smoke instantiation and its push unchanged; the three consumer runs of the verification prove AC4 of AIFACTORY-US-232. ConnectSoft.AzurePipelines

AIFACTORY-US-233: Base template: the Hangfire.Core, Pulumi and System.ServiceModel.Primitives dependency paths are cleared at the parent, so that no consumer needs a direct reference of its own

enabling · persona asset-maintainer As an asset maintainer, I want the vulnerable transitive dependencies of the template to be cleared at their source, so that no Factory service and no consuming template inherits a known vulnerability it cannot fix itself.

Item 4 of the findings register of the template (Docs/Consumer-Reported-Findings.md of the template) lists the advisories that remain after the earlier bumps: Newtonsoft.Json 11.0.1 through Hangfire.Core, rated High, OpenTelemetry.Api and the OpenTelemetry protocol exporter at 1.9.0 through Pulumi, rated Moderate, and the remaining path of System.Security.Cryptography.Xml through System.ServiceModel.Primitives. The register explains why a consuming template cannot repair them: central transitive pinning breaks restore because the template declares package versions conditionally on symbols that are not evaluated yet, and a direct reference per project would place a package into projects that do not use it. It names Pulumi as the entry to do first, because it also holds the infrastructure project at an OpenTelemetry version below the centrally declared one. The evidence is not uniform, so this PBI first establishes what is open. The register reports the advisories against a solution generated from the authorization server template, while the findings verification page of the base template (Docs/Findings-Verification.md of the template) records for the same commit no known vulnerabilities across its authoring and generated projects, and the shared pipeline page of the authorization server template records that four direct references in its own projects select the already declared central versions without a change of the base template. What stays open in the base template is the parents: Hangfire.Core, Pulumi and System.ServiceModel.Primitives still pull the vulnerable versions into every consumer that carries no direct references of its own, and the infrastructure project still resolves the old OpenTelemetry version. The PBI raises the three parents to versions whose transitive closure is clean. Where a parent has no clean release, the central version of the vulnerable package is activated by a versionless direct reference in the base template project that references the parent, with the reason next to it, so that a consumer needs none. The audit runs through Invoke-DependencyAudit.ps1 of the shared template pipeline tooling on the authoring solution and on every generated case and fails the run on any finding; the template adds no audit step of its own.

Acceptance criteria

AC1 Given the base template before the change, when the dependency audit runs over a generated case with the HangFire scheduler and the infrastructure project and over a solution composed by a consuming template that carries no direct references of its own, then it either reproduces the advisories of item 4 of the findings register with the parent of each, or the register records with the commit that they are already cleared there (ADR-0028, NFR-02, docs/architecture/ecosystem-composition.md).
AC2 Given the base template after the change, when the audit runs over the authoring solution and over every generated case, then Hangfire.Core, Pulumi and System.ServiceModel.Primitives resolve to versions whose closure holds none of the advisories, or the versionless direct reference that activates the central version sits in the base template project that references the parent with its reason, and no vulnerable package is reported (ADR-0028, NFR-02, model/template-parameters/connectsoft-base.yaml lists SchedulerModelType).
AC3 Given a solution composed by a consuming template on the changed base template, when the consumer carries no direct reference of its own for these packages, then its audit is clean, and the infrastructure project resolves the centrally declared OpenTelemetry version (NFR-02, ADR-0028).
AC4 Given the template pipeline, when Invoke-DependencyAudit.ps1 of the shared tooling finds a vulnerable package of any severity in the authoring solution or in a generated case, then the run fails with the package, the advisory and the case named, and item 4 is marked fixed in the status table of the register only when the audit is green (FR-11, NFR-02).
Traces: adrs ADR-0028
Traces: requirements FR-11
Relates: nfrs NFR-02
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md, model/template-parameters/connectsoft-base.yaml

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-1168 Baseline audit of what is open before the change verification The audit output of a generated case with the HangFire scheduler and the infrastructure project and of a consumer composition without direct references of its own is recorded in item 4 of Docs/Consumer-Reported-Findings.md of the template, with the commit and with the parent of each advisory or the statement that it is already cleared, which proves AC1 of AIFACTORY-US-233. ConnectSoft.BaseTemplate
AIFACTORY-TASK-586 Vulnerable transitive dependencies cleared implementation The Hangfire.Core, Pulumi and System.ServiceModel.Primitives paths are raised, or the versionless direct reference sits in the base template project that references the parent, so that the direct and transitive audit of the authoring and generated projects reports no known vulnerability, a consumer needs no direct reference of its own and the infrastructure project resolves the centrally declared OpenTelemetry version. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1094 Dependency audit of the shared tooling for the authoring solution and every generated case operations The manifest and the pipelines of the base template run Invoke-DependencyAudit.ps1 of the shared template pipeline tooling on the authoring solution and on each generated case; a finding or an unavailable audit source fails the run with package, advisory and case named, and the template holds no audit step of its own. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1095 Register item 4 closed with the raised versions documentation Item 4 of Docs/Consumer-Reported-Findings.md of the template lists the raised parent versions, any versionless direct reference with its project and reason, and the audit output, and the status table marks the item fixed. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1096 Verify the audit of the authoring, generated and consumer-composed solutions verification Run the audit on the authoring solution, on every generated case and on a consumer composition without direct references of its own; zero findings, and a planted vulnerable pin fails the audit, which proves AC2 to AC4 of AIFACTORY-US-233 (NFR-02). ConnectSoft.BaseTemplate

AIFACTORY-US-234: Base template: consuming templates receive QueryModel through a migration step and the Scripts folder through the check of the shared template pipeline, which fails their pipeline on drift

enabling · persona asset-maintainer As an asset maintainer, I want a defined path by which a change of the base template reaches the templates composed on it, so that a default-on feature or a new script of the base template no longer breaks or silently bypasses its consumers.

Items 5 and 6 of the findings register of the template (Docs/Consumer-Reported-Findings.md of the template) are two forms of one gap. QueryModel shipped with UseQueryModel on by default and an unconditional AddQueryModel call that binds a validated configuration section, so every consuming host without that section failed at startup when its submodule moved, and the three QueryModel package versions were missing from a consumer snapshot. The Scripts folder of the base template holds 35 files while a consumer root holds 14: the observability toolkit and four dashboards never arrive, and no mechanism keeps the two in step. The register proposes the repair for both: a change that makes configuration mandatory states its migration step, and a sync step replaces hand copies, in the shape a consumer already uses for its package snapshot, with a check mode for the pipeline and a write mode to regenerate. That shape exists once in the estate, as the snapshot check of the shared template pipeline tooling (Sync-PackageSnapshot.ps1 with a snapshot entry in build/template-ci.json). The Scripts sync and its check therefore belong beside it in the shared tooling of ConnectSoft.AzurePipelines, with one manifest entry per consumer, and not in the base template, where a script would ship inside every consumer submodule. ConnectSoft.AzurePipelines is a before-development repository (D114), so the sync with its check mode and its write mode is a task of this PBI in that repository. This PBI keeps in the base template what belongs there: the AddQueryModel call depends on the UseQueryModel symbol, a configuration invariant test names a missing section instead of failing at startup, and a consumer migration note lists, per change of the base template, the configuration and package entries a consumer adds and the manifest entry of the Scripts check. A consumer whose Scripts differ from the Scripts folder of its base-template submodule fails its own pipeline in check mode with the drifted files named. The check is wired by the adopters this campaign names, each in its own feature: the authorization server template (AIFACTORY-US-247), the gateway template (AIFACTORY-US-239), the identity template (AIFACTORY-US-243) and the Tenants template (AIFACTORY-US-253). The remaining consumers are listed in the migration note in the order of the rollout ledger of the shared tooling.

Acceptance criteria

AC1 Given a host generated with UseQueryModel off and no QueryModel configuration section, when it starts, then it starts without a binding failure; given the symbol on and a configuration root without the section, when the configuration invariant test runs, then it fails and names the root and the section before any host starts (item 5 of the findings register, ADR-0028, docs/architecture/ecosystem-composition.md).
AC2 Given a consuming template whose Scripts folder differs from the Scripts folder of its base-template submodule, when the Scripts check of the shared template pipeline tooling runs in check mode through the entry of the consumer in build/template-ci.json, then it exits with an error that lists the missing and the changed files, and when it runs in write mode, then the folders are equal and the check passes; the base template holds no copy of the sync script (item 6 of the findings register, ADR-0028, FR-11).
AC3 Given a change of the base template that makes a configuration section or a package entry mandatory, when the consumer migration note is read, then it lists the change with the step a consumer takes, the manifest entry of the Scripts check, the four adopters that wire the check in this campaign and the consumers that still follow, and items 5 and 6 are marked fixed in the status table of the register (ADR-0028, model/components.yaml).
Traces: adrs ADR-0028
Traces: requirements FR-11
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-587 QueryModel rollout and Scripts sync path for the consuming templates implementation The AddQueryModel call depends on UseQueryModel and a configuration invariant test names a missing QueryModel section; the consuming templates receive the QueryModel symbol through the documented migration step and the Scripts folder through a documented sync step with a guard, the Scripts check of the shared template pipeline tooling, that fails their pipeline when they drift; the two findings are closed in the register. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1462 Scripts sync with check and write mode in the shared template pipeline tooling implementation A Scripts sync script of template-ci/v1 stands beside Sync-PackageSnapshot.ps1: in check mode it compares the Scripts folder of a consumer with the Scripts folder of its base-template submodule and exits with an error that lists the missing and the changed files, and in write mode it writes the folder; the manifest schema holds one Scripts entry per consumer beside the snapshot entry, and a self-test covers an aligned folder, a removed file, a changed file and the write mode. ConnectSoft.AzurePipelines
AIFACTORY-TASK-1097 Drift fixture for the Scripts check and the QueryModel invariant fixture A self-test removes the QueryModel section from one configuration root and asserts that the invariant test names root and section; a copy of the Scripts folder with one file removed and one changed is run through the Scripts check of the shared tooling in check mode, which names both, and in write mode, which restores them. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1098 Consumer migration note and closure of items 5 and 6 documentation A page of the template documentation lists, per change of the base template that adds mandatory configuration or package entries, the step a consumer takes, the entry of the Scripts check in build/template-ci.json, the four adopters of this campaign and the consumers that still follow in the order of the rollout ledger; items 5 and 6 of Docs/Consumer-Reported-Findings.md of the template are marked fixed. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1099 Verify the sync step and the invariant on a consumer copy verification Run the Scripts check of the shared tooling in check mode against a drifted consumer copy and against an aligned one, and run the invariant test with and without the section; the drifted cases fail and the aligned cases pass, which proves AC1 to AC3 of AIFACTORY-US-234 (ADR-0028). ConnectSoft.BaseTemplate

AIFACTORY-US-235: Base template: the register holds no open finding and the packed template passes the cases of the shared template pipeline with complete reports before the package publishes

evidence · persona asset-maintainer As an asset maintainer, I want the closure of the findings to be proven by the template pipeline on generated solutions, so that the Factory scaffolds its first service from a package whose green result is complete, audited and reproducible.

The amendment of ADR-0028 that scaffolds the Factory services from the base template puts the extensions the templates need before the first scaffold into the build backlog, and the feature states that the Factory scaffolds from the base template only after the open findings are closed. This PBI is the proof. The gate is the one mechanism the estate has, the shared template pipeline of ConnectSoft.AzurePipelines (template-ci/v1): candidate packing, scaffold cases, result validation, dependency audit, package protection and publication evidence bound to the candidate hash. The rollout ledger of that tooling schedules the base template next. The preset matrix of build/Test-BaseTemplateRegressions.ps1 becomes the Domain and Compatibility cases of the build/template-ci.json manifest, the template pipeline imports the shared installer jobs, and publication requires the complete reports of every case bound to the candidate. For each case the candidate is installed and the solution is generated, restored and built in Release; it passes the configuration smoke tests of the substitution fix as a case validator, runs its tests with the discovery and completion checks against the services the manifest declares, SQL Server for the persistence and messaging tests and a co-hosted silo, and passes the dependency audit. A case that fails any stage fails the run with the case and the stage named, and no later stage of that case counts as evidence. Publication pushes a version that is not yet on the ConnectSoft feed. The status table of the findings register then shows items 4, 5, 6 and 7 and the substitution defect as fixed, each with the stage of the gate that guards it, so that a finding cannot reopen without a red run. The agent host template moves its base-template submodule to the published state in its own release feature.

Acceptance criteria

AC1 Given the base template with the work of this feature, when the template pipeline runs the shared installer jobs with build/template-ci.json, then the candidate is packed once and installed, every case of the selected profile is generated, restored and built in Release, passes the configuration smoke tests, runs its tests with the discovery and completion checks against the services the manifest declares, SQL Server and a co-hosted silo, and passes the dependency audit before publication (ADR-0028 amendment on scaffolding from the base template, FR-11).
AC2 Given a planted unterminated provider string, a planted truncated test run and a planted vulnerable pin, when the pipeline runs with each, then each run fails at the stage that guards the finding with the case named and publication is not reached (FR-11, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md).
AC3 Given complete reports of every case bound to the candidate hash, when the findings register is read, then its status table shows items 4, 5, 6 and 7 and the substitution defect as fixed with the guarding stage named, the package is published with a version that was not on the feed, and a fresh install of that version generates the default case whose configuration parses (ADR-0028, model/components.yaml).
Traces: adrs ADR-0028
Traces: requirements FR-11
Depends on AIFACTORY-US-231, AIFACTORY-US-232, AIFACTORY-US-233, AIFACTORY-US-234
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md, docs/architecture/catalogs/templates.md

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-1100 Preset matrix as Domain and Compatibility cases of the manifest with the shared installer jobs operations The presets of build/Test-BaseTemplateRegressions.ps1 are the Domain and Compatibility cases of build/template-ci.json, each with its arguments, test filter, required services and the configuration smoke tests as its validator; azure-pipelines-template.yml imports template-ci/v1/installer-jobs.yml of the shared tooling; publication requires the complete reports of every case bound to the candidate hash and refuses a version that is already on the feed. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1101 Planted regressions of the three guarded findings fixture Pipeline fixtures plant an unterminated provider string, a truncated run and a vulnerable pin, and assert that each run fails at its guarding stage with the case named and that publication is not reached. ConnectSoft.BaseTemplate
AIFACTORY-TASK-1102 Verify the closed register on a green run and on the planted runs verification One green pipeline run reaches publication with the status table of the register showing no open finding, and the three planted runs fail before it; together they prove AC1 to AC3 of AIFACTORY-US-235 (ADR-0028, FR-11). ConnectSoft.BaseTemplate

AIFACTORY-US-104: Base template: open consumer findings closed before the first scaffold is delivered and proven on a generated solution

enabling · persona asset-maintainer As an asset maintainer, I want BaseTemplate to carry open consumer findings closed before the first scaffold, so that it serves every Factory service that is not a gateway or an agent host, and every generated product module (D94, D95) without later rework.

This is the integration PBI of the feature. The base template keeps a register of findings reported by its consuming templates, and four of its items are open together with a generation defect the agent host template inherits. With the substitution fixed, the test runs checked for completeness by the shared template pipeline, the vulnerable dependency paths cleared at their parents, the migration step for QueryModel and the Scripts check for the consumers in place, and the cases of the shared template pipeline guarding each of them, the asset maintainer runs the pipeline end to end and publishes the package. A case that fails any stage blocks publication. The migrated tasks sit under the PBIs that deliver them, and the verification task of this PBI is the proof on the published package. The feature is done when the status table of the register shows no open item, the package is on the feed with a verified version, and a solution generated from it builds and passes with a complete test run, so that the first Factory service and the agent host template compose on a base template without known defects.

Acceptance criteria

AC1 Given the template repository ConnectSoft.BaseTemplate with the work of this feature, when the template is packed, installed and instantiated in its pipeline, then the generated solution builds and its tests pass through the completeness check before the package publishes with a verified version (ADR-0028, model/components.yaml).
AC2 Given the work of AIFACTORY-TASK-584 (persistence provider substitution fixed in the generated configuration) is done, then the PostgreSQL and MySQL constant substitutions keep their closing quote, the generated configuration of every provider parses, and the configuration smoke tests of the generated matrix pass for all providers (ADR-0028, docs/architecture/ecosystem-composition.md).
AC3 Given the work of AIFACTORY-TASK-585 (test session timeout audited) is done, then the test session timeout is set so that no suite is truncated, a truncated run fails instead of passing because the suites run through the shared template pipeline, and the finding is closed in the register (ADR-0028).
AC4 Given the work of AIFACTORY-TASK-586 (vulnerable transitive dependencies cleared) is done, then the Hangfire.Core, Pulumi and System.ServiceModel.Primitives paths are cleared at the parent, so that the direct and transitive audit of the authoring and generated projects reports no known vulnerability and a consumer needs no direct reference of its own (ADR-0028).
AC5 Given the work of AIFACTORY-TASK-587 (QueryModel rollout and Scripts sync path for the consuming templates) is done, then the consuming templates receive the QueryModel symbol through a documented migration step and the Scripts folder through a documented sync step with a guard, the Scripts check of the shared template pipeline, that fails their pipeline when they drift; the authorization server, gateway, identity and Tenants templates wire it in their own features, the remaining consumers are listed in the migration note, and the two findings are closed in the register (ADR-0028).
Traces: adrs ADR-0028
Depends on AIFACTORY-US-231, AIFACTORY-US-232, AIFACTORY-US-233, AIFACTORY-US-234, AIFACTORY-US-235
Sources model/components.yaml, docs/architecture/ecosystem-composition.md, docs/architecture/adr/0028-one-repository-and-deployable-per-service.md

Tasks

Task Kind Expected output Repository
AIFACTORY-TASK-673 Verify base-template-findings-delivered by running the declared command verification Run dotnet build -c Release and dotnet test -c Release --no-build on the solution generated from the published package; they pass with a complete run and prove AC1 to AC5 of AIFACTORY-US-104. ConnectSoft.BaseTemplate