Skip to content

Dox patch release: 30 November 2026

This release is patch versions only. The Postgres and MySQL drivers make the rows of a query result faster, and the ORM uses these rows for its models. Your code needs no change.

Key takeaways

  • Faster models. On our MySQL test, a route that returns 20 model rows does 15% to 39% more requests a second. See Benchmark.
  • Faster plain queries. The rows of query() and of the query builder are faster too, by approximately 8%.
  • Faster JSON columns and text columns. The drivers read simple JSON and ASCII text with less work.
  • Easy to update. Run dart pub upgrade. Then check Read before you update.

Versions

Package New version
dox_postgres_native 3.2.3
dox_mysql_native 3.2.3
dox_orm 3.2.6
dox_migration 3.2.6
dox_cache_database 3.2.6
App template v3.2.8

dox_migration and dox_cache_database have no changes. Their version goes up with dox_orm. The app template only gets the new minimum versions.

No change: all the other packages.

How to update

  1. Get the new versions:

    dart pub upgrade
    
  2. Build or start the app again. The new native libraries download automatically.

  3. Read Read before you update.

There is no API change. You do not need to run build_runner again.

Benchmark

The test is a Dox app with MySQL 8.4. Each request reads 20 rows that have a JSON column, and returns them as JSON. The rig is Linux in Docker on an Apple M2. Each number is a median, in requests a second.

Model rows on 1 core: 39% more requests

A route that reads 20 model rows from MySQL and returns them as JSON.

req/s
Doxthis release 35.9K39% faster
Doxbefore 25.9Kbefore

1 server core · MySQL 8.4 · Linux in Docker on an Apple M2 · median

Model rows on 2 cores: 15% more requests

The same route. On 2 cores, MySQL is the limit.

req/s
Doxthis release 50.8K15% faster
Doxbefore 44.1Kbefore

2 server cores · MySQL 8.4 · Linux in Docker on an Apple M2 · median

Test Before This release Change
20 model rows, 1 server core 25.9K 35.9K +39%
20 model rows, 2 server cores 44.1K 50.8K +15%
20 plain rows of the query builder, 1 server core 25.4K 27.5K +8%

What the numbers do not show

  • On 2 cores, MySQL is the limit. The server gets faster, but the database cannot give more rows. Thus the gain is 15% and not 39%.
  • A route with one row gets little. The gain comes from the rows. A result with many rows gets the most.
  • There is no clean number for Postgres. The Postgres driver has the same changes, but our Postgres runs had too much noise for a number that we can publish.
  • This is one machine. Your numbers will be different.

Why it is faster

Rows share one column index

Before, each row of a result was a full map. For 20 rows with 10 columns, the driver made 20 maps and put each column name in each map.

Now the driver has a row that keeps only a list of its values. All the rows of a result share one index of the column names. The ORM makes its models from these rows, so a model costs less memory and less time.

Plain rows are faster too. query() of the drivers, QueryBuilder.table() and rawQuery() give plain maps, as before. The driver now makes these maps with less work.

JSON columns

A small parser reads simple JSON of 4 kB or less: ASCII text with no escapes, integers, lists, maps, true, false and null. The Dart decoder reads all other JSON, as before. The values are the same as before.

Text columns

ASCII text does not go through the UTF-8 decoder.

JSON parameters

A Map parameter goes to UTF-8 JSON in one step, with no String between. On MySQL, a List parameter does the same.

Read before you update

  • dox_orm 3.2.6 needs the 3.2.3 drivers. dart pub upgrade gets them together.
  • If you override fromMap() of a model and keep the map, keep a copy. On MySQL, MariaDB and Postgres, the map that fromMap() gets is not a LinkedHashMap. Dart cannot send such a map to an isolate of another isolate group.

    final Map<String, dynamic> copy = Map.of(m);
    
  • All other maps are plain maps, as before. Examples are the rows of QueryBuilder.table() and rawQuery(), and originalMap of a model.

  • A driver of your own works as before. The ORM uses the faster rows only with its own MySQL and Postgres drivers.

Full list: the CHANGELOG of each package.