mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-13 03:40:27 +08:00
实现open file cache
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="color-border">文件目录最大容量</td>
|
||||
<td class="color-border">文件目录最大容量 *</td>
|
||||
<td>
|
||||
<size-capacity-box :v-name="'capacityJSON'" :v-count="128" :v-unit="'gb'" :key="'capacityJSON1'"></size-capacity-box>
|
||||
<p class="comment">作为二级缓存的文件目录允许缓存的最大容量,如果为0表示没有限制。</p>
|
||||
@@ -38,6 +38,13 @@
|
||||
<size-capacity-box :v-name="'fileMemoryCapacityJSON'" :v-count="0" :v-unit="'gb'" :key="'fileMemoryCapacityJSON'"></size-capacity-box>
|
||||
<p class="comment">作为一级缓存的内存最大容量,如果为0表示不使用内存作为一级缓存。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="color-border">缓存文件句柄缓存</td>
|
||||
<td>
|
||||
<input type="text" name="fileOpenFileCacheMax" maxlength="6" value="0" style="width: 10em"/>
|
||||
<p class="comment">保持缓存文件句柄,提升缓存文件打开速度,建议数量是缓存文件数量的10%。</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
|
||||
@@ -40,6 +40,10 @@
|
||||
<p class="comment">作为一级缓存的内存最大容量,如果为0表示不使用内存作为一级缓存。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr v-if="cachePolicy.options.openFileCache != null && cachePolicy.options.openFileCache.isOn && cachePolicy.options.openFileCache.max > 0">
|
||||
<td>缓存文件句柄缓存</td>
|
||||
<td>{{cachePolicy.options.openFileCache.max}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
<tbody v-if="cachePolicy.type != 'file'">
|
||||
|
||||
@@ -47,6 +47,13 @@
|
||||
<size-capacity-box :v-name="'fileMemoryCapacityJSON'" :v-count="0" :v-unit="'gb'"></size-capacity-box>
|
||||
<p class="comment">作为一级缓存的内存最大容量,如果为0表示不使用内存作为一级缓存。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="color-border">缓存文件句柄缓存</td>
|
||||
<td>
|
||||
<input type="text" name="fileOpenFileCacheMax" v-model="fileOpenFileCacheMax" maxlength="6" value="0" style="width: 10em"/>
|
||||
<p class="comment">保持缓存文件句柄,提升缓存文件打开速度,建议数量是缓存文件数量的10%。</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
|
||||
@@ -2,4 +2,9 @@ Tea.context(function () {
|
||||
this.success = NotifyReloadSuccess("保存成功 ")
|
||||
|
||||
this.policyType = this.cachePolicy.type
|
||||
|
||||
this.fileOpenFileCacheMax = 0
|
||||
if (this.cachePolicy.type == "file" && this.cachePolicy.options.openFileCache != null && this.cachePolicy.options.openFileCache.isOn && this.cachePolicy.options.openFileCache.max > 0) {
|
||||
this.fileOpenFileCacheMax = this.cachePolicy.options.openFileCache.max
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user