Reputation: 25
Is it possible to send/upload a large file (cca 2GB) using Liferay and
UploadPortletRequest uploadRequest = PortalUtil.getUploadPortletRequest(request);
?
I understand that data transmission is limited by default to 104857600 B but I found out that by changing the limit to 0 the amount of sent data should be unlimited. Temporary storage directory should be used to avoid OutOfMemoryException or something like that (I guess..)
Screenshot of Control panel of Liferay with File Uploads Settings:Control Panel, Administration
Is it possible to send 2GB file using this technique? If so, please, could you tell me how, and what settings shall I use for the Limit and Temporary Storage Directory?
If this solution is not working what is the best way to do it using Liferay?
Upvotes: 2
Views: 2395
Reputation: 330
For the sake of completeness:
To increase the file size of your uploads add the following lines to your portal-ext.properties file (that is found in your bundle dir, in LR 7 if installed as bundle):
com.liferay.portal.upload.UploadServletRequestImpl.max.size=524288000
dl.file.max.size=0
Source:
https://web.liferay.com/de/community/forums/-/message_boards/message/6428002
Upvotes: 1