aboutsummaryrefslogtreecommitdiffstats
path: root/make
diff options
context:
space:
mode:
authorChristopher Faulet <[email protected]>2011-09-05 12:42:33 +0200
committerHenrik Nord <[email protected]>2011-09-16 14:54:44 +0200
commit47759479146ca11ad81eca0bb3236b265e20601d (patch)
treedebf184d6518c4737a9d91867d1923d78c38d977 /make
parent6a113a60dba9fd6c4d736b9e56c52f3494a15027 (diff)
downloadotp-47759479146ca11ad81eca0bb3236b265e20601d.tar.gz
otp-47759479146ca11ad81eca0bb3236b265e20601d.tar.bz2
otp-47759479146ca11ad81eca0bb3236b265e20601d.zip
Explicitly kill dynamic children in supervisors
According to the supervisor's documentation: "Important note on simple-one-for-one supervisors: The dynamically created child processes of a simple-one-for-one supervisor are not explicitly killed, regardless of shutdown strategy, but are expected to terminate when the supervisor does (that is, when an exit signal from the parent process is received)." All is fine as long as we stop simple_one_for_one supervisor manually. Dynamic children catch the exit signal from the supervisor and leave. But, if this happens when we stop an application, after the top supervisor has stopped, the application master kills all remaining processes associated to this application. So, dynamic children that trap exit signals can be killed during their cleanup (here we mean inside terminate/2). This is unpredictable and highly time-dependent. In this commit, supervisor module is patched to explicitly terminate dynamic children accordingly to the shutdown strategy. NOTE: Order in which dynamic children are stopped is not defined. In fact, this is "almost" done at the same time.
Diffstat (limited to 'make')
0 files changed, 0 insertions, 0 deletions