Skip to content

Fix premature exit#135

Open
suexcxine wants to merge 1 commit intodevinus:masterfrom
suexcxine:patch-1
Open

Fix premature exit#135
suexcxine wants to merge 1 commit intodevinus:masterfrom
suexcxine:patch-1

Conversation

@suexcxine
Copy link

I met a lot of the following error logs when I execute init:stop()

14:46:29.924 [error] Undefined:Undefined gen_server <0.1199.0> terminated with reason: killed
14:46:29.924 [error] Undefined:Undefined CRASH REPORT Process <0.1199.0> with 0 neighbours exited with reason: killed in gen_server:decode_msg/9 line 432

And terminate function of mysql_conn.erl didn't get fully executed.

I have a pool size of 1600, maybe this caused this problem to be obvious.

Because exit(State#state.supervisor, shutdown) is async shutdown, the pool process passed away immediately,
so State#state.supervisor gets also killed,
Now that parent of all workers is dead, so workers show messages pasted above(gen_server:decode_msg/9 line 432),
So we need to wait a little bit to allow workers to terminate properly.

I met a lot of the following error logs when I execute `init:stop()`
```
14:46:29.924 [error] Undefined:Undefined gen_server <0.1199.0> terminated with reason: killed
14:46:29.924 [error] Undefined:Undefined CRASH REPORT Process <0.1199.0> with 0 neighbours exited with reason: killed in gen_server:decode_msg/9 line 432
```
And terminate function of mysql_conn.erl didn't get fully executed.

I have a pool size of 1600, maybe this caused this problem to be obvious.

Because `exit(State#state.supervisor, shutdown)` is async shutdown, the pool process passed away immediately,
so State#state.supervisor gets also killed, 
Now that parent of all workers is dead, so workers show messages pasted above(gen_server:decode_msg/9 line 432), 
So we need to wait a little bit to allow workers to terminate properly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant