Skip to content

Commit

Permalink
Revert "Delete grpc.WithBlock() and grpc.WaitForReady(true) options (#…
Browse files Browse the repository at this point in the history
…917)" (#918)

This reverts commit 2d3d13c.

Signed-off-by: Nikita Skrynnik <[email protected]>
  • Loading branch information
NikitaSkrynnik authored Aug 14, 2023
1 parent 2d3d13c commit 1b810ff
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
4 changes: 3 additions & 1 deletion internal/tests/suite_healthcheck_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2020-2023 Cisco and/or its affiliates.
// Copyright (c) 2020-2022 Cisco and/or its affiliates.
//
// SPDX-License-Identifier: Apache-2.0
//
Expand All @@ -23,6 +23,7 @@ import (

"github.com/networkservicemesh/sdk/pkg/tools/log/logruslogger"

"google.golang.org/grpc"
"google.golang.org/grpc/health/grpc_health_v1"

"github.com/networkservicemesh/sdk/pkg/tools/log"
Expand All @@ -37,6 +38,7 @@ func (f *ForwarderTestSuite) TestHealthCheck() {
&grpc_health_v1.HealthCheckRequest{
Service: "networkservice.NetworkService",
},
grpc.WaitForReady(true),
)
f.NoError(err)
f.Require().NotNil(healthResponse)
Expand Down
1 change: 1 addition & 0 deletions internal/tests/suite_setup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ func (f *ForwarderTestSuite) SetupSuite() {
f.sutCC, err = grpc.DialContext(f.ctx,
regEndpoint.NetworkServiceEndpoint.GetUrl(),
grpc.WithTransportCredentials(clientCreds),
grpc.WithBlock(),
grpc.WithDefaultCallOptions(
grpc.PerRPCCredentials(token.NewPerRPCCredentials(spiffejwt.TokenGeneratorFunc(source, f.config.MaxTokenLifetime))),
),
Expand Down
2 changes: 2 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,9 @@ func main() {

dialOptions := append(
tracing.WithTracingDial(),
grpc.WithBlock(),
grpc.WithDefaultCallOptions(
grpc.WaitForReady(true),
grpc.PerRPCCredentials(token.NewPerRPCCredentials(spiffejwt.TokenGeneratorFunc(source, cfg.MaxTokenLifetime)))),
grpc.WithTransportCredentials(
grpcfd.TransportCredentials(
Expand Down

0 comments on commit 1b810ff

Please sign in to comment.