Rask.Data
0.20.0
See the version list below for details.
dotnet add package Rask.Data --version 0.20.0
NuGet\Install-Package Rask.Data -Version 0.20.0
<PackageReference Include="Rask.Data" Version="0.20.0" />
<PackageVersion Include="Rask.Data" Version="0.20.0" />
<PackageReference Include="Rask.Data" />
paket add Rask.Data --version 0.20.0
#r "nuget: Rask.Data, 0.20.0"
#:package Rask.Data@0.20.0
#addin nuget:?package=Rask.Data&version=0.20.0
#tool nuget:?package=Rask.Data&version=0.20.0
Rask.Data
A tiny, provider-agnostic data layer for Entity Framework Core apps — the DDD building blocks the
rask generate feature scaffolder emits, packaged for reuse.
Entity<TId>— a base entity withId, audit stamps (CreatedAt/UpdatedAt), and a domain-events buffer.- Opt-in markers — implement
ISoftDeletable(addsDeletedAt) orIVersioned(adds aVersionconcurrency token) on your entity to turn on the behavior. - Three
ISaveChangesInterceptors — auditing timestamps, transparent soft delete (aRemovebecomes aDeletedAtstamp behind a global query filter), and after-commit domain-event publication through Rask.Cqrs.
Use
public sealed class Product : Entity<Guid>, ISoftDeletable, IVersioned
{
public string Name { get; private set; } = "";
public DateTime? DeletedAt { get; private set; }
public int Version { get; private set; }
public static Product Create(string name) => new() { Id = Guid.NewGuid(), Name = name };
}
// Program.cs
builder.Services.AddRaskCqrs();
builder.Services.AddRaskData();
builder.Services.AddDbContextFactory<AppDbContext>((sp, o) => o
.UseSqlite("Data Source=app.db")
.AddInterceptors(sp.GetServices<ISaveChangesInterceptor>()));
// AppDbContext.OnModelCreating
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
modelBuilder.ApplyConfigurationsFromAssembly(typeof(AppDbContext).Assembly);
modelBuilder.ApplyRaskConventions();
}
db.Remove(product) now soft-deletes; deleted rows drop out of queries (use IgnoreQueryFilters() to
restore); a save against a stale Version throws DbUpdateConcurrencyException; and any
INotification raised on the entity is published after the change commits.
Part of the Rask framework. MIT licensed.
| 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.EntityFrameworkCore (>= 10.0.10)
- Rask.Cqrs (>= 0.20.0)
NuGet packages (3)
Showing the top 3 NuGet packages that depend on Rask.Data:
| Package | Downloads |
|---|---|
|
Rask.SQLite.EntityFrameworkCore
The Entity Framework Core integration for Rask.SQLite: `UseRaskSqlite(...)`, a drop-in replacement for `UseSqlite` that also registers a `ConnectionOpened` interceptor applying the production pragma set (WAL, `synchronous=NORMAL`, `foreign_keys=ON`, a `busy_timeout`, `mmap_size`, `journal_size_limit`) to every connection the context opens. Split out from Rask.SQLite so apps that only need the raw `Microsoft.Data.Sqlite` path (or run on mobile/AOT) don't pull in Entity Framework Core. |
|
|
Rask.Outbox
A transactional outbox for Rask.Data entities: domain events marked `IOutboxEvent` are written to an `OutboxMessage` table in the **same transaction** as the change that raised them (so an event is never lost and never fires for a rolled-back change), then a background `OutboxProcessor` polls the table and publishes them through Rask.Cqrs — at-least-once, crash-safe delivery, all on the app's own database (no broker, no Redis). A source generator registers each event type for reflection-free lookup. Server-side; pairs with Rask.Data. |
|
|
Rask
The one reference a Rask application needs, server or browser. On net10.0 it brings the ASP.NET host plus every battery — database, mediator, background jobs, transactional email, cache, outbox, operator dashboard, durable logs, Web Push, and SQLite snapshots and continuous backup — with RaskApp.Create(args) as the entry point. On net10.0-browser it brings the WebAssembly host, the source-generated mediator, the query cache and remote dispatch. Everything referenced is wired and on; app.Configure(c => c.Jobs.Off()) is how an app does without one. Reference Rask.Server for a lean host with no database. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.20.1-alpha.0.228 | 36 | 9/4/2026 |
| 0.20.1-alpha.0.227 | 34 | 9/4/2026 |
| 0.20.1-alpha.0.226 | 35 | 9/4/2026 |
| 0.20.1-alpha.0.225 | 40 | 9/4/2026 |
| 0.20.1-alpha.0.224 | 47 | 9/4/2026 |
| 0.20.1-alpha.0.223 | 40 | 9/4/2026 |
| 0.20.1-alpha.0.221 | 39 | 9/4/2026 |
| 0.20.1-alpha.0.220 | 43 | 9/4/2026 |
| 0.20.1-alpha.0.217 | 33 | 9/4/2026 |
| 0.20.1-alpha.0.216 | 40 | 9/4/2026 |
| 0.20.1-alpha.0.215 | 43 | 9/3/2026 |
| 0.20.1-alpha.0.213 | 38 | 9/3/2026 |
| 0.20.1-alpha.0.212 | 47 | 9/3/2026 |
| 0.20.1-alpha.0.211 | 46 | 9/3/2026 |
| 0.20.1-alpha.0.210 | 49 | 9/3/2026 |
| 0.20.1-alpha.0.209 | 42 | 9/2/2026 |
| 0.20.1-alpha.0.208 | 47 | 9/2/2026 |
| 0.20.1-alpha.0.207 | 50 | 9/2/2026 |
| 0.20.1-alpha.0.206 | 48 | 9/2/2026 |
| 0.20.0 | 127 | 8/6/2026 |