[erlang-questions] OTP question

Ladislav Lenart lenartlad@REDACTED
Mon Aug 18 10:36:19 CEST 2008

Edwin Fine wrote:
> In test_ser.erl, trap exits:
> init([]) ->
> *    erlang:process_flag(trap_exit, true),
> *    io:format("TEST SERVER INIT.~n",[]),
>     {ok, []}.


I would like to clarify that both your supervisor and worker terminated
when the application stopped. Only the worker's (gen_server) terminate/2
callback was not called because the termination reason from its parent
(the supervisor) was atom shutdown which is different from atom normal.
Since the worker didn't trap exit signals, it "crashed".

Ladislav Lenart

More information about the erlang-questions mailing list