User development, A new message was posted in the thread "Using ExpirationAlgorithm with PojoCache":
http://community.jboss.org/message/521901#521901 Author : Wendy Schmitz Profile : http://community.jboss.org/people/citress Message: -------------------------------------------------------------- I am trying to configure an eviction policy using the ExpriationAlgorithm for my PojoCache, and I would like to specify a time-to-live value for each pojo I insert into the cache. The only documentation I found says to do this: Cache cache = DefaultCacheFactory.createCache(); Fqn fqn1 = Fqn.fromString("/node/1"); Long future = new Long(System.currentTimeMillis() + 2000); // sets the expiry time for a node cache.getRoot().addChild(fqn1).put(ExpirationConfiguration.EXPIRATION_KEY, future); However, since I am using a PojoCache, I have to retrieve the underlying generic cache (through getCache()) in order to object the generic Cache in order to call .getRoot().addChild(...).put(....). The documentation for getCache() says only to use this for non-POJO cache operations. Can I use ExpirationAlogrithm wtih PojoCache, and if so, how do I configure the time-to-live for each pojo I'm inserting into the cache? Thanks! -------------------------------------------------------------- To reply to this message visit the message page: http://community.jboss.org/message/521901#521901
_______________________________________________ jboss-user mailing list [email protected] https://lists.jboss.org/mailman/listinfo/jboss-user
