Postgres Distributed Lock
Package
Configuration
new PostgresLockingProvider(
new PostgresLockingProviderOptions(
connectionString: "Host=localhost;Database=orders;Username=app;Password=secret"));Setting
Type
Default
Description
Example
const string connectionString = "Host=localhost;Database=orders;Username=app;Password=secret";
services
.AddBrighter()
.AddProducers(opt =>
{
opt.Outbox = /* your Postgres Outbox */;
opt.ConnectionProvider = typeof(PostgreSqlConnectionProvider);
opt.TransactionProvider = typeof(PostgreSqlTransactionProvider);
opt.DistributedLock = new PostgresLockingProvider(
new PostgresLockingProviderOptions(connectionString));
})
.UseOutboxSweeper(opt => { opt.BatchSize = 10; });Provisioning
Notes
Further Reading
Last updated
Was this helpful?
