Re: [go-nuts] sigTERM not intercepted

2021-03-24 Thread Brian Candler
That is, you're sending the SIGTERM via systemd? Is it possible that systemd is sending it to the whole process group, and not just to the parent? Is systemd running the go command directly, or via a shell? If you want to be 100% sure, you can start the children in separate process groups.

Re: [go-nuts] sigTERM not intercepted

2021-03-24 Thread madscientist
On 3/23/21 11:59 PM, Kurtis Rader wrote: > It sounds as if you might be running your "REST endpoint" program from > an interactive shell (i.e., a terminal) and sending SIGTERM by > pressing something like Ctrl-C. Interactive job control, which > includes how signals generated by a "terminal" are

Re: [go-nuts] sigTERM not intercepted

2021-03-23 Thread Kurtis Rader
It sounds as if you might be running your "REST endpoint" program from an interactive shell (i.e., a terminal) and sending SIGTERM by pressing something like Ctrl-C. Interactive job control, which includes how signals generated by a "terminal" are handled, is a complex topic. So we need to know

[go-nuts] sigTERM not intercepted

2021-03-23 Thread Madscientist Microneil
Hi, I've got a REST endpoint coded in go and it communicates with various child processes to get it's work done. I've used // Set up to handle signals so we can stop when asked done := make(chan os.Signal, 3) signal.Notify(done, os.Interrupt, syscall.SIGINT, syscall.SIGTERM) and <-done to