Franz.Common
3.0.0
dotnet add package Franz.Common --version 3.0.0
NuGet\Install-Package Franz.Common -Version 3.0.0
<PackageReference Include="Franz.Common" Version="3.0.0" />
<PackageVersion Include="Franz.Common" Version="3.0.0" />
<PackageReference Include="Franz.Common" />
paket add Franz.Common --version 3.0.0
#r "nuget: Franz.Common, 3.0.0"
#:package Franz.Common@3.0.0
#addin nuget:?package=Franz.Common&version=3.0.0
#tool nuget:?package=Franz.Common&version=3.0.0
Franz.Common
Foundational contracts and small cross-cutting utilities shared by Franz.Common applications.
Overview
Foundational contracts and small cross-cutting utilities shared by Franz.Common applications.
Responsibilities
This package contains framework-neutral building blocks. It is not the dependency-injection scanner, hosting bootstrapper, mediator implementation, or persistence provider. Those capabilities live in their dedicated packages.
The current source surface includes:
- Dependency lifetime markers:
IScopedDependencyandISingletonDependency. - Seeding contract:
ISeeder. - Collection helpers:
AddIfNotContains,AddRange, andIsNullOrEmpty. - Enumerable helper:
ForEach. - Environment predicates:
IsIntegration,IsValidation, andIsPreProduction. - Shared company/product-generation identifiers and resource definitions.
Installation
dotnet add package Franz.Common
Dependency lifetime markers
The marker interfaces describe intended lifetimes for implementations discovered by the separate Franz.Common.DependencyInjection package. They do not register services by themselves.
using Franz.Common.DependencyInjection;
public sealed class RequestContext : IScopedDependency
{
// Request-scoped state belongs here.
}
public sealed class ApplicationClock : ISingletonDependency
{
public DateTimeOffset UtcNow => DateTimeOffset.UtcNow;
}
When using assembly scanning, include the implementation assemblies in the scanner's discovery scope and apply the matching registration extensions from Franz.Common.DependencyInjection. Do not mark a service singleton if it captures scoped dependencies or mutable request state.
Seeding contract
ISeeder exposes an ordering value and asynchronous seed operation. The application owns orchestration, scope creation, execution policy, and failure handling; this package does not automatically run seeders.
using Franz.Common.Data;
public sealed class ReferenceDataSeeder : ISeeder
{
public int Order => 100;
public Task SeedAsync()
{
// Seed application-owned reference data.
return Task.CompletedTask;
}
}
Resolve seeders from an application scope, order them by Order, and await each operation. Decide explicitly whether a failure should stop subsequent seeders.
Utility extensions
Collection and enumerable extensions are convenience operations; they do not introduce persistence, concurrency, or transactional guarantees. Environment predicates are helpers over the host environment name. Use the host's canonical environment configuration and avoid treating these predicates as a security boundary.
Package boundaries
| Concern | Package |
|---|---|
| Marker-based service scanning | Franz.Common.DependencyInjection |
| Host initialization lifecycle | Franz.Common.Hosting |
| Mediator dispatch and pipelines | Franz.Common.Mediator |
| HTTP composition | Franz.Common.Http.Bootstrap |
| Persistence and repositories | Franz.Common.EntityFramework and provider packages |
Compatibility and maintenance
The package targets the repository's .NET 10 baseline. The package version is governed by the repository's release process; do not infer a package version from historical text in this guide.
License
MIT. See LICENSE.
| 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.14)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.14)
NuGet packages (8)
Showing the top 5 NuGet packages that depend on Franz.Common:
| Package | Downloads |
|---|---|
|
Franz.Common.Reflection
Shared utility library for the Franz Framework. |
|
|
Franz.Common.Mediator
Shared utility library for the Franz Framework. |
|
|
Franz.Common.DependencyInjection
Shared utility library for the Franz Framework. |
|
|
Franz.Common.Headers
Shared utility library for the Franz Framework. |
|
|
Franz.Common.Serialization
Shared utility library for the Franz Framework. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0 | 108 | 11/10/2026 |
| 2.3.4 | 893 | 11/1/2026 |
| 2.3.3 | 755 | 10/28/2026 |
| 2.3.2 | 553 | 10/27/2026 |
| 2.3.1 | 617 | 10/26/2026 |
| 2.3.0 | 820 | 7/21/2026 |
| 2.2.19 | 632 | 7/19/2026 |
| 2.2.18 | 622 | 7/19/2026 |
| 2.2.17 | 913 | 7/12/2026 |
| 2.2.16 | 645 | 7/2/2026 |
| 2.2.15 | 631 | 6/29/2026 |
| 2.2.14 | 643 | 6/29/2026 |
| 2.2.13 | 637 | 6/29/2026 |
| 2.2.12 | 632 | 6/28/2026 |
| 2.2.11 | 642 | 6/28/2026 |
| 2.2.10 | 638 | 6/28/2026 |
| 2.2.9 | 624 | 6/28/2026 |
| 2.2.8 | 633 | 6/28/2026 |
| 2.2.7 | 636 | 6/7/2026 |
| 2.2.6 | 649 | 6/6/2026 |