How to fix an error `Java heap space` when downloading large files (GB) using Liferay

后端 未结 3 959
死守一世寂寞
死守一世寂寞 2021-01-26 16:03

I am using this code to download an existing file from the server on Liferay (6.2) into a local pc:

`

    File file = getFile(diskImage.getImageType(), d         


        
3条回答
  •  渐次进展
    2021-01-26 16:34

    Thanks for thoughts, finally I used PortletResponseUtil.sendFile(...); method and changed actionURL to responseURL in .jsp file. So that I implemented serveResource()with above mentioned method. It seems that everything is working fine.

提交回复
热议问题