Reputation: 141
I would like to ask if anyone knows a JAVA Caching Framework with the following properties:
I have big data files (2mb up to 5gb), which i need to serialize if the memory increases and deserialize them on demand.
Last recently used strategy
I want to handle serialization/deserializtion on my own, this means i just want to know from the framework when I have to serialize. Deserializing is on user demand.
I want to have minimum IO as I have big data
If there is no direct framework for this, maybe you can point me to a heuristik or any other strategy? SoftReferences/WeakReference as a solution do not work, as i can't serialize, even if I get noticed when they are garbage collected (to less memory left for serializing or even worse: file gone before serialization).
Thanks!
Upvotes: 1
Views: 5377
Reputation: 1236
The JCache API is in public draft (as of August 2013), and will come with an open source reference implementation (RI). All of the major caching vendors (e.g. Oracle Coherence, ehCache) and open source projects will provide a JCache binding for their implementations, so it's worth taking a look.
See: https://github.com/jsr107
Update (11 July 2014) - The JCache API is completed and released several months ago as a standard.
If you need an implementation of JCache, the only one that I'm aware of being available today is Oracle Coherence; see: http://docs.oracle.com/middleware/1213/coherence/develop-applications/jcache_part.htm
For the sake of full disclosure, I work at Oracle. The opinions and views expressed in this post are my own, and do not necessarily reflect the opinions or views of my employer.
Upvotes: 1
Reputation: 28665
Check on the Redis - Redis is an open source, BSD licensed, advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets. For more details click on Redis
Upvotes: 0
Reputation: 9568
(disclaimer - I work for GigaSpaces)
GigaSpaces XAP DataGrid provides a full object oriented Java caching solution.
Upvotes: 4
Reputation: 5665
Try Ehcache . Ehcache is an open source, standards-based cache used to boost performance, offload the database and simplify scalability. Ehcache is robust, proven and full-featured and this has made it the most widely-used Java-based cache
Upvotes: 4