ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Garima Bathla <garima.bat...@gmail.com>
Subject Custom Cache Managers
Date Fri, 10 Apr 2009 00:26:09 GMT
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*

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message