Trapping these signals hijacks the usual termination behavior for any program that happens to link in the engine and perform an operation that starts a gRPC server. These servers already provide a cancellation mechanism via a `cancel` channel parameter; if the using program wants to gracefully terminate these servers on some signal, it is responsible for providing that behavior. This also fixes a leak in which the goroutine responsible for waiting on a server's signals and cancellation channel would never exit. |
||
---|---|---|
.. | ||
serve.go |