diff --git a/.agents/agents/sdk-consumer-setup.md b/.agents/agents/sdk-consumer-setup.md index b356a417..8e5066c3 100644 --- a/.agents/agents/sdk-consumer-setup.md +++ b/.agents/agents/sdk-consumer-setup.md @@ -2,12 +2,12 @@ ## Goal -Help a consuming repository adopt or troubleshoot `Purview.DotNetProjectSdk` correctly, without breaking existing build behaviour. +Help a consuming repository adopt or troubleshoot `Purview.BuildSdk` correctly, without breaking existing build behaviour. ## Workflow 1. Confirm the SDK is imported in `Directory.Build.props`/`Directory.Build.targets` via - `` and the matching `Sdk.targets` import. + `` and the matching `Sdk.targets` import. 2. Check pre-import bootstrap properties are set **before** the `Sdk.props` import when they must affect evaluation: `NamespacePrefix`, `UsePackageJsonVersion`, `RootPackageJson`. 3. If version resolution looks wrong, verify `package.json` discovery: explicit `RootPackageJson`, then CI diff --git a/.agents/prompts/sdk-diagnose-agent-folder-copy.md b/.agents/prompts/sdk-diagnose-agent-folder-copy.md index 49ad1c21..85ad4445 100644 --- a/.agents/prompts/sdk-diagnose-agent-folder-copy.md +++ b/.agents/prompts/sdk-diagnose-agent-folder-copy.md @@ -1,6 +1,6 @@ # sdk-diagnose-agent-folder-copy (generic prompt spec) -Diagnose why the bundled `.agents/**` folder from `Purview.DotNetProjectSdk` did not appear at the expected +Diagnose why the bundled `.agents/**` folder from `Purview.BuildSdk` did not appear at the expected destination in a consuming repository. ## Required behaviour diff --git a/AGENTS.md b/AGENTS.md index 3cd0fce2..a23f94c8 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -7,7 +7,7 @@ This repository contains the `Purview.EventSourcing` framework, its incremental - This file is the repository-wide source of truth for AI agents. More-specific `AGENTS.md` files, if added later, take precedence for their subtrees. - `.github/copilot-instructions.md` bootstraps GitHub Copilot into this file; keep it aligned if instruction locations change. - Follow explicit user instructions first, then the nearest applicable repository instructions, then established code patterns. -- Operate only in this repository unless the user explicitly expands the scope. `P:\GitHub\purview-dev\purview-sourcegeneratorframework` may be inspected as read-only reference material, but do not edit it or assume its conventions override this repository. +- Operate only in this repository unless the user explicitly expands the scope. `P:\GitHub\purview-dev\sourcegenerator-framework` may be inspected as read-only reference material, but do not edit it or assume its conventions override this repository. - Never read, copy, log, or commit secrets from excluded files, environment variables, user profiles, local configuration, test output, or provider credentials. ## Repository boundaries and working tree safety @@ -56,7 +56,7 @@ Do not introduce a second version source, dependency-version location, or parall Use repository-local skills when their trigger applies: - `dotnet-tunit` for writing TUnit tests and `tunit-test-runner` for executing or filtering them. -- `project-placement-defaults`, `sdk-configuration-reference`, and `sdk-project-behavior-and-detection` for project layout or `Purview.DotNetProjectSdk` behavior. +- `project-placement-defaults`, `sdk-configuration-reference`, and `sdk-project-behavior-and-detection` for project layout or `Purview.BuildSdk` behavior. - `git-conventional-commits` for commit work and `lefthook-integration` for Git-hook changes. ## Architecture and domain invariants @@ -127,7 +127,7 @@ Use repository-local skills when their trigger applies: - Prefer backward-compatible additions. Do not rename, remove, narrow accessibility, or alter semantics without explicit approval and corresponding migration/release documentation. - Centralize package versions in `Directory.Packages.props`; project files should normally contain versionless `PackageReference` entries. - Reuse existing dependencies when practical. New dependencies require a clear need, compatible target frameworks, acceptable licensing/security posture, and correct public/private asset flow. -- Respect `Purview.DotNetProjectSdk` inference before adding manual properties or references. Repository-wide bootstrap properties that affect `Sdk.props` belong before the SDK import in `src/Directory.Build.props`. +- Respect `Purview.BuildSdk` inference before adding manual properties or references. Repository-wide bootstrap properties that affect `Sdk.props` belong before the SDK import in `src/Directory.Build.props`. - Place source projects under `src/src` and test projects under `src/tests`, beside the closest peer. Follow established suffixes such as `.UnitTests`, `.IntegrationTests`, and `.PerformanceTests`. Performance harnesses are console projects consolidated under `src/src/Benchmarks` (`Benchmarks.csproj`), not test projects. - Keep packability explicit and package metadata consistent. Verify package contents when changing build assets, analyzers, transitive targets, README files, or project-reference packing. @@ -151,7 +151,7 @@ Use repository-local skills when their trigger applies: dotnet test --project src/EventSourcing.slnx --configuration Debug --treenode-filter "/*/*/*/*" --ignore-exit-code 8 ``` -- PR validation restores and builds the Release solution, then runs the unit-test tree filter `/*/*/*/*[Category=Unit]` (the `Purview.DotNetProjectSdk` applies `[assembly: TUnit.Core.Category("Unit")]` to unit-test projects) and emits TRX results. +- PR validation restores and builds the Release solution, then runs the unit-test tree filter `/*/*/*/*[Category=Unit]` (the `Purview.BuildSdk` applies `[assembly: TUnit.Core.Category("Unit")]` to unit-test projects) and emits TRX results. - Unit tests should cover domain logic, contracts, failure behavior, and regressions without external infrastructure. - Source-generator tests should assert generated code and diagnostics using the existing testing framework. - Provider integration tests use `src/tests/SharedTestingFramework` and Testcontainers or provider infrastructure. Run affected-provider tests for translation, persistence, concurrency, or serialization changes when infrastructure is available. diff --git a/Justfile b/Justfile index df6abffc..47ac5f44 100644 --- a/Justfile +++ b/Justfile @@ -112,7 +112,7 @@ restore *args: # Displays the current package version from package.json [group('Build and Test')] current_version: - echo "==> Current version: {{ GREEN }}{{ current_version }}{{ NORMAL }} (defined in package.json and automatically included in the build output through the Purview.DotNetProjectSdk package)" + echo "==> Current version: {{ GREEN }}{{ current_version }}{{ NORMAL }} (defined in package.json and automatically included in the build output through the Purview.BuildSdk package)" # Run the source-generator performance harness (pass --benchmark for larger runs; requires Release for meaningful numbers) [group('Performance Tests')] diff --git a/README.md b/README.md index f1870d48..46708e56 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Purview EventSourcing [![NuGet](https://img.shields.io/nuget/v/Purview.EventSourcing.svg)](https://www.nuget.org/packages/Purview.EventSourcing) -[![Release](https://github.com/purview-dev/eventsourcing/actions/workflows/release.yml/badge.svg)](https://github.com/purview-dev/eventsourcing/actions/workflows/release.yml) +[![Release](https://github.com/purview-dev/event-sourcing/actions/workflows/release.yml/badge.svg)](https://github.com/purview-dev/event-sourcing/actions/workflows/release.yml) Purview EventSourcing is a .NET event sourcing framework for building aggregate-based applications with provider-agnostic store facades, source-generated aggregates, transaction coordination, and storage packages for SQL Server, PostgreSQL, MongoDB, Azure Storage, Azure Cosmos DB, and in-memory. diff --git a/docs/wiki/Release-Flow.md b/docs/wiki/Release-Flow.md index 5c1b88e2..2fe76f65 100644 --- a/docs/wiki/Release-Flow.md +++ b/docs/wiki/Release-Flow.md @@ -21,7 +21,7 @@ and releases. Consuming repositories own configuration (through `purview-build.j Integration tests are never discovered in CI: `purview-build.json` sets `Build:TestPatterns` to `*Tests.csproj`, `Build:TestProjects` to `*UnitTests.csproj`, and `Build:TestFilter` to `/*/*/*/*[Category=Unit]`, so only unit-test -projects (tagged `[Category=Unit]` by the `Purview.DotNetProjectSdk`) are executed; provider integration tests +projects (tagged `[Category=Unit]` by the `Purview.BuildSdk`) are executed; provider integration tests (which require Docker/Testcontainers) run only locally via `just test`. The performance harnesses live under `src/src/Benchmarks` (a single non-test `Benchmarks.csproj`) and run locally via `just perf-source-generator` / `just perf-runtime` / `just perf-sql-server`. diff --git a/global.json b/global.json index 3e5fc489..5bb362b4 100644 --- a/global.json +++ b/global.json @@ -3,7 +3,7 @@ "allowPrerelease": false }, "msbuild-sdks": { - "Purview.DotNetProjectSdk": "1.0.0-prerelease.55" + "Purview.BuildSdk": "1.0.0-prerelease.56" }, "test": { "runner": "Microsoft.Testing.Platform" diff --git a/package-lock.json b/package-lock.json index 1c2d50d8..b1ab4ccb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { - "name": "purview-eventsourcing", - "version": "2.0.0-prerelease.29", + "name": "purview-event-sourcing", + "version": "2.0.0-prerelease.33", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "purview-eventsourcing", + "name": "purview-event-sourcing", "version": "2.0.0-prerelease.29" } } diff --git a/package.json b/package.json index 78601cb6..961e6bc9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "purview-eventsourcing", - "version": "2.0.0-prerelease.32", + "name": "purview-event-sourcing", + "version": "2.0.0-prerelease.33", "license": "MIT", "author": { "name": "Kieron Lanning", @@ -8,10 +8,10 @@ }, "homepage": "https://purview.dev/projects/event-sourcing/", "bugs": { - "url": "https://github.com/purview-dev/eventsourcing/issues" + "url": "https://github.com/purview-dev/event-sourcing/issues" }, "repository": { "type": "git", - "url": "git+https://github.com/purview-dev/eventsourcing.git" + "url": "git+https://github.com/purview-dev/event-sourcing.git" } } \ No newline at end of file diff --git a/src/Directory.Build.props b/src/Directory.Build.props index eb109003..2f4bb4f0 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -3,7 +3,7 @@ Purview.EventSourcing - + @@ -40,7 +40,7 @@ Kieron Lanning Purview-Dev Copyright © $(CurrentYear) Purview-Dev - https://github.com/purview-dev/eventsourcing.git + https://github.com/purview-dev/event-sourcing.git $(PurviewProjectUrl) git purview-logo.png diff --git a/src/Directory.Build.targets b/src/Directory.Build.targets index 3d7b93aa..86aef8d5 100644 --- a/src/Directory.Build.targets +++ b/src/Directory.Build.targets @@ -1,5 +1,5 @@ - + diff --git a/src/src/Benchmarks/Program.cs b/src/src/Benchmarks/Program.cs index 1f52dd70..d9b21c49 100644 --- a/src/src/Benchmarks/Program.cs +++ b/src/src/Benchmarks/Program.cs @@ -6,7 +6,7 @@ // The suites run with the in-process toolchain: benchmarks execute directly in this process, which // avoids BenchmarkDotNet generating an out-of-process boilerplate project. The repository's -// Purview.DotNetProjectSdk cannot build under BenchmarkDotNet's generated project layout, and an +// Purview.BuildSdk cannot build under BenchmarkDotNet's generated project layout, and an // in-process run keeps the harness self-contained and fast to invoke. var mode = args.Length > 0 ? args[0].ToLowerInvariant() : "all"; diff --git a/src/src/Benchmarks/README.md b/src/src/Benchmarks/README.md index 15b807f9..da0d7cdf 100644 --- a/src/src/Benchmarks/README.md +++ b/src/src/Benchmarks/README.md @@ -13,7 +13,7 @@ built on **BenchmarkDotNet**. Three suites measure the framework's high-impact a Each run uses the **in-process toolchain** (`InProcessEmitToolchain`), so the benchmarks execute in the current process. This avoids BenchmarkDotNet generating an out-of-process boilerplate project, -which the repository's `Purview.DotNetProjectSdk` cannot build under. In-process runs are slightly +which the repository's `Purview.BuildSdk` cannot build under. In-process runs are slightly less isolated than out-of-process runs, but they keep the harness self-contained and fast to invoke, and allocation measurements use `GC.GetAllocatedBytesForCurrentThread` so they remain meaningful. diff --git a/src/src/CosmosDb/Sdk/README.md b/src/src/CosmosDb/Sdk/README.md index f4bf8b93..102b3bec 100644 --- a/src/src/CosmosDb/Sdk/README.md +++ b/src/src/CosmosDb/Sdk/README.md @@ -24,6 +24,6 @@ builder.Services.AddCosmosDbSnapshotQueryableEventStore(); - [Homepage](https://purview.dev/projects/event-sourcing/) - [Documentation](https://purview.dev/docs/event-sourcing/) -- [Provider feature matrix](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) +- [Provider feature matrix](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) Snapshot query translation capabilities differ by provider; consult the provider matrix before relying on deep nested predicates for complex value-object shapes. diff --git a/src/src/EventSourcing/Sdk/README.md b/src/src/EventSourcing/Sdk/README.md index 57b58916..3bb4d648 100644 --- a/src/src/EventSourcing/Sdk/README.md +++ b/src/src/EventSourcing/Sdk/README.md @@ -47,14 +47,14 @@ await store.SaveAsync(order, cancellationToken); - [Homepage](https://purview.dev/projects/event-sourcing/) - [Documentation](https://purview.dev/docs/event-sourcing/) -- [SQL Server guide](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/SQL-Server-Guide.md) -- [Provider feature matrix](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) +- [SQL Server guide](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/SQL-Server-Guide.md) +- [Provider feature matrix](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) When using snapshot-backed providers, especially SQL Server, read the provider docs before assuming deep predicates through complex scalar value object `.Value` members will translate. ## Agent skill integration -When installed from NuGet, `Purview.EventSourcing` ships bundled agent skills. Consuming repositories that use `Purview.DotNetProjectSdk` get those skills copied into `.agents\skills\` before build so supported coding agents can discover framework-specific guidance automatically. +When installed from NuGet, `Purview.EventSourcing` ships bundled agent skills. Consuming repositories that use `Purview.BuildSdk` get those skills copied into `.agents\skills\` before build so supported coding agents can discover framework-specific guidance automatically. To opt out, set: diff --git a/src/src/InMemory/Sdk/README.md b/src/src/InMemory/Sdk/README.md index 310adbb0..127d916b 100644 --- a/src/src/InMemory/Sdk/README.md +++ b/src/src/InMemory/Sdk/README.md @@ -57,5 +57,5 @@ if (order is null) ## Related packages -- [Core package](https://github.com/purview-dev/eventsourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` -- [Provider feature matrix](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) \ No newline at end of file +- [Core package](https://github.com/purview-dev/event-sourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` +- [Provider feature matrix](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) \ No newline at end of file diff --git a/src/src/MongoDB/Sdk/README.md b/src/src/MongoDB/Sdk/README.md index d125f43d..076198bc 100644 --- a/src/src/MongoDB/Sdk/README.md +++ b/src/src/MongoDB/Sdk/README.md @@ -26,6 +26,6 @@ builder.Services.AddMongoDBSnapshotQueryableEventStore(); - [Homepage](https://purview.dev/projects/event-sourcing/) - [Documentation](https://purview.dev/docs/event-sourcing/) -- [Provider feature matrix](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) +- [Provider feature matrix](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) Snapshot query translation capabilities differ by provider; consult the provider matrix and provider-specific guides before relying on deep nested predicates for complex value-object shapes. diff --git a/src/src/Postgres/Sdk/README.md b/src/src/Postgres/Sdk/README.md index 5e7c666f..fc82934c 100644 --- a/src/src/Postgres/Sdk/README.md +++ b/src/src/Postgres/Sdk/README.md @@ -92,6 +92,6 @@ Unsupported shapes fail during model creation, including arrays and collection t - [Homepage](https://purview.dev/projects/event-sourcing/) - [Documentation](https://purview.dev/docs/event-sourcing/) -- [Provider feature matrix](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) +- [Provider feature matrix](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/Provider-Feature-Matrix.md) - Includes behavior notes/caveats (`IsDeletedAsync` missing behavior, tolerant replay, principal requirements) - Includes snapshot payload/query-translation guidance for scalar value objects vs directly mapped complex mirrors diff --git a/src/src/SqlServer/Sdk/README.md b/src/src/SqlServer/Sdk/README.md index d7211a73..0cb6e714 100644 --- a/src/src/SqlServer/Sdk/README.md +++ b/src/src/SqlServer/Sdk/README.md @@ -52,6 +52,6 @@ Unsupported shapes fail during model creation, including arrays and collection t - [Homepage](https://purview.dev/projects/event-sourcing/) - [Documentation](https://purview.dev/docs/event-sourcing/) -- [SQL Server guide](https://github.com/purview-dev/eventsourcing/blob/main/docs/wiki/SQL-Server-Guide.md) +- [SQL Server guide](https://github.com/purview-dev/event-sourcing/blob/main/docs/wiki/SQL-Server-Guide.md) - Includes behavior notes/caveats (`IsDeletedAsync` missing behavior, tolerant replay, principal requirements) - Includes snapshot payload/query-translation guidance for scalar value objects vs directly mapped complex mirrors diff --git a/src/src/Validation.FluentValidation/Sdk/README.md b/src/src/Validation.FluentValidation/Sdk/README.md index 92b9c0e1..646b4f7c 100644 --- a/src/src/Validation.FluentValidation/Sdk/README.md +++ b/src/src/Validation.FluentValidation/Sdk/README.md @@ -52,5 +52,5 @@ await store.SaveAsync(order, cancellationToken); ## Related packages -- [Core package](https://github.com/purview-dev/eventsourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` -- [ZodSharp integration](https://github.com/purview-dev/eventsourcing/blob/main/src/src/Validation.ZodSharp/Sdk/README.md): `Purview.EventSourcing.Validation.ZodSharp` +- [Core package](https://github.com/purview-dev/event-sourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` +- [ZodSharp integration](https://github.com/purview-dev/event-sourcing/blob/main/src/src/Validation.ZodSharp/Sdk/README.md): `Purview.EventSourcing.Validation.ZodSharp` diff --git a/src/src/Validation.ZodSharp/Sdk/README.md b/src/src/Validation.ZodSharp/Sdk/README.md index c16cc68f..47f511e3 100644 --- a/src/src/Validation.ZodSharp/Sdk/README.md +++ b/src/src/Validation.ZodSharp/Sdk/README.md @@ -66,5 +66,5 @@ await store.SaveAsync(order, cancellationToken); ## Related packages -- [Core package](https://github.com/purview-dev/eventsourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` -- [FluentValidation integration](https://github.com/purview-dev/eventsourcing/blob/main/src/src/FluentValidationImpl/Sdk/README.md): `Purview.EventSourcing.FluentValidation` \ No newline at end of file +- [Core package](https://github.com/purview-dev/event-sourcing/blob/main/src/src/EventSourcing/Sdk/README.md): `Purview.EventSourcing` +- [FluentValidation integration](https://github.com/purview-dev/event-sourcing/blob/main/src/src/FluentValidationImpl/Sdk/README.md): `Purview.EventSourcing.FluentValidation` \ No newline at end of file