[erlang-questions] gen_server:init(Args) -> {stop, {normal, Reply}}

Guilherme Andrade g@REDACTED
Sat Sep 7 16:33:15 CEST 2019


On Sat, 7 Sep 2019 at 15:11, Guilherme Andrade <g@REDACTED> wrote:

> This way it won't be interpreted as a crash but still be returned to
> whomever called `gen_server:start_link`.
>

(Assuming that, if you're launching the gen_server under a supervisor, its
child specification declares `restart` as either `transient` or
`temporary`.)



>
> On Mon, 2 Sep 2019 at 10:04, Aleksey Kluchnikov <kluchnikovas@REDACTED>
> wrote:
>
>> Hi
>>
>> look at
>> https://github.com/erlang/otp/blob/maint-22/lib/stdlib/src/gen_server.erl
>> line 337-371
>> gen_server:init/1 hasn`t {normal, Reply} answer.
>> It will be pretty good have gen_server:start/start_link normal reply
>> without exit CRASH REPLY
>> What do you think of it?
>> _______________________________________________
>> erlang-questions mailing list
>> erlang-questions@REDACTED
>> http://erlang.org/mailman/listinfo/erlang-questions
>>
>
>
> --
> Guilherme
>


-- 
Guilherme
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20190907/4332e391/attachment.htm>


More information about the erlang-questions mailing list