v1.4.1
This commit is contained in:
@@ -3,10 +3,11 @@
|
||||
package memutils
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
teaconst "github.com/TeaOSLab/EdgeNode/internal/const"
|
||||
"github.com/TeaOSLab/EdgeNode/internal/utils/goman"
|
||||
"github.com/shirou/gopsutil/v3/mem"
|
||||
"time"
|
||||
)
|
||||
|
||||
var systemTotalMemory = -1
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2023 GoEdge goedge.cdn@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
// Copyright 2023 GoEdge goedge.cdn@gmail.com. All rights reserved. Official site: https://goedge.cloud .
|
||||
//go:build go1.19
|
||||
|
||||
package memutils
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2023 GoEdge goedge.cdn@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
// Copyright 2023 GoEdge goedge.cdn@gmail.com. All rights reserved. Official site: https://goedge.cloud .
|
||||
//go:build !go1.19
|
||||
|
||||
package memutils
|
||||
@@ -6,4 +6,4 @@ package memutils
|
||||
// 设置软内存最大值
|
||||
func setMaxMemory(memoryGB int) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,8 +3,9 @@
|
||||
package memutils_test
|
||||
|
||||
import (
|
||||
"github.com/TeaOSLab/EdgeNode/internal/utils/mem"
|
||||
"testing"
|
||||
|
||||
"github.com/TeaOSLab/EdgeNode/internal/utils/mem"
|
||||
)
|
||||
|
||||
func TestSystemMemoryGB(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user