Conversation
5 tasks
Copilot
AI
changed the title
[WIP] Register IEventOutbox as PostgreSqlEventOutbox in AddPostgreSqlOutbox
feat: Register IEventOutbox as PostgreSqlEventOutbox in AddPostgreSqlOutbox()
Apr 13, 2026
7f926e0 to
be431d5
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #370 +/- ##
==========================================
+ Coverage 84.94% 90.28% +5.33%
==========================================
Files 106 107 +1
Lines 3867 3983 +116
Branches 353 365 +12
==========================================
+ Hits 3285 3596 +311
+ Misses 496 284 -212
- Partials 86 103 +17 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
|
@copilot Also add Integration tests similar to |
Contributor
Author
Added |
Contributor
|
@copilot Fix pipeline errors |
…Outbox() Agent-Logs-Url: https://github.com/dailydevops/pulse/sessions/2782dea3-d906-411e-ab45-2090a9306010 Co-authored-by: samtrion <3283596+samtrion@users.noreply.github.com>
Agent-Logs-Url: https://github.com/dailydevops/pulse/sessions/e370179f-436a-48f1-beeb-7fd9fe7d33ee Co-authored-by: samtrion <3283596+samtrion@users.noreply.github.com>
Agent-Logs-Url: https://github.com/dailydevops/pulse/sessions/e370179f-436a-48f1-beeb-7fd9fe7d33ee Co-authored-by: samtrion <3283596+samtrion@users.noreply.github.com>
e42fa2a to
c8c9814
Compare
Agent-Logs-Url: https://github.com/dailydevops/pulse/sessions/2ae647b9-9902-4001-8aac-4a08c31c9b25 Co-authored-by: samtrion <3283596+samtrion@users.noreply.github.com>
c8c9814 to
02508b6
Compare
- Add GetPendingCountAsync and batch update methods to PostgreSqlOutboxRepository for efficient message handling. - Update SQL functions to accept explicit timestamps and improve retry logic. - Limit connection pool size and eagerly clear pools in test fixtures to prevent exhausting PostgreSQL connections during parallel tests. - Raise max_connections in test container to support high parallelism. - Update verified test output to match new message handling logic.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AddPostgreSqlOutbox()was not registeringIEventOutbox, causing apps to fall back to the defaultOutboxEventStorewhich opens a separate Npgsql connection instead of sharing the caller's transaction. This mirrors the existing SQL Server pattern.Changes
New:
PostgreSqlEventOutboxpublic sealed classimplementingIEventOutboxdirectly via ADO.NETIOptions<OutboxOptions>,TimeProvider, and optionalIOutboxTransactionScopeNpgsqlTransactionfromIOutboxTransactionScopewhen present; opens its own connection otherwiseUpdated:
RegisterPostgreSqlOutboxServicesAddOutbox()then overridesIEventOutbox → PostgreSqlEventOutbox,IOutboxRepository → PostgreSqlOutboxRepository, andIOutboxManagement → PostgreSqlOutboxManagement(same pattern as SQL Server)New:
AddPostgreSqlOutboxTransactionScope<TUnitOfWork>()IOutboxTransactionScope(Scoped), mirroringAddSqlServerOutboxTransactionScope<TUnitOfWork>()Tests
PostgreSqlEventOutboxTests: constructor validation, transaction scope path,StoreAsyncargument guardsPostgreSqlExtensionsTests:IEventOutboxregistration type assertions +AddPostgreSqlOutboxTransactionScopecoveragePostgreSqlAdoNetInitializer: database initializer that loads and executes the PostgreSQL OutboxMessage.sql scriptPostgreSqlAdoNetOutboxTests: integration test class that inherits fromOutboxTestsBaseand tests the ADO.NET implementation against a real PostgreSQL container via Testcontainers