Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-23752

SHOW EXPLAIN FOR thd waits for sleep

Details

    • Bug
    • Status: Stalled (View Workflow)
    • Critical
    • Resolution: Unresolved
    • 10.1(EOL), 10.2(EOL), 10.3(EOL), 10.4(EOL), 10.5
    • 10.5
    • OTHER
    • None

    Description

      --source include/not_embedded.inc
       
      --connect (con1,localhost,root,,)
      --let $con_id = `SELECT CONNECTION_ID()`
      --send select sleep(100000);
       
      --connection default
       
      --replace_result $con_id con_id
      eval SHOW EXPLAIN FOR $con_id;
       
      --replace_result $con_id con_id
      eval KILL QUERY $con_id;
      

      Attachments

        Activity

          for 10.6:

          commit dec45aca77ee23557c59411fa9abf037e5343739 (HEAD -> bb-10.6-MDEV-23752-2, origin/bb-10.6-MDEV-23752-2, origin/bb-10.6-MDEV-16440-2)
          Author: Oleksandr Byelkin <sanja@mariadb.com>
          Date:   Fri Sep 18 17:35:08 2020 +0200
           
              MDEV-23752 SHOW EXPLAIN FOR thd waits for sleep
              
              my_apc awake thread after request.
          

          for 10.2 & up (in 10.3 argument TRUE to check_killed() shoud be added)

          commit 3d466b3c9b704e48bdffb9ed84852b9f3720b22b (HEAD -> bb-10.2-MDEV-23752, origin/bb-10.2-MDEV-23752)
          Author: Oleksandr Byelkin <sanja@mariadb.com>
          Date:   Fri Sep 18 09:11:38 2020 +0200
           
              MDEV-23752 SHOW EXPLAIN FOR thd waits for sleep
              
              call check_killed() periodically during sleep()
          

          sanja Oleksandr Byelkin added a comment - for 10.6: commit dec45aca77ee23557c59411fa9abf037e5343739 (HEAD -> bb-10.6-MDEV-23752-2, origin/bb-10.6-MDEV-23752-2, origin/bb-10.6-MDEV-16440-2) Author: Oleksandr Byelkin <sanja@mariadb.com> Date: Fri Sep 18 17:35:08 2020 +0200   MDEV-23752 SHOW EXPLAIN FOR thd waits for sleep my_apc awake thread after request. for 10.2 & up (in 10.3 argument TRUE to check_killed() shoud be added) commit 3d466b3c9b704e48bdffb9ed84852b9f3720b22b (HEAD -> bb-10.2-MDEV-23752, origin/bb-10.2-MDEV-23752) Author: Oleksandr Byelkin <sanja@mariadb.com> Date: Fri Sep 18 09:11:38 2020 +0200   MDEV-23752 SHOW EXPLAIN FOR thd waits for sleep call check_killed() periodically during sleep()

          First pass of review done. Waiting for requested fixes and then will do a new review

          monty Michael Widenius added a comment - First pass of review done. Waiting for requested fixes and then will do a new review

          Although the bug report is still open, there is a test already for it inside mysql-test/t/processlist_notembedded.test, and the test fails fairly frequently in buildbot:

          10.2 5b93a483e41

          main.processlist_notembedded             w4 [ fail ]
                  Test ended at 2021-01-27 15:54:35
           
          CURRENT_TEST: main.processlist_notembedded
          mysqltest: At line 55: query 'SHOW EXPLAIN FOR $con_id' failed: 1933: Target is not running an EXPLAINable command
           
          The result from queries just before the failure was:
          < snip >
          connect  con1,localhost,root,,;
          connection con1;
          SET DEBUG_SYNC= 'before_join_optimize SIGNAL in_sync WAIT_FOR go';
          connection default;
          SET DEBUG_SYNC= 'now WAIT_FOR in_sync';
          FOUND 1 /sleep/ in MDEV-20466.text
          SET DEBUG_SYNC= 'now SIGNAL go';
          connection con1;
          user
          disconnect con1;
          connection default;
          SET DEBUG_SYNC = 'RESET';
          End of 5.5 tests
          #
          # MDEV-23752: SHOW EXPLAIN FOR thd waits for sleep
          #
          connect  con1,localhost,root,,;
          select sleep(100000);;
          connection default;
          SHOW EXPLAIN FOR con_id;
          

          Please fix the test before you close the bug report.

          elenst Elena Stepanova added a comment - Although the bug report is still open, there is a test already for it inside mysql-test/t/processlist_notembedded.test, and the test fails fairly frequently in buildbot: 10.2 5b93a483e41 main.processlist_notembedded w4 [ fail ] Test ended at 2021-01-27 15:54:35   CURRENT_TEST: main.processlist_notembedded mysqltest: At line 55: query 'SHOW EXPLAIN FOR $con_id' failed: 1933: Target is not running an EXPLAINable command   The result from queries just before the failure was: < snip > connect con1,localhost,root,,; connection con1; SET DEBUG_SYNC= 'before_join_optimize SIGNAL in_sync WAIT_FOR go'; connection default; SET DEBUG_SYNC= 'now WAIT_FOR in_sync'; FOUND 1 /sleep/ in MDEV-20466.text SET DEBUG_SYNC= 'now SIGNAL go'; connection con1; user disconnect con1; connection default; SET DEBUG_SYNC = 'RESET'; End of 5.5 tests # # MDEV-23752: SHOW EXPLAIN FOR thd waits for sleep # connect con1,localhost,root,,; select sleep(100000);; connection default; SHOW EXPLAIN FOR con_id; Please fix the test before you close the bug report.

          I made this a blocker as this affects protected branches and thus can stop people from pushing

          monty Michael Widenius added a comment - I made this a blocker as this affects protected branches and thus can stop people from pushing

          ok, I see that at least one of my review requests are in the commit, but not all.

          I also noticed the split of 'awake' is already done in 10.6, so a lot of the changes in the code for dec45aca77ee23557c59411fa9abf037e5343739 has already been done.

          Can you please compare your patch against 10.6 and create a new one?
          Also please test that the above test case really works with 10.6

          monty Michael Widenius added a comment - ok, I see that at least one of my review requests are in the commit, but not all. I also noticed the split of 'awake' is already done in 10.6, so a lot of the changes in the code for dec45aca77ee23557c59411fa9abf037e5343739 has already been done. Can you please compare your patch against 10.6 and create a new one? Also please test that the above test case really works with 10.6

          shoud be f867cca46b47f2ef9170ac9a7130bd3e493b8338 in bb-10.6-MDEV-23752-2

          sanja Oleksandr Byelkin added a comment - shoud be f867cca46b47f2ef9170ac9a7130bd3e493b8338 in bb-10.6- MDEV-23752 -2

          Looks good.
          You can push, but please add the test case and also ensure to enable the test that Elena disabled

          monty Michael Widenius added a comment - Looks good. You can push, but please add the test case and also ensure to enable the test that Elena disabled

          People

            sanja Oleksandr Byelkin
            sanja Oleksandr Byelkin
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.