Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DelayedDelivery Poller doesn't handle messages going over the size limit gracefully #993

Open
danielmarbach opened this issue Mar 27, 2023 · 0 comments

Comments

@danielmarbach
Copy link
Contributor

Describe the suggested improvement

Is your improvement related to a problem? Please describe.

For messages close to the maximum size it is possible that the delayed message poller cannot send a message to the destination queue. When that happens it tries to add a failed Q header which makes the attempt also fail.

Messages cannot be larger than 65536 bytes.
Failed at dispatching the delayed message with PartitionKey:'2023030208' RowKey: '20230302082154_5989ca79686f48c593f8bf34a7ec4126' message ID: '094bc4f2-152e-4e0c-a983-afb9006dd811'

Stack Trace
at Microsoft.WindowsAzure.Storage.Queue.CloudQueueMessage.GetMessageContentForTransfer(Boolean shouldEncodeMessage, QueueRequestOptions options)
at Microsoft.WindowsAzure.Storage.Queue.CloudQueue.AddMessageImpl(CloudQueueMessage message, Nullable`1 timeToLive, Nullable`1 initialVisibilityDelay, QueueRequestOptions options)
at Microsoft.WindowsAzure.Storage.Queue.CloudQueue.AddMessageAsync(CloudQueueMessage message, Nullable`1 timeToLive, Nullable`1 initialVisibilityDelay, QueueRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
at Microsoft.WindowsAzure.Storage.Queue.CloudQueue.AddMessageAsync(CloudQueueMessage message, Nullable`1 timeToLive, Nullable`1 initialVisibilityDelay, QueueRequestOptions options, OperationContext operationContext)
at NServiceBus.Transport.AzureStorageQueues.Dispatcher.Send(MessageWrapper wrapper, CloudQueue sendQueue, TimeSpan timeToBeReceived)
at NServiceBus.Transport.AzureStorageQueues.Dispatcher.Send(UnicastTransportOperation operation, CancellationToken cancellationToken)
at NServiceBus.Transport.AzureStorageQueues.DelayedMessagesPoller.SafeDispatch(DelayedMessageEntity delayedMessage, CancellationToken cancellationToken)
at NServiceBus.Transport.AzureStorageQueues.DelayedMessagesPoller.SpinOnce(CancellationToken cancellationToken)

the poller doesn't handle such a situation gracefully nor does it trigger critical error actions. For example the recoverability code would trigger the critical error in such a situation.

Describe the suggested solution

Describe alternatives you've considered

Additional Context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant