1

I have a blob triggered Azure function. I would like to define the retry policy (count and interval) for the function to be retried if it throws an exception. Is there a way I can do that ?

Arnavion
  • 3,627
  • 1
  • 24
  • 31
Tany
  • 1,252
  • 14
  • 30

1 Answers1

4

You can control the maximum number of retries via the maxDequeueCount setting in the "queues" config section of host.json (see here). The reason "queues" config affects blob functions is because behind the scenes a control queue is used for dispatching blobs to your functions. So the settings you configure for "queues" will affect the blob triggered functions as well. E.g. the default retry count is 5 - if a blob fails processing more than that, then it is moved to the poison queue.

You can control the time between retries via the visibilityTimeout setting.

Note that these settings are host wide and apply to all functions. You can't control these per function currently.

Andrew Williamson
  • 8,299
  • 3
  • 34
  • 62
mathewc
  • 13,312
  • 2
  • 45
  • 53
  • Thanks. Is there a way I can update the maxDequeueCount and visibilityTimeout during ARM template deployment of the function app (or through powershell) ? – Tany Jun 27 '17 at 17:46
  • These settings can only be set via host.json – mathewc Jun 27 '17 at 18:05