gen_server terminate stopping other application like mnesia

Yogish Baliga yogishb@REDACTED
Tue Sep 1 00:17:22 CEST 2009

My app has one supervisor which in turn start few gen_server (standard OTP). start_link of one of the gen_server,  start several other applications. To ensure the clean shutdown, this gen_server's terminate function call application:stop(..) on the dependent applications.

While shutting down the whole VM via init:stop(), my app's supervisor get's brutally killed as the gen_server 's terminate function does not return. It gets stuck in application:stop(..) of dependent application (including mnesia).

Is this the desired behavior?

-- baliga
"Point of view is worth 80 IQ points" --Alan Kay

More information about the erlang-questions mailing list