Re: Cache or memory pools in java
- From: Piotr Kobzda <pikob@xxxxxxxxx>
- Date: Wed, 23 May 2007 19:48:51 +0200
I know this standard (JCache) but that implementation take 1 second per 1MB when evaluate how many size entries occupy in the memory :/
Hmm, maybe instrumentation could help?
Simple example on how to compute approximated object size is there:
(notice the correction from a post next to it)
Accuracy of that method is much better than with serialization, and efficiency is not so bad I think.
For example, on my machine ArrayList filled with 1000000 new Objects consumes about 14MB of memory, and computation of its size takes about 1.5 sec.
- Prev by Date: Re: Entertaining Java Programs
- Next by Date: Re: read and show CSV-files
- Previous by thread: Re: Cache or memory pools in java
- Next by thread: Re: Cache or memory pools in java