We are using Wildfly 10. Until now our application was working smoothly on this server. But from last few days, we are facing an issue where Wildfly 10 hangs unexpectedly. We checked our logs and found nothing suspicious (Not even OutOfMemory exception). We increased our heap size from 2 GB to 4 GB, but that didn't fix the problem, in fact, memory utilization was below the allowed limit. Our CPU utilization is high (more than 80%) and at some specific moment, it reaches to 200% also.
Our application stack is Java 8, Spring, Hibernate, MySql (DB). We are not sure how to diagnose this issue. What kind of logs or tools can help us to identify root cause so that We can fix it?
Assuming you're using Linux or another UNIXy OS, you can use "top" to identify the busy OS thread(s) and use the Java "jps" command to correlate that to a Java stack trace.