Pipelink.Outbox 1.0.12

There is a newer version of this package available.
See the version list below for details.
dotnet add package Pipelink.Outbox --version 1.0.12
                    
NuGet\Install-Package Pipelink.Outbox -Version 1.0.12
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Pipelink.Outbox" Version="1.0.12" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Pipelink.Outbox" Version="1.0.12" />
                    
Directory.Packages.props
<PackageReference Include="Pipelink.Outbox" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Pipelink.Outbox --version 1.0.12
                    
#r "nuget: Pipelink.Outbox, 1.0.12"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Pipelink.Outbox@1.0.12
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Pipelink.Outbox&version=1.0.12
                    
Install as a Cake Addin
#tool nuget:?package=Pipelink.Outbox&version=1.0.12
                    
Install as a Cake Tool

Pipelink.Outbox

A .NET library for implementing the outbox pattern with Entity Framework Core.

Overview

Pipelink.Outbox provides a simple and efficient way to implement the outbox pattern in your .NET applications using Entity Framework Core. The outbox pattern is a reliable way to handle message publishing in distributed systems, ensuring that messages are not lost even if the system fails.

Features

  • Easy integration with Entity Framework Core
  • Support for multiple message types
  • Automatic message publishing
  • Configurable retry policies
  • Transactional message handling

Installation

dotnet add package Pipelink.Outbox

Quick Start

  1. Configure your DbContext:
public class YourDbContext : DbContext
{
    public DbSet<OutboxMessage> OutboxMessages { get; set; }

    protected override void OnModelCreating(ModelBuilder modelBuilder)
    {
        modelBuilder.ApplyConfiguration(new OutboxMessageConfiguration());
    }
}
  1. Use the outbox in your services:
public class YourService
{
    private readonly YourDbContext _context;
    private readonly IOutboxPublisher _publisher;

    public YourService(YourDbContext context, IOutboxPublisher publisher)
    {
        _context = context;
        _publisher = publisher;
    }

    public async Task ProcessOrder(Order order)
    {
        using var transaction = await _context.Database.BeginTransactionAsync();
        
        // Save your business data
        _context.Orders.Add(order);
        await _context.SaveChangesAsync();

        // Add message to outbox
        var message = new OutboxMessage
        {
            MessageType = "OrderCreated",
            Payload = JsonSerializer.Serialize(order),
            CreatedAt = DateTime.UtcNow
        };
        _context.OutboxMessages.Add(message);
        await _context.SaveChangesAsync();

        await transaction.CommitAsync();
    }
}
  1. Configure the publisher in your startup:
services.AddOutboxPublisher(options =>
{
    options.RetryCount = 3;
    options.RetryInterval = TimeSpan.FromSeconds(5);
});

Configuration Options

  • RetryCount: Number of retry attempts for failed messages (default: 3)
  • RetryInterval: Time between retry attempts (default: 5 seconds)
  • BatchSize: Number of messages to process in a single batch (default: 100)

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Support

If you encounter any issues or have questions, please open an issue on GitHub.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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
1.0.20 156 4/22/2025
1.0.19 237 4/22/2025 1.0.19 is deprecated because it is no longer maintained.
1.0.18 235 4/22/2025 1.0.18 is deprecated because it is no longer maintained.
1.0.17 258 4/22/2025 1.0.17 is deprecated because it is no longer maintained.
1.0.16 245 4/22/2025 1.0.16 is deprecated because it is no longer maintained.
1.0.15 252 4/22/2025 1.0.15 is deprecated because it is no longer maintained.
1.0.14 269 4/22/2025 1.0.14 is deprecated because it is no longer maintained.
1.0.13 254 4/22/2025 1.0.13 is deprecated because it is no longer maintained.
1.0.12 255 4/22/2025 1.0.12 is deprecated because it is no longer maintained.
1.0.11 262 4/22/2025 1.0.11 is deprecated because it is no longer maintained.
1.0.10 257 4/22/2025 1.0.10 is deprecated because it is no longer maintained.
1.0.9 259 4/22/2025 1.0.9 is deprecated because it is no longer maintained.
1.0.7 262 4/22/2025 1.0.7 is deprecated because it is no longer maintained.
1.0.6 251 4/22/2025 1.0.6 is deprecated because it is no longer maintained.
1.0.5 266 4/22/2025 1.0.5 is deprecated because it is no longer maintained.
1.0.4 255 4/22/2025 1.0.4 is deprecated because it is no longer maintained.
1.0.3 254 4/22/2025 1.0.3 is deprecated because it is no longer maintained.
1.0.2 257 4/22/2025 1.0.2 is deprecated because it is no longer maintained.
1.0.1 257 4/22/2025 1.0.1 is deprecated because it is no longer maintained.
1.0.0 262 4/22/2025 1.0.0 is deprecated because it is no longer maintained.