-
Notifications
You must be signed in to change notification settings - Fork 817
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
Spring boot with GRPC server blocking GRPC client request #1057
Comments
How does your grpc service look like? |
Yes, I do.
|
a) Is the |
No, the code that I provided above is from the service that I want to reach from the service that I described in the question above. When it comes to executing the .setAccountsForMerchant method
my request just hangs. |
Unless that is some weird issue regarding server address resolution, I don't have any idea what might cause this.
|
Set in application.yml
Also didn't help |
Hi everyone, we have had a similar experience since updating to v3.0.0. It's working on production, but locally, the client hangs forever when calling a gRPC server. After adding
The host is configured as We reverted to v2.15.0 for now. |
In my case if I turn down the grpc server app and I start the grpc client app, then as long as the grpc client request occurs before the ServletWebServerInitializedEvent (or any other spring boot event) then the client request will not hang and the deadline exceeded takes place. One work around is to drop the deadline exceeded and use instead a ListenableFuture with the timeout moved to the future get method.
` I have tried ApplicationStartedEvent, ContextRefreshedEvent - same. The grpc client hangs. In ClientCalls.java from the grpc-java project, the thread that sends that request is never woke up .... More precisely in blockingUnaryCall method executor.waitAndDrain does not timeout on the LockSupport.park call. Some form of reference is lost somehow or something else gets corrupted for a reason. Unfortunately I could not go further than that. |
I have Spring boot app v.3.2.1 and GRPC server and client in one app.
Initially, when I wrote the service, I only had a GRPC client. Everything worked well until the moment when I added a GRPC server to the same service. After adding it, requests to the GRPC server are successful, but when trying to make a request through the GRPC client, the request simply freezes.
Dependencies i have in pom.xml
Applcation.yaml
In logs due request i have
I try to make requests locally, but i didn't help.
Update:
I add deadline for this request:
After passing 5 seconds I received the following logs after the ones I sent earlier.
The text was updated successfully, but these errors were encountered: