ImageResizer diskcache cleanupStrategy [英] ImageResizer diskcache cleanupStrategy

查看:341
本文介绍了ImageResizer diskcache cleanupStrategy的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在使用ImageResizer插件与diskCache插件沿着高速缓存大小调整动态影像。

We are using ImageResizer plugin to resize images on the fly along with diskCache plugin for caching.

<diskCache dir="~/imagecache" autoClean="false" hashModifiedDate="true" enabled="true"
  subfolders="32" cacheAccessTimeout="15000" asyncWrites="false" syncBufferSize="10485760" />

<cleanupStrategy startupDelay="00:05" minDelay="00:00:20" maxDelay="00:05" 
    optimalWorkSegmentLength="00:00:04" 
    targetItemsPerFolder="400" maximumItemsPerFolder="1000" 
    avoidRemovalIfCreatedWithin="24:00" avoidRemovalIfUsedWithin="4.00:00" 
    prohibitRemovalIfUsedWithin="00:05" prohibitRemovalIfCreatedWithin="00:10" />

我们要提到的每个文件夹的图像数量。
然而,选项cleanupStrategy可用。
现在,我们不想设置清理化战略。
有人可以告诉我怎么可以设置targetItemsPerFolder&放大器; maximumItemsPerFolder没有清理的东西?

We want to mention the number of images per folder. However the options are available in cleanupStrategy. Right now we do not want to set the clean up stragegy. Can somebody advise how can I set targetItemsPerFolder & maximumItemsPerFolder without clean up stuff?

在此先感谢..

推荐答案

只能使用你实际上改变的属性。

Only use the attributes that you're actually changing.

&LT; cleanupStrategy targetItemsPerFolder =400maximumItemsPerFolder =1000/&GT;

更重要的是,不要乱用精心调校默认的。调整的子计数 diskcache 元素代替,如文档中推荐的无处不在。

Better yet, don't mess with carefully tuned defaults at all. Adjust the subfolders count on the diskcache element instead, as recommended everywhere in the documentation.

这篇关于ImageResizer diskcache cleanupStrategy的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆