mirror of
https://github.com/vale981/agent
synced 2025-03-05 09:31:39 -05:00
GOMAXPROCS is forced to number of CPU-cores
This commit is contained in:
parent
d9d2a3c49b
commit
8001e7e94d
1 changed files with 4 additions and 2 deletions
6
main.go
6
main.go
|
@ -12,12 +12,11 @@ import (
|
|||
"os/signal"
|
||||
"runtime"
|
||||
|
||||
"github.com/indihub-space/agent/apiserver"
|
||||
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/credentials"
|
||||
_ "google.golang.org/grpc/encoding/gzip"
|
||||
|
||||
"github.com/indihub-space/agent/apiserver"
|
||||
"github.com/indihub-space/agent/config"
|
||||
"github.com/indihub-space/agent/lib"
|
||||
"github.com/indihub-space/agent/logutil"
|
||||
|
@ -50,6 +49,9 @@ var (
|
|||
)
|
||||
|
||||
func init() {
|
||||
// restrict number of system-threads to number of cores
|
||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||
|
||||
flag.StringVar(
|
||||
&flagINDIServerManagerAddr,
|
||||
"indi-server-manager",
|
||||
|
|
Loading…
Add table
Reference in a new issue