All,
I'm using JDK 1.4.2_07 in Solaris UNIX. I've a multi-threaded application and I wanted to measure the CPU usage of every
thread from
Java. I wrote a Native C application that could return me the CPU usage of the thread given the process id and the thread id. But I'm not sure of how to get the current thread id so that it can be passed on to the native applcation. I'm able to get the current thread name (+ the current process id) and I'm not sure how to get the thread id using this information. It would be of great help, if somebody could help me in getting the thread id.
Thanks & Regards
- Siva