You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Investigation of FileAggregate-6dca2ab10bce4994c7d508206b0bedfe found that all source FileLineAddedEvent events exist, but line 7 has no terminal processing event.
Observed stream sequence:
Lines 1, 9: FileLineProcessingIgnoredEvent
Lines 2–5 and 8: FileLineProcessingSuccessfulEvent
Line 6: FileLineTransactionDispatchFailedEvent only
Line 7: no processing result event
No FileProcessingCompletedEvent
Suggested code changes:
Propagate failed handler results from DomainEventHandlers.HandleDomainEvent. It currently awaits Task.WhenAll(tasks) but ignores the returned Result values and always returns HTTP 200. Failed processing should return a non-success response so EventStore retries the event.
Prevent concurrent writes to the same FileAggregate. The subscription currently uses IsOrdered: false and InflightMessages: 100, allowing several lines from one aggregate to load/save concurrently. The short-term mitigation is ordered/single-inflight processing; the better long-term solution is aggregate/stream-keyed serialization.
Ensure aggregate save/version conflicts remain retryable. ApplyFileUpdates converts exceptions and save failures into failed Result values, but those failures must reach the HTTP layer as non-success responses.
Add tests for failed-result HTTP propagation, aggregate concurrency/save conflicts, idempotent redelivery, and retrying dispatch failures.
Add recovery/monitoring for aggregates with lines still marked NotProcessed, since already-acknowledged events will not be retried automatically.
The exact line-7 exception cannot be identified because the logs are no longer available, but the stream confirms that the input event exists and its processing result was never persisted.
Activity
StuartFerguson commentedon Sep 25, 2026
Investigation of
FileAggregate-6dca2ab10bce4994c7d508206b0bedfefound that all sourceFileLineAddedEventevents exist, but line 7 has no terminal processing event.Observed stream sequence:
FileLineProcessingIgnoredEventFileLineProcessingSuccessfulEventFileLineTransactionDispatchFailedEventonlyFileProcessingCompletedEventSuggested code changes:
DomainEventHandlers.HandleDomainEvent. It currently awaitsTask.WhenAll(tasks)but ignores the returnedResultvalues and always returns HTTP 200. Failed processing should return a non-success response so EventStore retries the event.Prevent concurrent writes to the same
FileAggregate. The subscription currently usesIsOrdered: falseandInflightMessages: 100, allowing several lines from one aggregate to load/save concurrently. The short-term mitigation is ordered/single-inflight processing; the better long-term solution is aggregate/stream-keyed serialization.Ensure aggregate save/version conflicts remain retryable.
ApplyFileUpdatesconverts exceptions and save failures into failedResultvalues, but those failures must reach the HTTP layer as non-success responses.Add tests for failed-result HTTP propagation, aggregate concurrency/save conflicts, idempotent redelivery, and retrying dispatch failures.
Add recovery/monitoring for aggregates with lines still marked
NotProcessed, since already-acknowledged events will not be retried automatically.The exact line-7 exception cannot be identified because the logs are no longer available, but the stream confirms that the input event exists and its processing result was never persisted.