db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig L Russell <Craig.Russ...@Sun.COM>
Subject Negative VOTE Issue 102: Pin clarifications
Date Mon, 13 Feb 2006 17:13:03 GMT
Javadogs,

Here are the proposed updates to the pin specification 11.8.

Please reply if you have objections.

<proposed>
Evicting objects from the cache
	void evict(Object oid);
	void evictAll();
	void evictAll(Object[] oids);
	void evictAll(Collection oids);
	void evictAll(Class pcClass, boolean subclasses);
The evict methods are hints to the implementation that the instances  
referred to by the object ids are stale and should be evicted from  
the cache. Evicting an instance does not unpin it.
Pinning objects in the cache
	void pin(Object oid);
	void pinAll(Collection oids);
	void pinAll(Object[] oids);
	void pinAll(Class pcClass, boolean subclasses);
The pin methods are hints to the implementation that the instances  
referred to by the object ids should be pinned in the cache (not  
subject to algorithm-based eviction, but subject to explicit  
eviction). There is no requirement that an instance be in the cache  
in order to pin or unpin it. The pinAll method with the Class  
parameter automatically pins all instances of that class, including  
those instances already in the cache and future instances of the  
class. When a class is pinned, pin and unpin methods on instances of  
the pinned class are ignored.
Unpinning objects in the cache
	void unpin(Object oid);
	void unpinAll(Collection oids);
	void unpinAll(Object[] oids);
	void unpinAll(Class pcClass, boolean subclasses);
The unpin methods are hints to the implementation that the instances  
referred to by the object ids should be unpinned (subject to eviction  
based on algorithm). There is no requirement that an instance be in  
the cache in order to pin or unpin it. The unpinAll method with the  
Class parameter automatically unpins all instances of that class,  
including those instances already in the cache and future instances  
of the class. When a class is pinned, pin and unpin methods on  
instances of the pinned class are ignored.
</proposed>

Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!


Mime
View raw message