java - ThreadLocal and Memory usage -


threadlocal created have separate copy of objects operate on in threadsafe manner.

this means number of objects in process increase number of threads. because, each thread create own copy of threadlocals.

  • does not increase memory requirement of process ?

you seem imply threadlocals specific culprit increases memory usage, in fact question not particularly related threadlocals per se. in situation describe, merely object have been allocated @ point , go unreacheable when thread dies @ latest.


Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -