Skip to content

Commit

Permalink
bugfix#map可能会出现并发读写
Browse files Browse the repository at this point in the history
  • Loading branch information
ouqiang committed Jun 15, 2019
1 parent 9215153 commit beeda4b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ github.com/klauspost/compress v1.5.0 h1:iDac0ZKbmSA4PRrRuXXjZL8C7UoJan8oBYxXkMzE
github.com/klauspost/compress v1.5.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
github.com/klauspost/cpuid v1.2.1 h1:vJi+O/nMdFt0vqm8NZBI6wzALWdA2X+egi0ogNyrC/w=
github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
github.com/konsorten/go-windows-terminal-sequences v1.0.1 h1:mweAR1A6xJ3oS2pRaGiHgQ4OO8tzTaLawm8vnODuwDk=
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
Expand Down
3 changes: 2 additions & 1 deletion internal/modules/rpc/grpcpool/grpc_pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ func (p *GRPCPool) Get(addr string) (rpc.TaskClient, error) {
if err != nil {
return nil, err
}
p.conns[addr] = client

return client.rpcClient, nil
}
Expand Down Expand Up @@ -115,5 +114,7 @@ func (p *GRPCPool) factory(addr string) (*Client, error) {
rpcClient: rpc.NewTaskClient(conn),
}

p.conns[addr] = client

return client, nil
}

0 comments on commit beeda4b

Please sign in to comment.