application:stop hangs
Chandrashekhar Mullaparthi
Chandrashekhar.Mullaparthi@REDACTED
Thu May 24 14:41:51 CEST 2001
Right - I did a bit of digging and found that supervisor is hanging in the
shutdown(Pid, brutal_kill) function.
The reason seems to be that the supervisor did exit(Pid, kill) - but the
message {'EXIT', Pid, killed) was only sent to another process to which my
worker is linked to! And the supervisor is waiting in this bit of code
shutdown(Pid, brutal_kill) ->
exit(Pid, kill),
receive
{'EXIT', Pid, killed} -> ok;
{'EXIT', Pid, OtherReason} -> {error, OtherReason}
end;
Why is it that if a process has links to many processes, only one of them
gets the message that this process has been killed??
cheers,
Chandru
> -----Original Message-----
> From: Chandrashekhar Mullaparthi
> [mailto:Chandrashekhar.Mullaparthi@REDACTED]
> Sent: 24 May 2001 12:21
> To: 'Erlang mailing list'
> Subject: application:stop hangs
>
>
> Hi,
>
> I need help finding out why my application:stop hangs.
> I have a supervisor(one_for_one) which has:
>
> 5 vanilla gen_servers,
> {permanent, 2000, worker}
>
> 10 workers spawned using proc_lib:spawn by one of the above
> gen_server. Do
> not trap exits
> {transient, brutal_kill, worker}
>
> 2 gen_servers which trap_exits but also shutdown when they receive a
> {'EXIT', Parent, shutdown} message
> {permanent, 2000, worker}
>
> 1 supervisor(simple_one_for_one) which supervises two other vanilla
> gen_servers
> {permanent, 5000, supervisor}. Childspec is {transient,
> 2000, worker}
>
> How do I track down the rogue process(es)?
>
> tia,
> Chandru
>
>
>
NOTICE AND DISCLAIMER:
This email (including attachments) is confidential. If you have received
this email in error please notify the sender immediately and delete this
email from your system without copying or disseminating it or placing any
reliance upon its contents. We cannot accept liability for any breaches of
confidence arising through use of email. Any opinions expressed in this
email (including attachments) are those of the author and do not necessarily
reflect our opinions. We will not accept responsibility for any commitments
made by our employees outside the scope of our business. We do not warrant
the accuracy or completeness of such information.
More information about the erlang-questions
mailing list