Closed zamzowd closed 2 years ago
This seems to be the same issue as reported here: https://github.com/Azure/azure-webjobs-sdk/issues/2152 (it has been an issue for more than 2 years now)
it's already fixed in latest SB extension https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.ServiceBus/5.3.0
Even though I have autocomplete disabled and I deadlettered the message in the function, if I then throw an exception, then in addition to the logged exception I also I get a
MessageLockLostException
logged fromMessageReceivePump.AbandonMessageIfNeeded
attempting to abandon the message I already deadlettered.So far as I know, throwing an exception is the only way that the function execution is logged as unsuccessful.
If I'm not mistaken, I think the SessionMessageProcessor on the single dispatch should check for
AutoComplete
before rethrowing similar to ServiceBusListener on the batch processing.