I’m running a “split” operation through the Ruby RJB with the split_and_merge script you guys sent me. The goal is to split a powerpoint file into individual files.
It works fine with most of small files (less than 50 megabytes). I’ve just tried with a 140mb file of 127 slides, and the script processes about 12 slides, and then freezes. You can see the screenshot of the container running it here, at 97% CPU and 1.5G of memory (when before starting the script it was 0% CPU, 0.1G memory)
I’m in the very last steps of implementing Aspose, but I need to be able to process bigger files than this (up to 500Mb would be nice).
So my question is : do you have any idea why splitting a 120mb powerpoint file would required 1.5+Gb of RAM and freeze the CPU to 100% after 12 slides ?
Thanks
EDIT : I let the freeze go for a few more minutes and ended up with a Heap OOM Exception, meaning that aspose required more than 2Gb of ram to split a 130mb file… is this normal?! Screenshot 2020-09-28 at 16.05.50.png (361.5 KB)
You are performing a computationally very resource eating process in terms of both memory and processing. You are using big presentation decks and splitting and merging them. You need to set the increase Java heap size to 4GB or above to achieve better performance and avoiding such computational issue.
Well there is no trick for this as entire presentation gets loaded in memory. The source and target both presentation objects are extracted in DOM (Document Object Model). It is a resource eating process and varies from case to case depending on content of slide, number of slide and size of presentation etc.
I’m just trying to understand why memory pressure doesn’t go down after aspose has finished its work.
I’ve tried adding
pres.dispose()
presSplit.dispose()
At the end of the script to liberate any resources taken by the source and destination presentations but this is not helping. Looks like there’s a memory leak somewhere.
Please share the snapshot of memory consumption and not getting freed, sample project, source presentation, Java and Operating System details. I doubt there is any memory leak but in order to investigate further we need you to please provide the requested information.
I’m running the script on a Docker container (this image: Docker) with java-11-openjdk-amd64 installed. I had to use docker to make sure aspose would work on all systems, as I had issues between my Mac development setup and the live linux servers.
Here is a link with the script that has extensive logging lines about memory pressure, as well as a video that shows that running the same script several times just adds used memory to the container without ever coming back down.
I have created an issue with ID SLIDESJAVA-38319 in our issue tracking system based on the information shared by you. This thread has been linked with the issue so that you may be notified once the issue will be fixed.
Can you please also provide the source presentation that has been used so that we may investigate the issue further. Please also provide the Java and Operating System details on your end too along with details about environment.
Can you please provide one presentation for testing? Because the problem may be related to the content of this (these) presentation. Our team needs a presentation with which you have been able to reproduce the issue.
I have updated the information shared in our issue tracking system. We request for your patience and we will share feedback with you as soon as the issue will be fixed.