Reputation: 1009
I'm working with a java app that does simulations but after about 30 minutes the amount of simulations it can do per second halves.
The simulations are just numerical. The results are buffering, I'm using the Apache POI library to write to excel files, the output should be around 500k rows of 15 columns in excel, it gets written after all simulations are done.
The PC I'm running it on is fast and has good cooling so I don't think it's thermal throttling.
What could be the cause of the slowdown? (I'm not sure what info is important, if you need to know something just ask)
Upvotes: 4
Views: 2822
Reputation: 444
Based on the description of the situation, I would claim the JVM is suffering from limited resources (most likely memory) and is being bogged down by increasingly longer and increasingly more frequent GC pauses. You can verify whether or not my gut feeling is correct via logging the GC pauses by specifying the following startup parameters for the JVM:
-XX:+PrintGCTimeStamps -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:
Now, if the guess was correct, you can proceed by understanding what is actually causing these long pauses, is it a memory leak or just some unnecessarily big data structure in heap. For this I can recommend to take a Java monitoring tool called Plumbr out for a test drive to see the content inside the memory. Based on the exposed data you can see what to trim down inside memory.
Full disclosure, I am affiliated with Plumbr.
Upvotes: 2