Azure function is triggered before the upload finished through SFTP

Anonymous
2022-09-30T08:32:10.743+00:00

Once a file is uploaded by Azure storage accounts through SFTP the Azure function is triggered immediately (before the upload operation finished) and the blobstream is not transferred as expected. Hence, we get error in the code since we do not have proper file data. After the upload operation finished, the function triggered again and works as expected. We expect the function should be triggered right after the upload finished. What is the problem here and what should we do? We are happy to hear your suggestions.

Thanks.

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
4,262 questions
Azure Storage Accounts
Azure Storage Accounts
Globally unique resources that provide access to data management services and serve as the parent namespace for the services.
2,687 questions
{count} vote

1 answer

Sort by: Most helpful
  1. MughundhanRaveendran-MSFT 12,421 Reputation points
    2022-10-04T04:55:23.133+00:00

    Hi @Anonymous ,

    Thanks for reaching out to Q&A forum.

    I would suggest you look into the storage diagnostic logs to see if the blob receipts are received properly.

    For more reliable processing of blobs, please refer to this article: https://learn.microsoft.com/en-us/azure/azure-functions/functions-bindings-storage-blob-trigger?tabs=in-process%2Cextensionv5&pivots=programming-language-csharp#polling-and-latency

    Hope this helps! Feel free to reach out to me if you have any questions or concerns.