Out of Memory : Java heap space

1
Hi Folks,   I have a requirement where I should upload a file with a size of up to 1.1 GB via a RestCall. The Mendix app runs on a Kubernets cluster and we have increased the memory to 2048mb. we think that this is enough because the Mendix app uses ~800mb.     after uploading I get the error and the Runtime crashs and starts again. java.lang.OutOfMemoryError: Java heap space   While I was googling for X-M2EE authentication for locale monitoring(Monitoring Mendix Runtime | Mendix Documentation) I found this link http://www.mxblog.eu/p/post/2533274790398005 This link describes how to get the X-M2EE authentication but there is also a performance task and there you could see that after the rest call with the file of a Size of 200mb the utilization increases to 1.5 GB. Before uploading it was on ~750mb   The question I ask myself is why it jumps to 1.5 GB and not 1 GB which would be ok in theory. It looks like the file is still 3x? used somewhere in memory.    What i did so far : Changed the Error Handling to "without Rollback" to avoid that the Objects are getting saved in the Memory Start Transaction and End Transaction Changed Loops where Objects are getting commited.   in the Microflow i have one Custom Java Action  which only returned 1 Value. im saying it, because i found some similar questions in the Forum and one of the Answers was that CustomJava Actions can impair the Runtime.   The Rest of the Microflow   As you can see, im retrieving the File from the Database which is for sure not optimal in this case but also necessary.    Does anyone have an idea what could be done better? :) Respectively, has anyone tried the solution from Jermaine? -> Mendix Community - Question Details   Best Regards, Thanks
asked
0 answers