We are building an App function that requires access to the file system. I have read elsewhere that the storage is not dedicated to a particular app and is shared. Is there any way that the app would be shifted to a new storage location while running?
[! IMPORTANT] When using the Consumption/Premium hosting plan, your function code and binding configuration files are stored in Azure Files in the main storage account.
Azure Files offers fully managed file shares in the cloud that are accessible via the industry standard Server Message Block (SMB) protocol, Network File System (NFS) protocol, and Azure Files REST API. Azure file shares can be mounted concurrently by cloud or on-premises deployments.
When creating a function app, you must create or link to a general-purpose Azure Storage account that supports Blob, Queue, and Table storage. This requirement exists because Functions relies on Azure Storage for operations such as managing triggers and logging function executions.
Azure Functions is a serverless solution that allows you to write less code, maintain less infrastructure, and save on costs. Instead of worrying about deploying and maintaining servers, the cloud infrastructure provides all the up-to-date resources needed to keep your applications running.
Your Azure Function application has multiple file-system storage locations.
d:\local points to a non-shared local-to-the-VM storage. It is temporary, as in when your function is deprovisioned from the VM, the storage goes away. You have 500MB to store here. So if we have scaled your function app to 5 instances, each of the five instances will run on its own VM and each will have its own d:\local storage of 500MB.
d:\home points to a shared storage folder which all your function application instances have access to. As your function apps get scaled out or moved, the folder remains the same. Of course implied by this is that for scale-reasons you may not want to have performance critical paths use it.
And of course you can access storage APIs yourself in your function.
Hope that helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With