From 685d1dd491308dfb94186390627450d68279a28c Mon Sep 17 00:00:00 2001 From: GoEdgeLab Date: Mon, 7 Nov 2022 21:32:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=8A=82=E7=82=B9=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=E7=9A=84=E2=80=9C=E7=BC=93=E5=AD=98=E7=A3=81=E7=9B=98?= =?UTF-8?q?=E5=AE=B9=E9=87=8F=E2=80=9D=E4=B8=8D=E8=B5=B7=E4=BD=9C=E7=94=A8?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- go.mod | 1 + internal/caches/storage_file.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 458cd2e..4aff959 100644 --- a/go.mod +++ b/go.mod @@ -5,6 +5,7 @@ go 1.18 replace ( github.com/TeaOSLab/EdgeCommon => ../EdgeCommon github.com/fsnotify/fsnotify => github.com/iwind/fsnotify v1.5.2-0.20220817040843-193be2051ff4 + rogchap.com/v8go => /Users/Workspace/Projects/v8go ) require ( diff --git a/internal/caches/storage_file.go b/internal/caches/storage_file.go index ae4a8cb..60dc9d9 100644 --- a/internal/caches/storage_file.go +++ b/internal/caches/storage_file.go @@ -954,7 +954,7 @@ func (this *FileStorage) purgeLoop() { this.checkDiskSpace() // 计算是否应该开启LFU清理 - var capacityBytes = this.policy.CapacityBytes() + var capacityBytes = this.diskCapacityBytes() var startLFU = false var lfuFreePercent = this.policy.PersistenceLFUFreePercent if lfuFreePercent <= 0 {