5.16.0 (2026-06-22)
Tools
- Zephir Parser v2.0.4
- Zephir 0.23.0 (development - f87b27ba9)
Changed
- Changed
Phalcon\Support\Debug::getVersion()to return a compact version badge anchor (v<version>) instead of the previous "Phalcon Framework" version block. #17202 [doc] - Changed
Phalcon\Support\DebugandPhalcon\Support\Debug\Dumpto render from named, overridable template strings (the newPhalcon\Contracts\Support\Debug\TemplateAwarecontract withgetTemplate()/setTemplate()) filled bystrtr, instead of inline string concatenation. #17202 [doc] - Changed
Phalcon\Support\Debuginto a thin coordinator that delegates exception-data collection to the newPhalcon\Support\Debug\ReportBuilderand HTML rendering to aPhalcon\Contracts\Support\Debug\Renderer(defaultPhalcon\Support\Debug\Renderer\HtmlRenderer), and exposesgetRenderer()/setRenderer()to swap the renderer. #17202 [doc] - Changed the
Phalcon\Support\DebugMemory panel to report both real and peak memory usage. #17202 [doc] - Changed the
Phalcon\Support\Debugexception page to a redesigned, asset-driven layout (masthead with the Phalcon logo, error card, tabbed Request/Server/Included Files/Memory/Variables context, and collapsible backtrace frames);getCssSources()andgetJsSources()now reference a singledebug.cssanddebug.jsinstead of the bundled jQuery, jQuery-UI and prettify assets. #17202 [doc]
Added
- Added
Phalcon\Support\Debug::getRenderer()andPhalcon\Support\Debug::setRenderer(). #17202 [doc] - Added connection-liveness and opt-in auto-reconnect support to
Phalcon\Db\Adapter\Pdo\AbstractPdo:ping()(aSELECT 1probe),ensureConnection()(reconnect in place when the probe fails), andsetAutoReconnect()/getAutoReconnect()(also settable via theautoReconnectdescriptor key). When auto-reconnect is enabled and a query fails on a lost ("gone away") connection outside a transaction,execute()andquery()fire the newdb:connectionLostevent, reconnect, and retry the statement once; a loss inside a transaction is re-thrown without retry. "Gone away" detection is provided per driver byPhalcon\Db\Adapter\Pdo\Mysql(error codes 2006/2013) andPhalcon\Db\Adapter\Pdo\Postgresql(SQLSTATE 08003/08006/57P01-03), with a message fallback. #17204 [doc] - Added the Beanstalk queue adapter (
Phalcon\Queue\Adapter\Beanstalk\*) over a dependency-free socket client, with native delivery delay and priority and aVisibilityAwareconsumer (touch()). #17051 [doc] - Added the Memory and Stream queue adapters (
Phalcon\Queue\Adapter\Memory\*, in-process FIFO;Phalcon\Queue\Adapter\Stream\*, file-per-queue withflock). #17051 [doc] - Added the Redis queue adapter (
Phalcon\Queue\Adapter\Redis\*) with list-backed FIFO delivery (LPUSH/BRPOP), sorted-set delivery delay and native blocking receive. #17051 [doc] - Added the
Phalcon\Contracts\Support\Debug\TemplateAwareandPhalcon\Contracts\Support\Debug\Renderercontracts, thePhalcon\Support\Debug\ReportBuilderandPhalcon\Support\Debug\Renderer\HtmlRendererclasses, and the value objectsPhalcon\Support\Debug\Report\ExceptionReportandPhalcon\Support\Debug\Report\BacktraceItem. #17202 [doc] - Added the
Phalcon\Queue\AdapterFactoryandPhalcon\Queue\QueueFactoryfactories, and registered thequeueFactoryservice inPhalcon\Di\FactoryDefaultandPhalcon\Di\FactoryDefault\Cli. #17051 [doc] - Added the
Phalcon\Queuecomponent, a first-class queue/messaging layer modeled on the queue-interop contracts, with thePhalcon\Contracts\Queue\*interfaces (ConnectionFactory,Context,Destination,Queue,Topic,Producer,Consumer,SubscriptionConsumer,Message,Processor,VisibilityAware) and thePhalcon\Queue\Exceptions\*hierarchy (QueueThrowable,Exceptionand the typedInvalid*/*NotSupportedExceptionexceptions). #17051 [doc] - Added the queue consumer runner (
Phalcon\Queue\Consumer\QueueConsumer,Worker,WorkerOptions,BoundProcessor,Events) and the CLI consumer taskPhalcon\Queue\Cli\ConsumerTask. #17051 [doc] - Added the same liveness and opt-in auto-reconnect support to
Phalcon\DataMapper\Pdo\Connection(ping(),ensureConnection(),setAutoReconnect()/getAutoReconnect()), wrappingexec(),perform(),prepare(), andquery()with the single-retry behavior. This connection has no events manager, so nodb:connectionLostevent is fired; "gone away" detection is driver-agnostic and the in-transaction guard uses a locally tracked transaction level. #17204 [doc]
Fixed
- Fixed
Phalcon\Mvc\Model::cloneResultMap()calling model setters during ORM hydration unconditionally (introduced in 5.12.0 via #14810), which ran user setters on every record hydrated byfind()/findFirst(); a setter that issued an ORM query (e.g.self::findFirstByEmail()) recursed infinitely, asfindFirst()re-enteredcloneResultMap(), which re-invoked the setter, which calledfindFirst()again. Hydration setters are now gated by a dedicatedorm.call_setters_on_hydrationsetting (defaultfalse), decoupled fromorm.disable_assign_setters(which still governsassign()); this restores the pre-5.12.0 hydration behaviour by default and makes setter execution during hydration opt-in. #17214 [doc] - Fixed
Phalcon\Mvc\Router\Route::compilePattern()andPhalcon\Cli\Router\Route::compilePattern()expanding the:paramsplaceholder - and the built-in/:controller/:action/:paramsand/:task/:action/:paramsdefault routes - to the nested quantifier(/.*)*. The group body overlaps itself, so an unmatchable trailing byte made the compiled pattern backtrack catastrophically: a short crafted URI (a run of/followed by a byte.cannot match) drove thepreg_match()inPhalcon\Mvc\Router::handle()/Phalcon\Cli\Router::handle()into exponential time on every request. The trailing group is now compiled to the equivalent(/.*)?, which captures the sameparamsvalue in linear time. [doc] - Fixed
Phalcon\Support\Debugignoring therequestentry ofsetBlacklist():$_REQUESTis now filtered against therequestblacklist, where previously both superglobals were filtered against theserverblacklist only. #17202 [doc] - Fixed
Phalcon\Tag\Select::selectField()to invoke the resultsetusingrender callback only when it is aClosure(previously any object), keeping the dynamically invoked callable out of reach of user-controlled data. #17210