RQG Extensions for MariaDB Features

You are viewing an old version of this article. View the current version here.

The components described below can be found in our work tree of the randgen project on Launchpad.

LimitRowsExamined Transformer

The transformer was developed for testing the functionality added in scope of the task MDEV-28: LIMIT ROWS EXAMINED clause to limit the number of rows examined during SELECT processing. It can be used in the usual way, by providing its name in the --transformers list.

The transformer checks whether the original query already contains a ROWS EXAMINED clause. If it does not, it adds the clause either after the LIMIT clause, or at the end of the query. In any case (even if ROWS EXAMINED was already there), the transformer returns the following sequence of statements:

  • FLUSH STATUS
  • <the query with ROWS EXAMINED>
  • <a query which sums up status variables related to examined rows>

The result of the main query is checked to be a subset of the original query's result set. The sum of status variables is checked to be not greater than the limit provided in the ROWS EXAMINED clause, plus a margin. The margin is configured in the transformer.

If the result of the transformed query appears not to be a subset of the original result set, STATUS_LENGTH_MISMATCH is returned.

If the sum of status variables is greater than the maximum allowed value, STATUS_REQUIREMENT_UNMET is returned.

Note: Status values STATUS_REQUIREMENT_UNMET and STATUS_REQUIREMENT_UNMET_SELECT were added to Constants.pm.

SlaveCrashRecovery Reporter

The reporter can be used to test crash-safety of replication, specifically it was created to test MariaDB GTID implementation (MDEV-26), which is expected to make replication of the transactional DML flow crash-safe.

It is a periodic reporter, every 30 seconds it kills the slave server using SIGKILL, and immediately restarts it on the old data directory, with the same parameters as before. On server restart, the reporter checks that the server itself and the replication started all right.

The reporter itself does not check consistency of the data, but it can be used together with ReplicationConsistency reporter.

It is supposed to be used with runall-new.pl, so that the server is started without MTR involvement.

See also:

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.