DRN.Framework Overview
Documentation And Source References
For a NuGet consumer, start in the application project:
- Identify the package and resolved version for the relevant target framework in
obj/project.assets.jsonorpackages.lock.json. Project files andDirectory.Packages.propsshow requested versions. - In the assets file, combine a
packageFoldersroot with the matchinglibrariesentry'spath. Open the package README named in the.nuspec, the release notes if present, and the XML documentation beside the target assembly when available. This works with custom NuGet cache locations and transitive dependencies. - Check the installed signatures and the application's own registration, settings and call sites before applying examples. These skills describe the framework under development. Older packages can differ in overloads, defaults and analyzer IDs. If local evidence is insufficient, use documentation for that exact version or the repository commit recorded in its package metadata. State which behavior remains unverified.
In a framework source checkout, use the repository profile or discover the owning projects locally. In a consuming application, its own project files and CI define commands and conventions. Example entity, context and program names stand for application-owned types.
Framework Stack
| When working on | Start with |
|---|---|
| Contracts, IDs, entities, exceptions, analyzers | SharedKernel. Contract projects can depend on this package alone. |
| Aggregates, DTO mapping, repository boundaries | Domain design |
| DI, settings, diagnostics, HTTP, cancellation, ID utilities | Utils |
| Persistence, migrations, repositories, PostgreSQL | EntityFramework |
| Host lifecycle, endpoints, security, Razor, static assets | Hosting |
| DTT, data attributes, contexts, integration hosts | Testing |
| Jobs or messaging | The installed Jobs or MassTransit package and the application's registration |
DRN Framework Maintenance Reference
Register modules through their extensions and DRN lifetime attributes. Avoid duplicate manual registrations. Validate each provider's own scope. SharedKernel owns JSON and exception semantics. Hosting owns HTTP responses. Check the application's composition root for module and startup-hook usage.
Maintenance Reference: Configuration Sources
AddDrnSettings applies later sources over earlier ones:
appsettings.json, thenappsettings.{Environment}.json.- User secrets when the application assembly is available.
- Environment variables with
ASPNETCORE_, thenDOTNET_, then unprefixed keys. - Mounted key-per-file and JSON settings under
/appconfig. Override the root throughIMountedSettingsConventionsOverride. - Command-line arguments.
Set Environment to Development, Staging or Production before loading environment-specific settings. Missing or unknown values fail startup. App data roots resolve earlier. Use the Utils skill for those roots, explicit application and instance IDs, and key rotation.
Maintenance Reference: Migration And Prototype Invariants
Production and Staging require explicit connection strings. Production never auto-migrates. Staging migrates only with AutoMigrateStaging and cannot recreate a prototype. Development defaults to automatic migration. Follow EntityFramework for prototype, seeding and connection safeguards.
Use explicit TemporaryApplication, SkipValidation or a dedicated test context. Keep production invariants active. Hosting owns temporary-host behavior.
Testing and maintenance
Follow repository execution gates and Testing for settings and container setup. PostgreSQL binding does not start RabbitMQ.
Update owning package docs and affected skills when public behavior changes. Search old names, defaults and examples for drift. Follow the current repository profile for release and packaging rules. Run git diff --check after documentation edits.