JDK-4242721 : Wanted: java.util.Cache class
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.util
  • Affected Version: 1.2.0
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • OS: generic
  • CPU: generic
  • Submitted: 1999-05-31
  • Updated: 2018-04-21
Related Reports
Relates :  
Description

Name: krT82822			Date: 05/31/99


I would like a standard class that implements the Map interface
and refers to its values only through SoftReferences. Such a beast
would provide a simple memory-sensitive cache which could be very
useful in a variety of applications. Also, note how this class 
would naturally complement the existing WeakHashMap class (which
stores its keys using WeakReferences and its values using strong
references).
(Review ID: 83692) 
======================================================================

Comments
Looks like this RFE is abandoned?
21-04-2018

What is the progress of the current enhancement? I have a request to rid of the sun.misc.SoftCache class: JDK-8154539 Examine the desktop module's use of sun.misc.SoftCache Will it be possible to change the unsupported SoftCache class to new API in JDK 9?
27-04-2016

JSR 107: JCACHE - Java Temporary Caching API https://jcp.org/en/jsr/detail?id=107
05-03-2014

There are external solutions which cannot be used from internal classes: commons.apache.org/collections//apidocs/org/apache/commons/collections/map/ReferenceMap.html google-collections.googlecode.com/svn/trunk/javadoc/com/google/common/collect/MapMaker.html
05-06-2013

WORK AROUND Name: krT82822 Date: 05/31/99 Implement your own cache. This requires some technical know-how related to how Reference objects interact with the garbage collector. ======================================================================
11-06-2004