-
Notifications
You must be signed in to change notification settings - Fork 1.5k
remove depecrated code used from grpc library #9345
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR removes deprecated gRPC connection methods by replacing calls to grpc.Dial and grpc.DialContext with grpc.NewClient and updating related connection options.
- Replace grpc.WithBackoffMaxDelay with grpc.WithConnectParams using the new backoff configuration
- Update connection establishment calls in production and test files to use grpc.NewClient
- Ensure consistency across components that rely on gRPC connections
Reviewed Changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
conn/pool.go | Updated connection creation and backoff configuration |
dgraph/cmd/zero/zero_test.go | Replaced DialContext with NewClient in tests |
graphql/e2e/common/common.go | Updated client creation in GraphQL bootstrap |
ee/backup/run.go | Updated backup restore client connection creation |
testutil/zero.go | Replaced grpc.Dial with grpc.NewClient in test utilities |
dgraph/cmd/bulk/loader.go | Updated client creation for bulk loader backup operations |
testutil/client.go | Updated client creation in test utilities |
systest/backup/filesystem/backup_test.go | Replaced Dial with NewClient for filesystem backup tests |
systest/export/export_test.go | Updated export test gRPC connection creation |
systest/online-restore/online_restore_test.go | Updated multiple client connections for online restore tests |
graphql/e2e/common/schema.go | Updated schema test client connection creation |
dgraphtest/local_cluster.go | Replaced Dial with NewClient for local cluster client connections |
systest/backup/minio/backup_test.go | Updated minio backup test gRPC connection creation |
graphql/e2e/common/admin.go | Updated admin test client connection creation |
dgraph/cmd/alpha/mutations_mode/mutations_mode_test.go | Updated mutations mode tests with NewClient instead of Dial |
systest/backup/nfs-backup/backup_test.go | Updated NFS backup test client connection creation |
graphql/e2e/common/query.go | Updated client creation for query tests |
graphql/e2e/common/mutation.go | Updated mutation test client connection creation |
graphql/e2e/common/error.go | Updated error test client connection creation |
systest/backup/minio-large/backup_test.go | Updated minio-large backup test gRPC connection creation |
Comments suppressed due to low confidence (3)
conn/pool.go:179
- Verify that grpc.NewClient correctly handles connection timeouts and context cancellation, as its behavior may differ from grpc.DialContext.
conn, err := grpc.NewClient(addr, conOpts...)
dgraph/cmd/zero/zero_test.go:52
- Confirm that removing the grpc.WithBlock option does not cause race conditions in tests, as connection establishment might behave asynchronously with grpc.NewClient.
con, err := grpc.NewClient(testutil.SockAddrZero, dialOpts...)
dgraphtest/local_cluster.go:777
- Check that using grpc.NewClient in this health check context maintains the expected retry behavior and service configuration provided by grpc.WithDefaultServiceConfig.
conn, err := grpc.NewClient(url, grpc.WithTransportCredentials(insecure.NewCredentials()), grpc.WithDefaultServiceConfig(retryPolicy))
No description provided.