feat: implement strangler-fig-demo Session 1 (backend + smoke script)
Builds the four-seam, three-write-path reference demo backend: case-framework (seam D stand-in), legacy-backend/frontend (SQL Server, seams A/B/C targets), and new-backend (Domain/Application/Infrastructure.*/Api implementing the source resolver, take/release-ownership, write-through translator, and owned assessment flow), wired together via docker-compose with a plain placeholder frontend standing in for the Angular portal until Session 2. All 11 Architecture.Tests pass and scripts/smoke.sh passes end-to-end against a fresh `docker compose up`, covering acceptance criteria 1-3 and 7-22. Fixes two real domain bugs found only once the stack ran for real: the BSN eleven-proof checksum trivially passes all-zero digits, and the adoption mapper silently treated a partial legacy address as absent instead of failing loudly. Also fixes several environment-specific integration issues (rootless Podman/SELinux bind-mount permissions, a buildah NuGet layer-caching bug, SqlClient's invariant-globalization incompatibility, and an nginx path-prefix mismatch for the legacy frontend). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,80 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace New.Infrastructure.Persistence.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class InitialCreate : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.CreateTable(
|
||||
name: "legacy_ownership",
|
||||
columns: table => new
|
||||
{
|
||||
legacy_aanvraag_id = table.Column<int>(type: "integer", nullable: false),
|
||||
registration_application_id = table.Column<Guid>(type: "uuid", nullable: false),
|
||||
taken_over_at = table.Column<DateTime>(type: "timestamp", nullable: false),
|
||||
domain_writes_since = table.Column<int>(type: "integer", nullable: false, defaultValue: 0)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_legacy_ownership", x => x.legacy_aanvraag_id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "registration_applications",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "uuid", nullable: false),
|
||||
Bsn = table.Column<string>(type: "character varying(9)", maxLength: 9, nullable: false),
|
||||
Surname = table.Column<string>(type: "text", nullable: false),
|
||||
Initials = table.Column<string>(type: "text", nullable: false),
|
||||
AddressStreet = table.Column<string>(type: "text", nullable: true),
|
||||
AddressNumber = table.Column<string>(type: "text", nullable: true),
|
||||
AddressPostalCode = table.Column<string>(type: "text", nullable: true),
|
||||
AddressCity = table.Column<string>(type: "text", nullable: true),
|
||||
Email = table.Column<string>(type: "text", nullable: true),
|
||||
Phone = table.Column<string>(type: "text", nullable: true),
|
||||
PreferredChannel = table.Column<string>(type: "text", nullable: false),
|
||||
DiplomaCode = table.Column<string>(type: "text", nullable: false),
|
||||
DiplomaCountryOfIssue = table.Column<string>(type: "text", nullable: false),
|
||||
DiplomaIssuedOn = table.Column<DateOnly>(type: "date", nullable: false),
|
||||
AssessmentOutcome = table.Column<string>(type: "text", nullable: true),
|
||||
AssessmentMotivation = table.Column<string>(type: "text", nullable: true),
|
||||
AssessmentVerifiedItems = table.Column<List<string>>(type: "text[]", nullable: false),
|
||||
AssessmentExceptionReason = table.Column<string>(type: "text", nullable: true),
|
||||
AssessmentRejectionCategory = table.Column<string>(type: "text", nullable: true),
|
||||
AssessmentDecidedOn = table.Column<DateOnly>(type: "date", nullable: true),
|
||||
CaseFrameworkCaseId = table.Column<Guid>(type: "uuid", nullable: true),
|
||||
CaseExternalReference = table.Column<string>(type: "text", nullable: true),
|
||||
CaseProcessStatus = table.Column<string>(type: "text", nullable: true),
|
||||
ReceivedOn = table.Column<DateOnly>(type: "date", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_registration_applications", x => x.Id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_legacy_ownership_registration_application_id",
|
||||
table: "legacy_ownership",
|
||||
column: "registration_application_id",
|
||||
unique: true);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropTable(
|
||||
name: "legacy_ownership");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "registration_applications");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user