[Question] (C# compiled functions) Some functions when deployed to azure seem to need the webapp restarted before picking up changes
Hi, more a question as I haven't found anything obvious in the docs and I see this happen every now and then...
(This is a C# Compiled function app using the preview VS tooling. Being deployed by a VSTS deployment agent using the webapp package upload. Running on a Consumption Plan).
Sometimes, more noticeably when adding a new function, it may not be accessible after the deployment has finished. If I navigate to the functionApp on azure, I see the function in the list. When I click on the name I get an error that includes "The function type name 'XYZ' is invalid.", but still lists the json describing the function, etc.
If I restart the functionApp and go back to it - all good.
Q) Is there a delay between the deployment and the running function detecting that the files have actually changed?
Has anyone else seen this before?
Thanks,
I have seen this, but more noticeable when updating functions, so I make small changes to the logs to determine if the new code is running or not, and if not I restart the application.
@dtriana thanks for that - yes it seems to be on update only when it happens. The initial deploys are completely fine - as would be expected.
I find that this seems to occur far less using the stop Azure App Service Deploy from VSTS if the following is enabled;
Additional Deployment Options
- Publish using Web Deploy
- Remove additional files at destination
@TheeJamesLee Please update to the latest tooling NuGet https://www.nuget.org/packages/Microsoft.NET.Sdk.Functions. We previously published binaries to the site root, which is not in the watch directory list. Now, we publish to /bin, which is a watched folder.
Yesterday I had this issue once again using VSTS release pipeline on an existing function app. Is there any update on this issue or advise?
@sebastianzolg still an issue?
We are observing same issue.
Still an issue. Using latest Microsoft.NET.Sdk.Functions 1.0.27. Deploying via Azure DevOps Release pipeline, but latest binaries do not get picked up until a manual restart. I can clearly see that, because I have a step in my build pipeline that increments assembly versions of my binaries, and then I have a Function that returns it's Assembly.GetExecutingAssembly().GetName().Version. Tried to wait for ~10 minutes after a successful deployment.
@soninaren can you take a look?
Any news?
This has been an issue for us for a very long time too. We just make use of the Azure App Service Deploy task instead and ensure that we check the 'Take app offline' box. That has been the workaround that gets the job done every time and considering we are making heavy use of server-less architecture, we cannot afford a deployment only working 'sometimes'
Yet another month passed. Any news? I also wonder why it is marked as a question and not as a bug.
Yet another 3.5 months passed. No activity whatsoever.
I am seeing exactly this issue using Azure DevOps pipeline. It seems to occur only for V3 functions. Before we started to update from V2 -> V3 we did not see this issue.