Java cup occupies high analysis scripts and javacup occupies scripts
[Was @ dmgr ita-scripts] $ vi java_analys.sh
PID = $1; ps-mp $ PID-o THREAD, tid, time | awk-F "" '{print $2 "" $8}' | grep-v CPU | grep-v "-" | sort-nr | head-1 | awk -F "" '{print $2}' | xargs pri
Ntf "% x \ n" | while read line; do TID = $ line; echo $ TID; jstack $ PID | grep $ TID-A 30; done
The CPU usage of java programs is extremely high. Why?
Since you said you had no problem before .. Now we have another problem. If the program is not modified. So you can't see the optimization of the Java Virtual Machine. If you have modified .. Then you can see that your resources are not released. Or, the read from your multi-threaded resources causes a deadlock ..
CPU usage of java programs is too high
There are too many times to connect to the database. The occupied connection is not closed and the connection is not released.