Azure / Azure/azure-functions-host

Functions with QueueTrigger misconfigured make the host restart over and over

Open
#7,713 2 comments 0 reactions 0 assignees View on GitHub
Needs: Attention :wave:
Dominant language
C#
Stars
2k
Forks
482
Avg merge
2d 12h
Merged PRs (30d)
38

Description

If there is a QueueTrigger in an AzureFunction that does not work (eg Connection does just not exist), this will make the host restart. I think this is not a good behavior, as it results in the following user experience:

- Functions App restarts and restarts and restarts and restarts...
- Log Stream works on Windows only (at least for me). Therefore, diagnosing this can be very hard on Linux. Maybe it's possible to diagnose this with Azure tools, but I was not able to.
- App Insights does not retrieve the error
- Some requests work, but they are very slow even for trivial stuff and they only work if you are in luck and the host is not restarting already.

I propose to just ignore not-working queue triggers and log them to app insights (if configured) and to Log Stream.

If I recall correctly I had similar error behavior on other mis-config as well; maybe it's a general problem that error handling on startup is not very forgiving.

Of course it's more of an user error, but the UX is surely not optimal. And as it's Azure I think it should be awesome :)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing a QueueTrigger configured with a nonexistent connection and observe the host restart and available logs. Done means the misconfigured trigger no longer causes repeated host restarts and the failure is visible through the requested diagnostics, including Application Insights when configured and Log Stream.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp
Domain
backend, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.