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

Performance difference when executing multiple queries in 10.1 vs 10.3 and 10.4

    XMLWordPrintable

Details

    • Bug
    • Status: Confirmed (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.2, 10.3, 10.4
    • 10.4
    • Protocol, Server
    • None
    • Ubuntu 18.04 VM, mariadb-server packages from MariaDB's Debian repository.

    Description

      I have a trivial PHP script using mysqli::multi_query (error handling ommited):

      $queries = "...";
      $db = new mysqli("localhost", $user, $pass, $database);
      $db->multi_query($queries);
      $db->close();

      Here $queries refers to a large number (hundreds) of CREATE TABLE, ALTER TABLE and INSERT queries derived from a database migration system. I can provide them privately if needed.

      When I run this script against MariaDB 10.1, it returns immediately, and a SHOW PROCESSLIST on the MariaDB console shows tables being created after the script has finished running. In other words, it's as if the queries run asynchronously.

      If I upgrade to 10.3 or 10.4, the behavior changes and becomes "synchronous": the script takes minutes to run and only finishes once every query has run.

      Is this a known behavior? Is there a configuration setting that can restore the behavior from 10.1?

      I've tested this on an Ubuntu 18.04 VM with packages installed from MariaDB's APT repositories, using default configurations.

      Attachments

        Activity

          People

            sanja Oleksandr Byelkin
            andrenth Andre Nathan
            Votes:
            0 Vote for this issue
            Watchers:
            4 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.