I see, so let's say I wanted to use the LRUAlgorithm on node "/a" of my cache to give
it a 10 second timeout. In such a case I would declare a regionManager to have my
LRUPolicy, grab a region from the manager with a node "/a" and the LRUAlgorithm and
set the region timeout. As follows:
cache=new TreeCache(group_name, props, 3000);
// .. instantiate cache code...
cache.start();
LRUAlgorithm algo = new LRUAlgorithm();
LRUPolicy policy = new LRUPolicy();
RegionManager regionManager = new RegionManager(policy);
Region region = regionManager.createRegion("/a", algo);
region.setTimeToIdleSeconds(10);
My question is then how to tie this back into the cache. The treecache has
cache.setEvictionPolicyClass(String policy_class), but then how does it know about the
region?
Thanks a lot for your patience, and any sample code that could be provided would be
greatly appreciated.
<a
href="http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3827283#3827283">View
the original post</a>
<a
href="http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3827283>Reply
to the post</a>
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development