Add sending failure policies for outgoing message error handling#2179
Merged
jeremydmiller merged 6 commits intomainfrom Feb 15, 2026
Merged
Add sending failure policies for outgoing message error handling#2179jeremydmiller merged 6 commits intomainfrom
jeremydmiller merged 6 commits intomainfrom
Conversation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This reverts commit b799693.
Implement configurable failure handling policies for outgoing message send failures (Issue #1686). When a message fails to send to an external transport, users can now configure policies to discard, move to dead letter queue, retry with backoff, or take custom actions instead of relying solely on the existing retry/circuit-breaker behavior. Key additions: - SendingFailurePolicies class with IWithFailurePolicies support - SendingEnvelopeLifecycle adapter for IContinuation reuse - LatchSenderContinuation to pause sending agents - MessageTooLargeException for oversized message detection - Global policies via WolverineOptions.SendingFailure - Per-endpoint policies via ConfigureSending() fluent API - Envelope.SendAttempts for independent send attempt tracking Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
de799e8 to
4100986
Compare
PauseSending now takes a TimeSpan and automatically resumes the sender after the specified duration. Falls back to CircuitWatcher if resume fails. Adds SendingFailurePoliciesTests covering the full API. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ions DefaultMessageBatcher.Group() threw ArgumentNullException when TenantId was null because Dictionary does not allow null keys. The exception was silently swallowed by the Block error handler, completely breaking batch processing. Also fix two OTel tracing tests that asserted ConversationId instead of CorrelationId to match what WriteTags actually writes. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This was referenced Feb 17, 2026
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.
Summary
MessageTooLargeExceptionwith detection in Azure Service Bus sender for messages that can never fit in any batchUser-facing API
Key changes
SendingFailurePoliciesclass reusing existingIWithFailurePolicies/FailureRuleCollectioninfrastructureSendingEnvelopeLifecycleadapter enabling existingIContinuationimplementations to work on outgoing envelopesLatchSenderContinuationto pause sending agents (mirrorsPauseListenerContinuation)Envelope.SendAttemptsfor independent send attempt trackingSendingAgent,DurableSendingAgent,BufferedSendingAgent, andInlineSendingAgentEndpointCollectionresolves combined global + per-endpoint policies during agent constructionTest plan
🤖 Generated with Claude Code