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

assert triggered by ./mtr --ps-protocol rpl_mdev382

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 5.5.25
    • 5.5.27
    • None
    • None

    Description

      rpl_mdev382 tests, besides other things, binlogging of implicitly emptied MEMORY tables.

      The assert that fires is here:

      3275 bool Prepared_statement::prepare(const char *packet, uint packet_len)
      3276 {
      ...
      3361     error= check_prepared_statement(this);
      ...
      3372   /* No need to commit statement transaction, it's not started. */
      3373   DBUG_ASSERT(thd->transaction.stmt.is_empty());
      ...

      Indeed, the "statement transaction" is not supposed to be started. But the check_prepared_statement call above opens all tables, and the "implicitly emptied" MEMORY table too, which triggers binlog write, which starts the transaction.

      Besides an assert it might be wrong on other layers too. What if the transaction is rolled back? What if the statement fails and is rolled back? DELETE must still be in binlog, strictly speaking it's not part of the transaction.

      Attachments

        Issue Links

          Activity

            serg Sergei Golubchik created issue -
            serg Sergei Golubchik made changes -
            Field Original Value New Value
            Status Open [ 1 ] In Progress [ 3 ]

            pushed

            serg Sergei Golubchik added a comment - pushed
            serg Sergei Golubchik made changes -
            Resolution Fixed [ 1 ]
            Status In Progress [ 3 ] Closed [ 6 ]
            serg Sergei Golubchik made changes -

            Jira is stupid, or I am: I didn't see how to log time without reopening issue.

            knielsen Kristian Nielsen added a comment - Jira is stupid, or I am: I didn't see how to log time without reopening issue.
            knielsen Kristian Nielsen made changes -
            Assignee Sergei Golubchik [ serg ] Kristian Nielsen [ knielsen ]
            Resolution Fixed [ 1 ]
            Status Closed [ 6 ] Reopened [ 4 ]
            knielsen Kristian Nielsen made changes -
            Resolution Fixed [ 1 ]
            Status Reopened [ 4 ] Closed [ 6 ]
            serg Sergei Golubchik made changes -
            Workflow defaullt [ 14108 ] MariaDB v2 [ 45319 ]
            ratzpo Rasmus Johansson (Inactive) made changes -
            Workflow MariaDB v2 [ 45319 ] MariaDB v3 [ 65982 ]
            serg Sergei Golubchik made changes -
            Workflow MariaDB v3 [ 65982 ] MariaDB v4 [ 144969 ]

            People

              knielsen Kristian Nielsen
              serg Sergei Golubchik
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

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