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

History is stored in different partitions on different nodes when using SYSTEM VERSION

    XMLWordPrintable

Details

    Description

      The history is stored in different partitions on different nodes when SYSTEM VERSIONING is enabled in a galera cluster

      Node1

      MariaDB [test]> DROP TABLE t1;CREATE TABLE t1 (x int) WITH SYSTEM VERSIONING PARTITION BY SYSTEM_TIME LIMIT 3 PARTITIONS 5;
      ERROR 1051 (42S02): Unknown table 'test.t1'
      Query OK, 0 rows affected (0.049 sec)
       
      MariaDB [test]>  INSERT INTO t1 VALUES(1);
      Query OK, 1 row affected (0.009 sec)
       
      MariaDB [test]>  INSERT INTO t1 VALUES(2);
      Query OK, 1 row affected (0.019 sec)
       
      MariaDB [test]>  INSERT INTO t1 VALUES(3);
      Query OK, 1 row affected (0.009 sec)
       
      MariaDB [test]>  INSERT INTO t1 VALUES(4);
      Query OK, 1 row affected (0.009 sec)
       
      MariaDB [test]>  INSERT INTO t1 VALUES(5);
      Query OK, 1 row affected (0.014 sec)
       
      MariaDB [test]> delete from t1 where x=1;
      Query OK, 1 row affected (0.014 sec)
       
      MariaDB [test]> delete from t1 where x=2;
      Query OK, 1 row affected (0.023 sec)
       
      MariaDB [test]> delete from t1 where x=3;
      Query OK, 1 row affected (0.018 sec)
       
      MariaDB [test]> delete from t1 where x=4;
      Query OK, 1 row affected (0.015 sec)
       
      MariaDB [test]> delete from t1 where x=5;
      Query OK, 1 row affected (0.010 sec)
       
      MariaDB [test]> SELECT * FROM t1 PARTITION (p0);
      +------+
      | x    |
      +------+
      |    1 |
      |    2 |
      |    3 |
      +------+
      3 rows in set (0.000 sec)
       
      MariaDB [test]> SELECT * FROM t1 PARTITION (p1);
      +------+
      | x    |
      +------+
      |    4 |
      |    5 |
      +------+
      2 rows in set (0.000 sec)
       
      MariaDB [test]> SELECT * FROM t1 PARTITION (p2);
      Empty set (0.000 sec)
      

      Node2

      MariaDB [test]> SELECT * FROM t1 PARTITION (p0);
      +------+
      | x    |
      +------+
      |    1 |
      |    2 |
      |    3 |
      |    4 |
      |    5 |
      +------+
      5 rows in set (0.000 sec)
       
      MariaDB [test]> SELECT * FROM t1 PARTITION (p1);
      Empty set (0.001 sec)
      

      Node3

      MariaDB [test]> SELECT * FROM t1 PARTITION (p0);
      +------+
      | x    |
      +------+
      |    1 |
      |    2 |
      |    3 |
      |    4 |
      |    5 |
      +------+
      5 rows in set (0.000 sec)
       
      MariaDB [test]> SELECT * FROM t1 PARTITION (p1);
      Empty set (0.000 sec)
      

      Attachments

        Issue Links

          Activity

            People

              bnestere Brandon Nesterenko
              susmeet.khaire Susmeet Khaire
              Votes:
              0 Vote for this issue
              Watchers:
              10 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.