Azure trigger function for file share

Amey Pimpley 1 Reputation point
2020-11-06T07:13:52.667+00:00

Like we have blob trigger or event trigger for the blob created or deleted in Azure blob storage, I need to have a function which is triggered when a file is uploaded or created in file share.
Blob storage trigger, event grid trigger doesn't work on Azure file share. Can you please suggest on any custom trigger function or any other way to use the trigger functions on file share?

Azure Files
Azure Files
An Azure service that offers file shares in the cloud.
1,285 questions
Azure Event Grid
Azure Event Grid
An Azure event routing service designed for high availability, consistent performance, and dynamic scale.
379 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sumarigo-MSFT 46,126 Reputation points Microsoft Employee
    2020-11-06T09:05:24.763+00:00

    @Amey Pimpley This function isn't available yet. One option that is worth testing is to use the storage logging feature to send the logs to Event Hub and monitor when the file is closed.

    Example below is a file copy to a file share. Once the file copy completed, the file was closed.

    { "time": "2020-11-06 T20:28:02.9322274Z", "resourceId": "/subscriptions/SubID/resourceGroups/afs/providers/Microsoft.Storage/storageAccounts/SAName/fileServices/default", "category": "StorageWrite", "operationName": "Close", "operationVersion": "3.0", "schemaVersion": "1.0", "statusCode": 0, "durationMs": 5, "callerIpAddress": "IP Address", "correlationId": "35f******1d-00ce-001e-91****00", "identity": {"type":"NTLMv2"}, "location": "West US", "properties": {"accountName":"SAName","etag":"0x8d85f3601523d96","serviceType":"file","lastModifiedTime":"2020/11/06 20:28:02.7964822","serverLatencyMs":5,"operationCount":0,"requestHeaderSize":64,"requestBodySize":24,"responseHeaderSize":64,"responseBodySize":112,"smbSessionId":10151588549518950453,"smbTreeConnectID":5,"smbPersistentHandleID":153771048971,"smbVolatileHandleID":18446744069414584357,
    "smbCreditsConsumed":1,"smbMessageID":927,"smbCommandMajor":6,"smbCommandMinor":"FileClose","smbCommandDetail":"Detail=Client","smbFileId":9223503153616388096}, "uri": "\\SAName.file.core.windows.net\afs-westus\StorageSyncAgent_WS2016.msi", "protocol": "SMB", "resourceType": "Microsoft.Storage/storageAccounts/fileServices"}

    If you wish you may vote your feedback here All the feedback you share in these forums
    will be monitored and reviewed by the Microsoft engineering teams responsible for building Azure.

    Hope this helps!

    Kindly let us know if the above helps or you need further assistance on this issue.


    Please don’t forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.