Core
The core packages provide the contracts (Cephalon.Abstractions), the composition runtime (Cephalon.Engine), the decorator framework (Cephalon.Behaviors.*), and the default identifier strategy (Cephalon.Ids.Sfid). Every Cephalon app uses at least the first two.
Packages
Section titled “Packages”Click any package name to jump to its source-doc (the canonical per-package detail synced from the engine repo).
| Package | NuGet ID | Maturity | What it ships |
|---|---|---|---|
| Abstractions | Cephalon.Abstractions | M3 | All public interfaces — IModule, IBehavior, IUserContext, ITenantContext, capability enums, manifest types. Zero runtime code. |
| Engine | Cephalon.Engine | M3 | The composition runtime — module discovery, capability negotiation, runtime catalog, manifest emission. |
| Behaviors (base) | Cephalon.Behaviors | M3 | The decorator base — IBehavior<TIn, TOut>, BehaviorPipelineBuilder, With* extension methods. |
| Behaviors.Http | Cephalon.Behaviors.Http | M3 | HTTP-flavoured decorators — WithRequireScope, WithProblemDetails, WithIdempotency, WithRateLimit. |
| Behaviors.Messaging | Cephalon.Behaviors.Messaging | M3 | Messaging-flavoured decorators — WithRetry, WithCircuitBreaker, WithOutbox, WithInbox. |
| Behaviors.Patterns | Cephalon.Behaviors.Patterns | M3 | Composite patterns — WithSaga, WithProcessManager, WithBulkhead. |
| Behaviors.Sourcegen | Cephalon.Behaviors.Sourcegen | M2 | Build-time source generator — emits typed registration glue for [Behavior]-tagged classes. |
| Ids.Sfid | Cephalon.Ids.Sfid | M3 | Sfid value type + EF Core converter + IIdGenerator<Sfid>. |
Install matrix
Section titled “Install matrix”| Scenario | Minimum packages |
|---|---|
| Anything Cephalon | Cephalon.Abstractions + Cephalon.Engine |
| Behaviors in a module | + Cephalon.Behaviors (matching *.Http / *.Messaging flavour) |
| Source-generated behavior registration | + Cephalon.Behaviors.Sourcegen |
| Sfid id strategy (default) | + Cephalon.Ids.Sfid |
Key types
Section titled “Key types”Cephalon.Abstractions
Section titled “Cephalon.Abstractions”public interface IModule{ ModuleDescriptor Describe();}
public interface IBehavior<TIn, TOut>{ Task<TOut> HandleAsync(TIn input, CancellationToken ct);}
public interface IUserContext{ string? UserId { get; } string? TenantId { get; } IReadOnlyList<string> Scopes { get; } bool IsAnonymous { get; }}
public enum Capability{ Data, Eventing, Identity, Tenancy, Observability, Edge, Agentics, Retrieval, Audit, EventSourcing}Full surface: API Reference → Cephalon.Abstractions.
Cephalon.Engine
Section titled “Cephalon.Engine”Entry points:
services.AddCephalonEngine(); // bare engineservices.AddCephalonAspNetCore(); // engine + ASP.NET Core host adapterservices.AddCephalonWorker(); // engine + worker host adapter
builder.AddModulesFromAssemblies(typeof(Program).Assembly);var app = builder.Services.Build(webBuilder);Cephalon.Behaviors.*
Section titled “Cephalon.Behaviors.*”// Decorator chain — applied right-to-leftbuilder.MapProfile<CreateOrderBehavior>(b => b .WithLogging() .WithRequireScope("orders:write") .WithOutbox() .WithRetry(maxAttempts: 3));Configuration
Section titled “Configuration”Engine:* key | Owned by | Purpose |
|---|---|---|
Engine:Id (required) | Cephalon.Engine | Unique identifier — emitted in every log, manifest, OTLP resource attribute. |
Engine:Deployment | Cephalon.Engine | Topology + deployment id + region. |
Engine:Composition | Cephalon.Engine | Model: "Modular" (currently only option). |
Engine:FeatureOrganization | Cephalon.Engine | ModuleFirst |
Engine:Data:IdStrategy | Cephalon.Ids.Sfid | "Sfid" (default), "Guid", "Long", "Custom" |
Dependencies
Section titled “Dependencies”Cephalon.Engine depends on Cephalon.AbstractionsCephalon.Behaviors depends on Cephalon.AbstractionsCephalon.Behaviors.Http depends on Cephalon.BehaviorsCephalon.Behaviors.Sourcegen → analyzer (build-time only)Cephalon.Ids.Sfid depends on Cephalon.Abstractions + Sfid.Net (external)See also
Section titled “See also”- Technology → Core — narrative description.
- Guide → Concepts — what these primitives mean.
- Reference → API — namespace tree.