You can call a grpc::Server::Shutdown with a timeout, after the timeout the 
pending rpcs will be cancelled. In your rpc handler (if you have long-lived 
streaming or rpcs), you will need to check ServerContext::isCancelled to 
finish up the rpcs. The sync server will not finish cleanup before you 
finish all the rpcs.

On Friday, August 2, 2019 at 4:27:31 PM UTC-7, Jeff wrote:
>
> Hi all,
>
> Is there an example of the correct way to shut down a synchronous server? 
> or do synchronous servers not need to be explicitly shutdown? Thanks!
>

-- 
You received this message because you are subscribed to the Google Groups 
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to grpc-io+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/grpc-io/b28a5da4-f187-4864-89e5-a9f76198ea79%40googlegroups.com.

Reply via email to