Skip to content

Commit b142ad8

Browse files
committed
missing sweeper line
1 parent 695ac28 commit b142ad8

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

  • samples/WebAPI/WebAPI_Dynamo/Greetings_Sweeper

samples/WebAPI/WebAPI_Dynamo/Greetings_Sweeper/Program.cs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
using Paramore.Brighter.Extensions.DependencyInjection;
77
using Paramore.Brighter.Observability;
88
using Paramore.Brighter.Outbox.DynamoDB;
9+
using Paramore.Brighter.Outbox.Hosting;
910
using TransportMaker;
1011

1112
JsonSerializerOptions jsonOptions = new() { PropertyNamingPolicy = JsonNamingPolicy.CamelCase, WriteIndented = true };
@@ -34,7 +35,15 @@
3435
configure.MaxOutStandingMessages = 5;
3536
configure.MaxOutStandingCheckInterval = TimeSpan.FromMilliseconds(500);
3637
configure.OutBoxBag = new Dictionary<string, object> { { "Topic", "GreetingMade" } };
37-
});
38+
})
39+
.UseOutboxSweeper(
40+
options =>
41+
{
42+
options.TimerInterval = 3;
43+
options.MinimumMessageAge = TimeSpan.FromSeconds(1);
44+
options.BatchSize = 10;
45+
options.UseBulk = false;
46+
});
3847

3948
WebApplication app = builder.Build();
4049

0 commit comments

Comments
 (0)