mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-18 10:09:59 -06:00
Merge pull request #10433 from 2403905/issue-10427
set the memlimit default loglevel to error
This commit is contained in:
6
changelog/unreleased/fix-memlimit-loglevel.md
Normal file
6
changelog/unreleased/fix-memlimit-loglevel.md
Normal file
@@ -0,0 +1,6 @@
|
||||
Bugfix: Fix the memlimit loglevel
|
||||
|
||||
We set the memlimit default loglevel to error.
|
||||
|
||||
https://github.com/owncloud/ocis/pull/10431
|
||||
https://github.com/owncloud/ocis/issues/10428
|
||||
@@ -1,6 +1,15 @@
|
||||
package shared
|
||||
|
||||
import (
|
||||
// we import automemlimit here to include it for ocis als well as individual service binaries
|
||||
_ "github.com/KimMachineGun/automemlimit"
|
||||
"log/slog"
|
||||
|
||||
"github.com/KimMachineGun/automemlimit/memlimit"
|
||||
)
|
||||
|
||||
// we init the memlimit here to include it for ocis als well as individual service binaries
|
||||
func init() {
|
||||
slog.SetLogLoggerLevel(slog.LevelError)
|
||||
_, _ = memlimit.SetGoMemLimitWithOpts(
|
||||
memlimit.WithLogger(slog.Default()),
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user