Reputation: 7459
With the 1.6 SDK (Version 2011-08-18) you can change the invisibility timeout of a queue message. However, reading the REST documentation, it would seem to show that you have to post back the message. I understand that the operation is meant to update the entire message (including invisibility timeout), but I only want to change the invisibility timeout without having to resend the entire message. Is this possible?
Thanks, Erick
Upvotes: 4
Views: 5655
Reputation: 816
Update the Queue Message with Flag Settings MessageUpdateFields.Visibility regardless of the value of Message contents. e.g.
message.SetMessageContent("");
queue.UpdateMessage(message, visibilityTimeout, MessageUpdateFields.Visibility);
this will not change the message contents to Empty string and contents will remain intact and would update the Visibility timeout only.
To update the contents as well as visibility timeout,
queue.UpdateMessage(message, visibilityTimeout, MessageUpdateFields.Content | MessageUpdateFields.Visibility);
Upvotes: 16
Reputation: 2233
Update message has capabilities of updating the timeout. More details can be found here http://msdn.microsoft.com/en-us/library/windowsazure/hh452234.aspx
Upvotes: -1