CloudQueue.DeleteMessageAsync(CloudQueueMessage) for message that became visible
See original GitHub issueScenario 1
- msg1 (
CloudQueueMessage
) is received with visibility timeout set to 30 seconds. - processing is taking much longer than 30 seconds
- while processing of msg1 is happening, msg1 becomes visible on the queue
- another competing consumer received the message as msg2
- msg1 is attempted to be deleted using
CloudQueue.DeleteMessageAsync(msg1)
. 💥
Exception is thrown The remote server returned an error: (404) Not Found.
Scenario 2
- msg1 (
CloudQueueMessage
) is received with visibility timeout set to 30 seconds. - processing takes 40 seconds
- msg1 is kept around and later deleted using
CloudQueue.DeleteMessageAsync(msg1)
.
Message is deleted.
The question
Should the second scenario throw an exception? In the world of the competing consumers it sounds wrong that one can delete a message with an expired PopReceipt
.
Side note: This is also very inconsistent with ASB, where once message lock is expired, no operations can happen on the message.
Issue Analytics
- State:
- Created 7 years ago
- Comments:14 (6 by maintainers)
Top Results From Across the Web
Azure Queue throwing Exception on DeleteMessage
I'm working on an Azure based project for some research and have been running into some issues when deleting messages from a CloudQueue...
Read more >CloudQueue Class (Microsoft.Azure.Storage.Queue)
Begins an asynchronous operation to get a single message from the queue, and specifies how long the message should be reserved before it...
Read more >CloudQueue.DeleteMessageAsync, Microsoft. ...
Queue CloudQueue. ... DeleteMessageAsync extracted from open source projects. ... De-queue the next message"); CloudQueueMessage message = await queue.
Read more >Azure Queue - Services Bus and Storage Bus
See how to create queue in azure portal, add message in it, queue and dequeue ... any messages that have not been deleted...
Read more >com.microsoft.azure.storage.queue.CloudQueueMessage ...
Sets the content of the message as a byte array. setNextVisibleTime. Sets the time for the message to become visible in the queue....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Raised UserVoice issue here
Please vote there as @mirobers has indicated. This is a storage queue server-side service issue.
Please do use the feedback link above to register this request so others can vote on it as well. I’m closing the issue here as it doesn’t relate to the client; we can track the request in the feedback forum instead. Thanks for your input!