cmd/geth: disable automaxprocs log (#27814)

Co-authored-by: Felix Lange <fjl@twurst.com>
This commit is contained in:
Delweng 2023-08-02 00:02:36 +08:00 committed by GitHub
parent 7de748d3f6
commit ff97b4cc6a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -39,14 +39,12 @@ import (
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/ethereum/go-ethereum/metrics" "github.com/ethereum/go-ethereum/metrics"
"github.com/ethereum/go-ethereum/node" "github.com/ethereum/go-ethereum/node"
"go.uber.org/automaxprocs/maxprocs"
// Force-load the tracer engines to trigger registration // Force-load the tracer engines to trigger registration
_ "github.com/ethereum/go-ethereum/eth/tracers/js" _ "github.com/ethereum/go-ethereum/eth/tracers/js"
_ "github.com/ethereum/go-ethereum/eth/tracers/native" _ "github.com/ethereum/go-ethereum/eth/tracers/native"
// Automatically set GOMAXPROCS to match Linux container CPU quota.
_ "go.uber.org/automaxprocs"
"github.com/urfave/cli/v2" "github.com/urfave/cli/v2"
) )
@ -245,6 +243,7 @@ func init() {
) )
app.Before = func(ctx *cli.Context) error { app.Before = func(ctx *cli.Context) error {
maxprocs.Set() // Automatically set GOMAXPROCS to match Linux container CPU quota.
flags.MigrateGlobalFlags(ctx) flags.MigrateGlobalFlags(ctx)
return debug.Setup(ctx) return debug.Setup(ctx)
} }