Description
jsvc-unix.c runs the following code in the child process before
/* create a new process group to prevent kill 0 killing the monitor process */ #if defined(OS_FREEBSD) || defined(OS_DARWIN) setpgid(0, 0); #else setpgrp(); #endif
This puts the child in its own process group, breaking some process management tools (such as supervisor) that expect to be able to kill a logical process by sending a SIGKILL to its process group. The su binary, which is somewhat analogous in function to jsvc, doesn't do this.
As best I can tell, there's no code in jsvc that does kill(0, ...). There's also not enough svn history to provide more context. As for the child process doing a kill(0, ...), I find it highly unlikely that the JVM itself sends signals.
So is the setpgrp call still necessary? If not, can it be removed?