Freakout.MsSql
0.0.8
See the version list below for details.
dotnet add package Freakout.MsSql --version 0.0.8
NuGet\Install-Package Freakout.MsSql -Version 0.0.8
<PackageReference Include="Freakout.MsSql" Version="0.0.8" />
<PackageVersion Include="Freakout.MsSql" Version="0.0.8" />
<PackageReference Include="Freakout.MsSql" />
paket add Freakout.MsSql --version 0.0.8
#r "nuget: Freakout.MsSql, 0.0.8"
#:package Freakout.MsSql@0.0.8
#addin nuget:?package=Freakout.MsSql&version=0.0.8
#tool nuget:?package=Freakout.MsSql&version=0.0.8
Freakout
📤 Just a general outbox thing
Why? Because "outbox" is closer to your chosen type of persistence (SQL Server, Postgres, etc.) than to anything else.
Which types of persistence does it support?
- Microsoft SQL Server (for when you're working with
Microsoft.Data.SqlClientandSqlConnection)
and that's it for now. 😅
How?
First, enable Freakout in your app:
services.AddFreakout(new MsSqlFreakoutConfiguration(connectionString));
It will register a couple of things, e.g. a background worker that will poll the outbox for pending commands. AddFreakout can only be called once.
Then, add your handlers:
services.AddCommandHandler<RecalculateClaimSummaryCommandHandler>();
services.AddCommandHandler<SendEmailCommandHandler>();
services.AddCommandHandler<PublishRebusEventCommandHandler>();
which will of course be resolved from the container, each in their own service scope.
Now it's fully configured - what's missing is putting something in the outbox.
Since this example is for SQL Server, and we're pretending to be working with Microsoft.Data.SqlClient and SqlConnection, it's natural to
provide the outbox functionality as an extension method to DbTransaction. This way, your code can do stuff like this:
await using var connection = new SqlConnection(_connectionString);
await connection.OpenAsync();
await using var transaction = await connection.BeginTransactionAsync();
// do your own work with connection+transaction here
// (...)
// possibly call this bad boy a couple of times
await transaction.AddOutboxCommandAsync(new PublishRebusEventCommand(
Event: new JournalEntryAdded(Id: journalEntryId)
));
// do more of your own work
// (...)
// commit it all atomically
await transaction.CommitAsync();
which in this case would result in publishing a couple of JournalEntryAdded events using Rebus.
Btw. a command handler to do this could look like this:
public class PublishRebusEventCommandHandler(IBus bus) : ICommandHandler<PublishRebusEventCommand>
{
public Task HandleAsync(PublishRebusEventCommand command, CancellationToken token) => bus.Publish(command.Event);
}
and that would be it.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 is compatible. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETFramework 4.6.2
- Freakout (>= 0.0.8)
- microsoft.data.sqlclient (>= 5.2.0)
-
.NETStandard 2.0
- Freakout (>= 0.0.8)
- microsoft.data.sqlclient (>= 5.2.0)
-
net6.0
- Freakout (>= 0.0.8)
- microsoft.data.sqlclient (>= 5.2.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.0.33 | 96 | 1/26/2026 |
| 0.0.31 | 521 | 2/18/2025 |
| 0.0.30 | 551 | 8/12/2024 |
| 0.0.24 | 182 | 6/10/2024 |
| 0.0.23 | 160 | 6/10/2024 |
| 0.0.22 | 164 | 6/10/2024 |
| 0.0.21 | 217 | 4/16/2024 |
| 0.0.19 | 197 | 4/16/2024 |
| 0.0.18 | 192 | 4/15/2024 |
| 0.0.17 | 155 | 4/15/2024 |
| 0.0.16 | 170 | 4/15/2024 |
| 0.0.15 | 184 | 4/15/2024 |
| 0.0.14 | 168 | 4/15/2024 |
| 0.0.13 | 188 | 4/15/2024 |
| 0.0.12 | 166 | 4/15/2024 |
| 0.0.11 | 171 | 4/15/2024 |
| 0.0.10 | 170 | 4/15/2024 |
| 0.0.9 | 199 | 4/15/2024 |
| 0.0.8 | 171 | 4/15/2024 |