none
Azure Function Output Blob binding - size limit [Linux, Python] RRS feed

  • Question

  • Hi,

    I have an issue regarding the size of the data passed to an Output Blob Binding in Azure Functions (Linux, Python). I can write a file up to approximately 125MB  of size in under a minute, but when trying to write a file that's around 150MB or more, the Function itself runs OK, I'm able to set the data to the binding, but then nothing more happens and after 30 minutes I get a timeout. I would have been expecting an error message or something, if there really is a limitation, but all I get is the timeout.

    I wasn't able to output a stream (StringIO, BytesIO) to the blob.

    Is there any workaround for this or am I really limited by size?

    Thanks in advance.

    Thursday, September 19, 2019 2:32 PM

All replies

  • Hi

    For me, this looks like a limitation of the Azure Functions Run time. Could you confirm the Service Plan of your Azure Functions.

    Hope the below chart helps to understand under which category your Functions service fall under.

    Plan Runtime Version Default Maximum
    Consumption 1.x 5 10
    Consumption 2.x 5 10
    App Service 1.x Unlimited Unlimited
    App Service 2.x 30 Unlimited

    Ref Link - https://docs.microsoft.com/en-us/azure/azure-functions/functions-scale#timeout

    Hope this is helpful !!

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Thursday, September 19, 2019 2:37 PM
  • Hi,

    I forgot to mention, I'm actually on a Premium Plan.

    Also, it doesn't make sense to me that I would be able to write 120MB really quickly and then suddenly 150MB would time out after 30 minutes. It feels like the write itself just hangs and the function gets suspended after timeout.

    I'm going to try to write the same function in C#, to see if binding a Stream to the output would work.

    Friday, September 20, 2019 7:38 AM
  • Sure, Please post how that try goes!!

    Thank you


    If this post helps to resolve your issue, please click the "Mark as Answer" of that post and/or click Answered "Vote as helpful" button of that post. By marking a post as Answered and/or Helpful, you help others find the answer faster.

    Friday, September 20, 2019 9:20 AM
  • Hi Naveen,

    the problem persists even in C#.

    I've also tried just using the tutorial example of BlobTrigger, which basically triggers when you upload a new blob to a container or location specified in the input binding, takes the aforementioned blob and copies it to another location. On a 12MB file, it works flawlessly. When I tried a 700MB file, it times out

    The only difference I've noticed between Python and C# is that C# creates an empty file but then nothing happens, while Python doesn't even create the empty file (my suspicion is that this is caused by C# manipulating the outputs as streams, while Python tries to do all of it in one go).

    BTW I've tried running it locally as well as in the cloud

    • Edited by Jakub Smetana Monday, September 23, 2019 8:50 AM clarification
    Monday, September 23, 2019 8:41 AM