I have a java process using jetty websockets. The process shows 151 live threads. The top result is showing 797MB of Resident memory.
Heap Memory used shows Committed as 231 MB
Non Heap Memory shows 115 MB.
There are total 1100 open file descriptors.
What I understand is every thread has a thread stack, say it is 1MB, then total memory used should be 151M + 231M + 115M + (file descriptors memory). Can someone tell me how all these lead to 797 MB of resident memory? What am I missing or not counting?