PS-311: On server shutdown threadpool is crashing in debug mode due #18
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
to race condition
This patch was ported from 5.7. The original commit message from 5.7
reads:
"Moved calling set_my_sys_thread_var before signaling conditional
variable THR_COND_threads. This is variable on which my_thread_global_end is
waiting. After it is signalled THR_KEY_mysys_initialized is set to FALSE in
my_thread_global_end. There is a debug assertion that THE_KEY_mysys_initialized == TRUE in
set_my_sys_thread_var.
Moved my_init_signals, which sets signal mask to block all
handleable kill signals - which are later serviced by signal_hand thread. my_init_singals
was moved before PFS initialization. PFS thread can be affected by
"handleable kill" signals unless they have singal mask set.
Only second part of this patch is ported from 5.7.
The first part is no longer valid as the debug assertion
THE_KEY_mysys_initialized == TRUE was removed.