Cannot stop server with gRPC service in 0.97
See original GitHub issueHi guys,
Could be red herring but I was playing with Armeria 0.97 a bit (like it was recommended in https://github.com/line/armeria/issues/2319). It looks like that that I can’t stop a server with single gRPC service, line (1) from the code below never returns.
ServerBuilder sb = new ServerBuilder();
Server server =
sb.service(new GrpcServiceBuilder().addService(new PingService()).build())
.port(1234, SessionProtocol.HTTP).build();
CompletableFuture startFuture = server.start();
startFuture.join();
CompletableFuture stopFuture = server.stop();
stopFuture.join(); // (1)
The same code worked fine in 0.88.
Sincerely, Andrey
PS. The test is executed from IntelliJ Idea 2019.2 on openjdk 12.0.2+10
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (6 by maintainers)
Top Results From Across the Web
Reliable gRPC services with deadlines and cancellation
It stops misbehaving services from running forever and exhausting server resources. Deadlines are a useful tool for building reliable apps ...
Read more >How to stop golang gRPC server with a function?
I am able to solve the problem by declaring *grpc.Server variable globally outside StartGrpcServer() , and then using it in StopGrpcServer() .
Read more >Implementing a gRPC Service - Quarkus
Implementing a gRPC service requires the gRPC classes to be generated. Place your proto files in ... Quarkus gRPC Server implements the reflection...
Read more >Basics tutorial | Go - gRPC
This tutorial provides a basic Go programmer's introduction to working with gRPC. By walking through this example you'll learn how to: Define a...
Read more >gRPC not dropping disconnected channel - Google Groups
Also I found that if the server is leave stopped for a long time before ... Tested with Python grpcio==1.19.0 server/client and with...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

After some tests it looks like that minor version of Netty makes all the difference
Armeria 0.88 works fine with both 4.1.42.Final and 4.1.43.Final.
Armeria 0.97 works with 4.1.43.Final but for some reason I can’t stop server on 4.1.42.Final and below (4.1.41.Final doesn’t work as well). “Luckily” my project is on 4.1.42.Final.
Can you try this?
Let me close this issue. If you have a problem with stopping a server, feel free to reopen this.