コード例 #1
0
 private Task ProcessFailedMessage(IQueueMessage message)
 {
     try
     {
         if (message.DequeueCount >= MaxDequeueCount)
         {
             return(MoveToPoisonQueue(message, null));
         }
         else
         {
             return(_queueReader.ReleaseMessageAsync(message));
         }
     }
     catch (Exception ex)
     {
         return(LogError("QueueTriggerBinding", "ProcessFailedMessage", ex));
     }
 }
コード例 #2
0
 private async Task ProcessFailedMessage(IQueueMessage message)
 {
     if (message == null)
     {
         return;
     }
     try
     {
         if (message.DequeueCount >= _maxDequeueCount)
         {
             await MoveToPoisonQueue(message, null);
         }
         else
         {
             await _queueReader.ReleaseMessageAsync(message);
         }
     }
     catch (Exception ex)
     {
         await LogError("QueueTriggerBinding", "ProcessFailedMessage", ex);
     }
 }