• Sergei Golubchik's avatar
    MDEV-30084 Shutdown hangs in some tests · 46b79b8c
    Sergei Golubchik authored
    debug-only issue. the test was doing
    
      set debug_sync='now SIGNAL go3';
      ...
      set debug_sync='reset';
    
    which translated into
    
      add "go3" to the hash of active signals
      pthread_broadcast to wake up waiting threads
      ...
      clear the hash of active signals
    
    as a result a waiting thread was awoken, but the hash was emptied
    before the thread checked if its signal was in the hash. so the
    thread didn't find its signal and went back to sleep.
    
    let's wait until the awoken thread has completely finished
    disconnecting and was added to the thread cache.
    46b79b8c
kill_debug.test 8.75 KB