优化代码

This commit is contained in:
GoEdgeLab
2024-03-28 17:17:34 +08:00
parent e242502948
commit 04bff814d9
27 changed files with 52 additions and 63 deletions

View File

@@ -6,7 +6,7 @@ import (
"errors"
"fmt"
"github.com/TeaOSLab/EdgeNode/internal/events"
"github.com/TeaOSLab/EdgeNode/internal/utils"
memutils "github.com/TeaOSLab/EdgeNode/internal/utils/mem"
"github.com/cockroachdb/pebble"
"github.com/iwind/TeaGo/Tea"
"io"
@@ -90,7 +90,7 @@ func (this *Store) Open() error {
Logger: NewLogger(),
}
var memoryMB = utils.SystemMemoryGB() * 1
var memoryMB = memutils.SystemMemoryGB() * 1
if memoryMB > 256 {
memoryMB = 256
}