Release Notes
Readyset is currently released as a docker container and Linux distro binary packages. For installation with docker, see the Install with Docker documentation. Available Linux distribution binary packages for x86_64/amd64 and arm64/aarch64 include deb package for Ubuntu 22.04, Debian 12 and later, and rpm packages for Amazon Linux 2023 and RedHat 9. See package installation instructions.
Highlights
- Lower CPU use on text-protocol queries: Readyset skips rewrite steps a query doesn't need. Initial tests showed 11–18% less Readyset CPU per query.
- Faster replication of bulk UPDATEs and DELETEs.
- Shallow cache mode serves every PostgreSQL database: clients connected to any database on the upstream are served, and the upstream URL no longer has to name a database. Behavior change: outside shallow mode, Readyset now rejects clients that connect to a database other than the one in the upstream URL.
- Better MySQL JSON fidelity: JSON is returned with MySQL's key order and spacing. Upgrading resnapshots all tables. (Community contribution from @floze-the-genius.)
- PostgreSQL
intervalsupport for shallow caches over the extended query protocol. - New metric:
readyset_shallow_shallow_refresh_pool_database_switches.
Detailed Changelog
- 4f733b9: Fixed a bug where a write that interleaved join keys on the right side of a left join could leave a stale or duplicate null-extended row in the cached results.
- 34a3fce: In shallow cache mode, Readyset now serves PostgreSQL clients connected to any database on the upstream, and the upstream URL no longer needs to specify a database. Outside shallow cache mode, Readyset now rejects PostgreSQL clients that connect to a database other than the one specified in the upstream URL. Previously, it served those clients data from the database specified in the URL.
- fb076ab: Added the
readyset_shallow_shallow_refresh_pool_database_switchesmetric, which counts the number of times a shallow refresh worker reconnects to a different upstream database. - 5879b0d: Deep caches now return MySQL JSON columns with the same key order and spacing as MySQL. They also no longer drop updates to rows whose JSON contains a datetime at midnight. Upgrading resnapshots all tables. Thanks to @floze-the-genius for the contribution.
- e4c66a7: Fixed a bug where updates to MySQL rows whose JSON column contained doubles, such as
1e15or1e-7, were not applied to deep caches. - f21f1e0: Sessions with an
intervalstyleother than the defaultpostgresare now served by the upstream database. - f498c3d: PostgreSQL interval values are now supported when shallow caches are accessed over the extended query protocol.
- 3c7d34d: Fixed deep caches on PostgreSQL ordering text columns without an explicit collation differently from the database when its collation is a libc locale, such as
en_us.utf8. - 8969e23: Fixed a bug where prepared statements with bind values in the left operand of an
INexpression could return incorrect results when selecting from a shallow cache. - 32124a9: When a key for an integer column is provided as a string, such as
'30'or'3e1', the string is converted to an integer. Strings containing non-integers, such as'3.5', are no longer converted. - 1079d51: Reads with a literal
LIMITand noORDER BYnow reach a cache created withLIMIT ?. - 18dd3fd: Prepared statements with a literal
LIMITnow reach a cache created withLIMIT ?. - e8a3aac: Converting
CHARtoTEXTorVARCHARin PostgreSQL no longer preserves padding. - 87667af: Readyset now rebuilds all of a failed domain’s indexes when the domain recovers. Previously, the next cache miss could panic with “lookup on non-indexed column set” and cause the domain to fail again.
- b0990f7: Readyset now reports the right-side key of a left join—for example,
r.idinl LEFT JOIN r ON l.a = r.id—with the type and column metadata ofr.id, rather thanl.a. - a0848cd: Fixed PostgreSQL shallow caches serving results keyed to session settings that a rolled-back transaction had reverted, such as a role or
request.jwt.claimsset inside the transaction. - 6e77f60: Fixed until-write shallow caches sending reads upstream for the rest of a transaction after
SAVEPOINTorRELEASE SAVEPOINTover the simple query protocol. - 7f568d0: Fixed PostgreSQL shallow caches serving results keyed to the login user after
RESET ALL, which preserves the role set bySET ROLE. - 9cb198c: Fixed handling of PostgreSQL
SET LOCAL search_path. The setting is now correctly reset after a transaction ends. - b132bdc: Fixed shallow caches over a view serving stale or cross-tenant rows after the view was redefined, its
security_invokersetting changed, or row-level security (RLS) was enabled on an underlying table. - ec84491: Fixed PostgreSQL views not being replicated when a view with the same name exists in another schema.
- b403639: Fixed the undesired recreation, after a restart, of a dropped shallow cache that was created by an older version of Readyset.
- 4584b7b: Fixed a cache over a join that reads a table with duplicate rows returning an extra copy of a row after a replay into the join failed partway through.
- 3bc2c8c: Readyset now returns the correct rows for a cache that filters a window function by a column outside its
PARTITION BYclause. - 8788e03: Fixed PostgreSQL shallow caches serving results keyed to a
search_pathor session variable thatRESET ALLorDISCARD ALLhad reset. - 93443d8: Fixed shallow caches over a view that calls a SQL function reading an RLS-protected table from serving rows across tenants. Queries over views that call volatile functions are no longer cached.
- 10e30bb: Fixed arithmetic on decimal columns in MySQL deep caches returning too few decimal places—for example, rounding
DECIMAL(10,2) + DECIMAL(8,4)to two places—and rounding half to even or to-0. Also fixed PostgreSQL deep caches failing to return an integer added to a numeric value, and comparing a boolean with a string such as'true'as text. - 34924f7: Fixed
GREATESTandLEASTon an integer and a decimal in deep caches returning the wrong value—for example,LEAST(int_col, 0.5)returning1on PostgreSQL. Also fixed MySQLCASE,COALESCE, andIFNULLon decimals rounding to the number of decimal places in one branch, andCASEandIFNULLon an integer and a decimal dropping the connection. - fdb6055: Fixed
ROUND()on a decimal in MySQL deep caches returning trailing zeros, such as2.00instead of2. - 6bdc207: Fixed deep caches writing a decimal as a JSON string instead of a number, as in
JSON_OBJECT('a', d). - 1c85191: Fixed MySQL decimal literals such as
0.1being evaluated as floating-point numbers in deep caches, which caused0.1 + 0.2to return0.30000000000000004instead of0.3. - ec13b5e: Fixed deep caches truncating a string longer than a
VARCHARorCHARcolumn before comparing it. For example,name = 'abcd'could return rows wherenamewas'abc'. - 72a3c40: Fixed deep caches rounding floating-point halves away from zero in casts to integer types and in
ROUND(). For example,2.5became3instead of2. - 2504ee9: Fixed deep cache reads that compare an integer column with an out-of-range value, such as
int_col = 5000000000, failing instead of returning the same rows as the database. - 929d556: Fixed PostgreSQL deep caches returning
1or0instead oftrueorfalsewhen casting a boolean to text. - 385676f: Fixed PostgreSQL deep caches interpreting UUID text differently from PostgreSQL—for example, accepting a
urn:uuid:prefix or rejecting a hyphen after every four digits. - 6d0d22f: Fixed a crash when a prepared statement’s
LIMITorOFFSETwas bound toNULL. Reads with aLIMITorOFFSETbound to a float or string are now sent to the upstream database. - 6bb57b8: Fixed PostgreSQL connections remaining open after the client sent
TERMINATE. - 3960138: Readyset now uses less CPU for queries sent as text by skipping rewrite steps that a query does not need. For example, a point lookup skips the join and subquery steps. Initial tests showed an 11–18% reduction in Readyset CPU per query; actual gains will vary by hardware and workload.
- 3f4945c: Fixed replicated updates and deletes being lost or applied to the wrong row in deep caches when a table’s primary key lists its columns in a different order from the table. This affected PostgreSQL and MySQL with
binlog_row_image=minimal. - 8d41a55: Improved replication throughput for bulk updates and deletes.
- 918e662: Fixed false query sampler mismatches after a sampled query took longer than
sampler_query_timeout_ms. - 7a6c541: Fixed a shallow cache bug that prevented empty PostgreSQL result sets from prepared statements and refreshes from being cached.
- 5cd2061: Fixed MySQL deep caches reporting a smaller column type than MySQL for integer arithmetic and comparisons—for example,
INTfora + bandTINYINTfora = b, when MySQL reportsBIGINT. - f0cb6a5: Fixed MySQL deep caches returning
NULLfor arithmetic on a signed and an unsigned integer, such asa + bwhenais-7andbis an unsigned8. Also fixed missing rows when an unsigned column is compared with a negative number. - 95d5ecd: Fixed MySQL deep caches failing or returning
NULLfor arithmetic on a string column, such asa + vwhenvis aVARCHARcontaining'1.5'. - de2f035: Fixed PostgreSQL deep caches sending values that a client could not read for arithmetic on a
REALand an integer, such asr + i. - 115c11a: Fixed deep caches rounding differently from the database, such as for
ROUND(d, '1')andROUND('3.5')in MySQL. Also fixed PostgreSQL deep caches returningROUND(r)on aREALin a form that clients could not read. - 932c4b1: Fixed PostgreSQL deep caches returning
NULLfromGREATESTorLEASTwhen only some arguments areNULL, or when one argument is a numericNaN.