For every method that you call in your thread, it’s like an additional layer that gets added to your thread’s stack. If the total space occupied by these layers exceeds the memory stipulated to that particular thread’s stack, a StackOverFlowError occours !!!!
Regards,
SPS
Tagged in
S
spstech
Java developer and blogger. Passionate about clean code, JVM internals, and sharing knowledge with the community.