Skip to content

Commit

Permalink
fix: client grpc dial non-block (dragonflyoss#2261)
Browse files Browse the repository at this point in the history
Signed-off-by: Jim Ma <[email protected]>
Signed-off-by: 李龙峰 <[email protected]>
  • Loading branch information
jim3ma authored and 李龙峰 committed May 15, 2023
1 parent eec63a1 commit 004e964
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client/daemon/peer/peertask_piecetask_synchronizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ func (s *pieceTaskSynchronizer) start(request *commonv1.PieceTaskRequest, dstPee
credentialOpt := grpc.WithTransportCredentials(s.peerTaskConductor.GRPCCredentials)

dialCtx, cancel := context.WithTimeout(s.ctx, s.peerTaskConductor.GRPCDialTimeout)
grpcClient, err := dfdaemonclient.GetV1(dialCtx, netAddr.String(), credentialOpt)
grpcClient, err := dfdaemonclient.GetV1(dialCtx, netAddr.String(), credentialOpt, grpc.WithBlock())
cancel()

if err != nil {
Expand Down

0 comments on commit 004e964

Please sign in to comment.