Repository navigation
v1.23.0
The parts of Laravel 13 a growing application reaches for: JSON:API resources, checked byte for byte against a real Laravel 13, Concurrency on warm isolates, Process, vector columns on PostgreSQL and MariaDB, debounced jobs, and automatic eager loading. For a migration: shadow parity compares a moved route with Laravel under real traffic, and LegacyKey makes MAX(id) + 1 safe with parallel writers. Tested beside real Laravel 8 to 13.
Upgrading can change what an application sees:
- A
mariadbconnection now hasSqlDialect.mariadb, notmysql. Code that comparesdialect == .mysqlshould usedialect.isMySqlFamily, and an exhaustiveswitchonSqlDialector onCast, which gainedVectorCast, stops compiling until it names the new case. - A job whose model is gone now fails at once, as in Laravel, instead of using up its tries.
deleteWhenMissingModelsdrops it instead. TransactionCommittedandTransactionRolledBackare now sent. They existed before and never fired, so a listener registered long ago starts to run.
Added
- Transaction events:
DB.listenTransactions, withpoolWaitanddepth, forwarded asTransactionBeginning,TransactionCommittedandTransactionRolledBack, of which the last two existed and were never sent. Pulse counts a transaction's wait for a connection. DaravelUri: Laravel's fluentUri, with PHP's reading and writing of the query.package:daravel/process.dart:Process.run,pipe,poolandfake.Queue.route: where a job type goes, in one place, andwithoutDelay()on a dispatch.deleteWhenMissingModels. A missing model now fails a job at once, as in Laravel, instead of using up its tries.debounceFor,debounceMaxWaitanddebounceId: only the last dispatch of a burst runs.Model.automaticallyEagerLoadandwithRelationshipAutoloading(): the models of a result load their relations together, throughloadandloadMissing, and so do the models those bring in. An N+1 loop becomes one query per relation, and a laterloadstill refreshes.Concurrency:run,defer,runIfLarge,syncandfake, on a pool of warm worker isolates, also aspackage:daravel/concurrency.dart.JsonApiResourceandJsonApiCollection: Laravel 13's JSON:API v1.1 shape, with?fields[type]=and?include=. The kernel awaits a newPreparedResponsable.preparebeforetoResponse, so a route that returns a resource loads what the query asks for.JsonSchema: a typed builder for JSON Schema documents, likeIlluminate\JsonSchema.- Shadow parity:
withUpstream(shadowSampleRate:)replays a sample of theGETandHEADrequests Daravel answers to the upstream, after the response, and reports differences in status, content type and JSON shape to the log andShadowParityDrift. - pgvector:
Blueprint.vector,tsvectorandvectorIndex,Schema.ensureVectorExtensionExists,Cast.vector,whereVectorSimilarTo,whereVectorDistanceLessThan,orderByVectorDistanceandselectVectorDistance. On PostgreSQL and MariaDB 11.7 or newer; MySQL gets the column. MariaDB reads a vector throughselectVector. - Pulse: a Shadow parity drift card, from
ShadowParityDrift. LegacyKey: keys for tables without a sequence, where Laravel code writesMAX(id) + 1, safe with parallel writers on PostgreSQL, MySQL, MariaDB and SQLite.