-
Notifications
You must be signed in to change notification settings - Fork 4.5k
[Prism] Set keepalive policy for grpc server. #37021
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
Summary of ChangesHello @shunping, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request enhances the robustness of the Prism gRPC server by implementing a keepalive enforcement policy. This policy ensures that client connections remain active and are not prematurely terminated by network intermediaries, which is crucial for the stability and reliability of job management services. The changes specifically set a minimum ping interval and allow pings on idle connections. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
dd3ebdd to
0cdae50
Compare
0cdae50 to
b28cc6f
Compare
| opts := []grpc.ServerOption{ | ||
| grpc.MaxRecvMsgSize(math.MaxInt32), | ||
| grpc.KeepaliveEnforcementPolicy(keepalive.EnforcementPolicy{ | ||
| MinTime: 20 * time.Second, // Minimum duration a client should wait before sending a keepalive ping |
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.
The 20-second min time matches the option set in the python client:
|
Checks are failing. Will not request review until checks are succeeding. If you'd like to override that behavior, comment |
|
Failure of PreCommit Java PVR Prism Loopback seems to be related to #36897. |
|
Assigning reviewers: R: @lostluck for label go. Note: If you would like to opt out of this review, comment Available commands:
The PR bot will only process comments in the main thread (not review comments). |
After the changes in FnApiRunner grpc server setting (#37013), one test is still flaky due to too-many-ping grpc error(https://github.com/apache/beam/actions/runs/19973942914/job/57285283120).
It seems that this test is running with prism (verified in a debugging PR #37020): https://github.com/apache/beam/actions/runs/19981955990/job/57309934542?pr=37020
This PR is to change the options of Prism grpc server, so it won't complain about the ping frequency of the client.
Notice that the default min ping frequency in the server option is 5 mins (https://pkg.go.dev/google.golang.org/grpc@v1.77.0/keepalive#EnforcementPolicy)