我的Ehcache配置開始是這樣的:春季4.1.7和羣集ehcache配置可能嗎?
<ehcache maxBytesLocalHeap="200M" updateCheck="false">
遇到錯誤,如「maxEntriesLocalHeap不兼容maxBytesLocalHeap上高速緩存管理器設置」後,我看着的彈簧上下文支持來源:
@SuppressWarnings("deprecation")
public EhCacheFactoryBean() {
setMaxEntriesLocalHeap(10000);
setMaxElementsOnDisk(10000000);
setTimeToLiveSeconds(120);
setTimeToIdleSeconds(120);
}
到setMaxElementsOnDisk該呼叫被評價是這樣的:
void net.sf.ehcache.config.CacheConfiguration.setMaxElementsOnDisk(int maxElementsOnDisk)
Deprecated. use setMaxEntriesLocalDisk(long) for unclustered caches and setMaxEntriesInCache(long) for clustered caches.
Sets the maximum number elements on Disk. 0 means unlimited.
This property can be modified dynamically while the cache is operating.
Parameters:
maxElementsOnDisk the maximum number of Elements to allow on the disk. 0 means unlimited.
這是否意味着春季使用到4.1.7與其依賴ehcache一起2.9.1一個聚簇緩存是不可能的使用彈簧EhCacheFactoryBean?
最好的問候, 卡斯滕