DylansTechStack.Pro.Licensing
0.9.0
dotnet add package DylansTechStack.Pro.Licensing --version 0.9.0
NuGet\Install-Package DylansTechStack.Pro.Licensing -Version 0.9.0
<PackageReference Include="DylansTechStack.Pro.Licensing" Version="0.9.0" />
<PackageVersion Include="DylansTechStack.Pro.Licensing" Version="0.9.0" />
<PackageReference Include="DylansTechStack.Pro.Licensing" />
paket add DylansTechStack.Pro.Licensing --version 0.9.0
#r "nuget: DylansTechStack.Pro.Licensing, 0.9.0"
#:package DylansTechStack.Pro.Licensing@0.9.0
#addin nuget:?package=DylansTechStack.Pro.Licensing&version=0.9.0
#tool nuget:?package=DylansTechStack.Pro.Licensing&version=0.9.0
DTS Pro
The opinionated, paid layer on DTS.DDD, the open DDDToolkit core. DTS.DDD is usable by anyone and makes no choices for an application. A DTS Pro package makes those choices: it is a supporting domain that an application adds whole.
| Package | Namespace | What it is |
|---|---|---|
DylansTechStack.Pro.Tenancy |
DTS.Tenancy |
Tenancy: tenants, their organization tree, seats and roles over a permission catalogue, a service per aggregate, and the access manager. No database in it. |
DylansTechStack.Pro.Tenancy.Abstractions |
DTS.Tenancy |
Tenancy's markers for domain classes, such as [OfTenant]. |
DylansTechStack.Pro.Tenancy.EntityFramework |
DTS.Tenancy.EntityFramework |
Tenancy in a context of your own, on every provider. |
DylansTechStack.Pro.Tenancy.Postgres |
DTS.Tenancy.Postgres |
Tenancy's queries as SQL functions, its row level security policies, and the start-up checks. |
DylansTechStack.Pro.Tenancy.AspNetCore |
DTS.Tenancy.AspNetCore |
app.UseTenantSelection(): the Tenant header names the tenant of a request, and the caller's active seat there becomes the Tenancy user. |
DylansTechStack.Pro.Membership |
DTS.Membership |
Membership: access to a resource through its members and the roles they hold. No database in it. |
DylansTechStack.Pro.Membership.Abstractions |
DTS.Membership |
Membership's markers for domain classes, such as [At]. |
DylansTechStack.Pro.Membership.EntityFramework |
DTS.Membership.EntityFramework |
A resource's members in a context of your own. |
DylansTechStack.Pro.Licensing |
DTS.Licensing |
The licence key check. Tenancy and Membership depend on it. |
DylansTechStack.Pro.Membership.Postgres |
DTS.Membership.Postgres |
A resource's access queries as SQL functions for row access rules. |
The docs are on the public docs site, under Tenancy and Membership.
The repository
core/is the public repository, DylanSnel/DDDToolkit, as a git submodule. Every project here references the core's projects in it, and the root'sDirectory.Build.props,Directory.Build.targetsandDirectory.Packages.propsimport the core's.Source/holds the packages, in one folder per domain:Source/TenancyandSource/Membership.Tests/holds their tests in the same domain folders:Tests/TenancyandTests/Membership.Tests/Togetherholds the tests that use Tenancy and Membership in one host. It also holds the core's tests that compile against both domains:DTS.Pro.Analyzers.TestsandDTS.Pro.HotChocolate.Testscompile the core's test project and add the parts that need Tenancy or Membership.Tests/Examples.Tenancy.TestsandTests/Examples.Tenancy.AppHost.Teststest the sample. The core's docs link to these paths, so they stay at the top ofTests/.Examples/Tenancyis the Tenancy sample.
Clone with the submodule:
git clone --recurse-submodules https://github.com/DIDIT-Solutions/DTS.Pro.git
Versions and the feed
Every DylansTechStack.* package has one version, the core's included. A release of DTS Pro is made from a commit
whose core/ is the core's release of the same version. The core's packages and DTS Pro's packages are on nuget.org,
so an application needs no extra feed, nuget.config or token.
The packages of DTS Pro are under the commercial licence in LICENSE. The packages of the core are under the MIT
licence.
- Development, tests, continuous integration, staging, demos and evaluation are free and need no licence key.
- An organisation with less than EUR 1,000,000 revenue and less than EUR 3,000,000 outside capital asks for a free Community licence key for production.
- Every other production use needs a commercial licence key.
Licence key
An application that uses DTS Pro sets its licence key at DTS:Licence in the configuration, in appsettings.json or
in the environment variable DTS__Licence.
{
"DTS": {
"Licence": "DTS1.eyJpZCI6Ij...In0.MEUCIQ..."
}
}
AddTenancyCoreandAddMembershipregister their module withAddLicensedModule. That method registers the hosted serviceLicenceCheckonce.LicenceCheckreads the key once when the host starts. It checks the signature with the public key inLicenceCheck.PublicKey, the expiry date, and that the key lists every module in use.- A valid key is logged as information. A missing, invalid or expired key, or a key without a module in use, is
logged as a warning in the log category
DTS.Licensing. In the Development environment it is logged as information. - The check never stops the host and needs no network.
A key is DTS1., the licence as base64url JSON, a period, and an ECDSA P-256 signature over the JSON part. The
licence holds an id, the customer, the modules, the issue day and the last valid day.
build/LicenceTool makes the keys. It is no package.
# A new key pair. The public key goes into LicenceCheck.PublicKey.
dotnet run --project build/LicenceTool -- new-keys
# A key for a customer. The private key comes from DTS_LICENCE_PRIVATE_KEY.
dotnet run --project build/LicenceTool -- sign --customer "Harbor Works" --modules Tenancy,Membership --expires 2027-12-31
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Microsoft.Extensions.Configuration.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.0)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on DylansTechStack.Pro.Licensing:
| Package | Downloads |
|---|---|
|
DylansTechStack.Pro.Membership.EntityFramework
Stores Membership with Entity Framework Core: the two member tables of a resource in the application's own context, under the application's names, the role class of a resource whose roles are kept, and the access questions of each kind of resource answered inside that context's own statements. |
|
|
DylansTechStack.Pro.Tenancy
Tenants, their organization tree, seats with placements and role grants, roles over a permission catalogue, and the access questions, database-agnostic. |
GitHub repositories
This package is not used by any popular GitHub repositories.