Skip to content
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

chore: by default support lazy connections #388

Merged
merged 3 commits into from
Mar 7, 2024

Conversation

bruuuuuuuce
Copy link
Contributor

@bruuuuuuuce bruuuuuuuce commented Mar 7, 2024

when using the Dial method inside of grpc-go, the client automatically tries to connect to the server. This is not the default behavior that we want, and is not the default behavior of other grpc language impl.

https://github.com/grpc/grpc-go/blob/99ded5c4905feb5d6ef305114c6f8a7a942011c7/clientconn.go#L222-L225

This pr addresses this by calling NewClient, which does not try to automatically connect to the server, unless an eagerConnection is specified. If the user wants to eagerly connect (which is currently only an option for data plane client), then the behavior is unchanged

Verified

This commit was signed with the committer’s verified signature.
h3ndrk Hendrik
@bruuuuuuuce bruuuuuuuce marked this pull request as ready for review March 7, 2024 18:43
@bruuuuuuuce bruuuuuuuce requested a review from a team March 7, 2024 18:44
Copy link
Contributor

@cprice404 cprice404 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:ty:

@bruuuuuuuce bruuuuuuuce merged commit ce01397 into main Mar 7, 2024
6 checks passed
@bruuuuuuuce bruuuuuuuce deleted the feat/lazyConnectingClient2 branch March 7, 2024 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants