I'm not sure, but I think you can do it like this: <classpath file="/path/to/custom/cache/manager.jar"/> <typedef name="Custom-CM" classname="org.gb.test.OptimisticCacheManager"/>
<caches> <cache name="xxx" basedir="/path/to/custom/basedir/> <Custom-CM name="yyy" basedir="..." /> </caches> Here the cache with name "yyy" will be your custom cache-manager. Maarten ----- Original Message ---- From: Garima Bathla <[email protected]> To: [email protected] Sent: Friday, April 10, 2009 2:26:09 AM Subject: Custom Cache Managers Hello, I am in a process of creating my own custom cache managers and I am little confused reading the documentation. As per documentation, I can define my custom cache manager via type def and classpath. Also as per documentation the caches element lets you configure the default cache manager or you can create multiple new definitions of cache managers based on the default cache manager in the child element of caches - i.e. cache element. But I am confused on how exactly the custom cache manager that I created via typedef tag can be registered as a Cache Manager before it can be used. e.g. <classpath file="/path/to/custom/cache/manager.jar"/> <typedef name="Custom-CM" classname="org.gb.test.OptimisticCacheManager"/> <caches> <cache name="xxx" basedir="/path/to/custom/basedir/> </caches> So in the above example a new cache manager instance xxx is created and this is based on default-cache manager. So where exactly can I register OptimisticCacheManager? Like other typedef's for lockstrategies and latest-strategies. Also please note I don't want to over-ride the default-cache manager . >From the documenation description of Cache element : cache<http://ant.apache.org/ivy/history/2.1.0-rc1/settings/caches/cache.html>defines a new repository cache instance, *based on the default repository cache implementation*
