Safely receive top peeked message if it is not locked
If you call the Peek() method and identify that the top message is a message that you wish to receive, and then you subsequently call receive, receive will return whatever message is determined to be the next "available" message (the top one that doesn't already have a lease lock), which may not be the message that appeared at the top of the the peek results. It would be nice to have a way to receive the specific message that was previously seen at the top of the peek results. This could be done with a receive method that accepts a message id or message sequence number, and that method would either give me that specific message if it is "available" (it is on top and not locked), or an exception if it is not. Perhaps this method would also accept an amount of time that the caller is willing to block waiting for the specified message to become available.
This feature would mostly be useful in support scenarios where processing of a queue is blocked on a message, and support personnel wish to administratively deal with the message.
Because I know questions will arise: yes, we have an intentional strategy in place for exponential backoff/retry of messages and auto-deadlettering. The feature I am asking for is for a small handful of real-world cases where this blanket stratety isn't perfect. I have also discussed other solutions to this problem with the product team, and all suggestions have been non-trivial for the scale at which we use (and will grow our use of) service bus.
