Is there a file size limit for content in Coldfusion?

I recently worked with a tag cfcontent

to load some files by the browser. This piece of code works when my file size is around 900MB. However, with large sizes (currently my file size is 2.5 GB), the page loads, but there are no pop-ups for the user to download the files.

<cfheader name="Content-disposition" 
       value='attachment;   filename="Questionnaire_files.zip"'>
<cfcontent variable="#filereadbinary('#path#Questionnaire_files.zip')#" 
       type="application/x-zip-compressed">

      

So is there a file size limit cfcontent

?

+3


source to share


2 answers


Off the top of my head, I would say no, however you are doing FileReadBinary () which will read the file into memory and therefore have memory limits set in your JVM config. Have you tried just using



<cfheader name="Content-disposition" 
   value='attachment;   filename="Questionnaire_files.zip"'>
<cfcontent file="#path#Questionnaire_files.zip" 
   type="application/x-zip-compressed">

      

+3


source


Recording and uploading File size like 2.5GB may give you request timeout error or jvm outofmemmory error depends on your jvm setup. I would let the client choose where to store the file and write it in chunks there. By writing it in chunks, you save runtime memory. And the increase in productivity will



+1


source







All Articles