|
| 1 | +CakePHP 5.4.0 Released |
| 2 | +====================== |
| 3 | + |
| 4 | +The CakePHP core team is happy to announce the release of CakePHP 5.4.0. With |
| 5 | +the release of 5.4.0, the 5.1 will no longer receive security fixes. 5.2 will |
| 6 | +continue to receive security fixes until the release of 5.5. |
| 7 | + |
| 8 | +What's new in 5.4.0 |
| 9 | +------------------- |
| 10 | + |
| 11 | +Some highlights of the 5.4.0 release include: |
| 12 | + |
| 13 | +- A backwards compatible container implementation has been added to CakePHP. |
| 14 | +- New methods on ``Collection`` for working with keys, values, conditional |
| 15 | + method chaining, and imploding to a string. |
| 16 | +- New ``Lock`` package for working with distributed locks. |
| 17 | +- Commands now have ``$this->io`` and ``$this->args`` as properties. |
| 18 | +- ``ConsoleHelpHeaderProviderInterface`` lets commands customize help output |
| 19 | + header messages. |
| 20 | +- The ``#[RequestToDto]`` attribute enables automatic mapping of request data to |
| 21 | + Data Transfer Objects. |
| 22 | +- Added ``JsonStreamResponse`` for more memory efficient streaming of large JSON |
| 23 | + responses. |
| 24 | +- Added several new expression builders for null-safe comparisons, and aggregations. |
| 25 | +- Added ``Connection::afterCommit()`` to register callbacks taht run after the |
| 26 | + outermost transaction commits. |
| 27 | +- Additional postgres index metadata reflection and generation support was |
| 28 | + added. |
| 29 | +- ``LoggedQuery::setRedactor()`` was added to scrub sensitive data from query |
| 30 | + logs. |
| 31 | +- Added a PSR-13 Link header implementation. |
| 32 | +- ``Number::toReadableSizes()`` now defaults binary units (KiB = 1024 bytes) |
| 33 | + with ``setUseIecUnits()``. |
| 34 | +- ``I18n::setCacheConfig()`` lets you rename the ``_cake_transalations_`` cache |
| 35 | + profile. |
| 36 | +- ``cake i18 extract`` now extracts labels added with the ``#[Label]`` attribute. |
| 37 | +- The ``associated`` option in ``newEntity()`` and ``patchEntity()`` supports |
| 38 | + the nested array format used by ``contain()``. |
| 39 | +- ``TestCase::mockModel()`` enables mocking of model classes with Mockery. |
| 40 | +- Added new ``Utility\Fs`` classes for scanning and pattern based discovery of directory trees. |
| 41 | +- ``Security::encrypt()`` now supports longer keys with separate encryption and |
| 42 | + authentication keys. |
| 43 | +- ``Text::mask()`` and ``Text::maskValue()`` were added. |
| 44 | +- ``FormHelper::enumOptions()`` was added to make generating form inputs from |
| 45 | + enums easier. |
| 46 | +- The default eager loading strategy for ``HasMany`` and ``BelongsToMany`` |
| 47 | + associations was changed from ``select to subquery``. |
| 48 | +- Table methods for patching, saving, deleting and loading entities now check |
| 49 | + entity class types and reject mismatched entities. |
| 50 | +- ``FormHelper`` now wraps hidden form blocks used for CSRF and tampering |
| 51 | + prevention with ``hidden`` attributes instead of inline styles. |
| 52 | +- ``Application::events()`` and ``Plugin::events()`` are now called consistently |
| 53 | + in both web and CLI contexts, and can use DI container services. |
| 54 | + |
| 55 | +The `migration guide |
| 56 | +<https://book.cakephp.org/5/en/appendices/5-4-migration-guide.html>`_ has |
| 57 | +a complete list of what's new in 5.4.0. We recommend you give that page a read |
| 58 | +when upgrading as it notes the behavior changes present in 5.4.0. |
| 59 | + |
| 60 | +Contributors to 5.4.0 |
| 61 | +--------------------- |
| 62 | + |
| 63 | +Thank you to all the contributors that have contributed to this release: |
| 64 | + |
| 65 | +* Abdul Malik Ikhsan |
| 66 | +* ADmad |
| 67 | +* celsowm |
| 68 | +* gillux |
| 69 | +* Graham Watson |
| 70 | +* Jamison Bryant |
| 71 | +* Jasper Smet |
| 72 | +* Joachim Rey |
| 73 | +* Kevin Pfeifer |
| 74 | +* Mallik Hassan |
| 75 | +* Mark Scherer |
| 76 | +* Mark Story |
| 77 | +* Nicos Panayides |
| 78 | +* othercorey |
| 79 | + |
| 80 | +As always, a huge thanks to all the community members that helped make this |
| 81 | +release happen by reporting issues and sending pull requests. |
| 82 | + |
| 83 | +Download a `packaged release on github |
| 84 | +<https://github.com/cakephp/cakephp/releases>`_. |
| 85 | + |
| 86 | +.. author:: markstory |
| 87 | +.. categories:: news |
| 88 | +.. tags:: release,news |
0 commit comments