Reputation: 255
I have an azure function, which is binded to blob storage. Once the blob is successfully processed I rename the file with a suffix '-Processed'.
But my azure function again picks up the same blob for processing. I tried putting {name}.csv filter in the BlobTrigger binding but that didn't help as the file will still be a csv even after the rename.
I know I can filter blobs to have a particular string in file name, for eg "original-{name}" will filter files starting with original. But Is there a way in azure functions using which I can filter the blob names to not include a particular string, in my case '-Processed'?
Upvotes: 1
Views: 760
Reputation: 1446
"path": "input/notprocessed-{name}"
Upvotes: 4
Reputation: 20127
Actually, blob service only supports filtering by blob prefix and not by suffix. Your only option would be to list blobs and then do client side filtering.
Also, the list blobs operation has an additional delimiter
parameter that enables the caller to traverse the blob namespace by using a user-configured delimiter.
You could refer to this article for more details.
Upvotes: 0