问题
Whenever I update my application settings for a Function app and hit the Save button on Azure Portal, I observe that this action temporarily stops my function app while the changes are being persisted to the active worker(s). I need to understand if this is indeed the case or if I'm making a false assumption.
What happens exactly when app settings are updated in the portal?
- 503 is thrown while active worker(s) are being updated
OR
- Another worker is specialized with the new host file. The old worker(s) stop once this one becomes active.
I keep getting 503 Service Unavailable errors. Is there any way to avoid this in production? I need to periodically rotate connection strings/keys, but I can't afford to disrupt the service constantly.
回答1:
If you update the app settings, the app will be restarted. That's why you got 503 error.
Usually in the production environment, we will not change the app settings frequently.
Anyway, to avoid such situation, you can use the slot feature
来源:https://stackoverflow.com/questions/61944403/does-azure-functions-throw-503-errors-while-app-settings-are-being-updated