News

Mercure Broadcasting in Laravel 13.32

Published
Mercure Broadcasting in Laravel 13.32 image

Release updates

Never miss a Laravel release

Get an email whenever a new Laravel release lands.

The Laravel team released v13.32.0 with a new Mercure broadcast driver, copyToDisk() and moveToDisk() methods on the filesystem, enum support in queue pause and resume, and more:

Mercure Broadcast Driver

Kévin Dunglas contributed a broadcast driver for Mercure, a real-time protocol that runs over SSE instead of WebSockets:

// config/broadcasting.php
'mercure' => [
'driver' => 'mercure',
'url' => env('MERCURE_URL'),
'public_url' => env('MERCURE_PUBLIC_URL'),
'secret' => env('MERCURE_JWT_SECRET'),
'encryption_key' => env('MERCURE_ENCRYPTION_KEY'),
],

With FrankenPHP, the built-in hub needs no url or secret. The driver also supports presence channels and end-to-end encrypted private-encrypted-* channels. A companion Echo patch adds client support.

See #61474 and the broadcasting installer support in #61587 for more details.

Storage copyToDisk() and moveToDisk()

Jack Bayliss contributed copyToDisk() and moveToDisk() to FilesystemAdapter, replacing the manual read-stream-then-write-stream pattern for moving files between disks:

// Copies to the backup disk, retaining the file on the local disk
Storage::disk('local')->copyToDisk('backup', 'reports/report.csv');
 
// Copies to the backup disk, deleting the file from local disk
Storage::disk('local')->moveToDisk('backup', 'reports/report.csv');
 
// Specify a different destination path
Storage::disk('local')->copyToDisk('s3', 'reports/report.csv', '2026/report.csv');

A follow-up PR lets you pass a filesystem instance instead of a disk name.

See #61511 for more details.

Enums in Queue Pause and Resume

Jack Bayliss contributed enum support for Queue::pause(), Queue::resume(), and Queue::pauseFor(), matching the enum support already available on job Queue/Connection attributes and manager methods like route() and forward():

Queue::pause(Queues::notifications, Connections::Redis);
Queue::resume(Queues::notifications, Connections::Redis);
Queue::pauseFor(Queues::notifications, Connections::Redis, 60);

See #61464 for more details.

Release Notes

You can see the complete list of new features and updates below and the diff between 13.31.0 and 13.32.0 on GitHub. The following release notes are directly from the changelog:

v13.32.0

Paul Redmond photo

Staff writer at Laravel News. Full stack web developer and author.

Sponsored

laravelcloud logo
Laravel Cloud

Easily create and manage your servers and deploy your Laravel applications in seconds.

Visit Laravel Cloud

The latest

View all →
Mastering Laravel Testing: A Video Course on Laravel Tests image

Mastering Laravel Testing: A Video Course on Laravel Tests

Read article
NativePHP Mobile Security Advisories: Update to 4.6.1 image

NativePHP Mobile Security Advisories: Update to 4.6.1

Read article
Volker Dusch on the PHP RCE Vulnerabilities and Disclosure image

Volker Dusch on the PHP RCE Vulnerabilities and Disclosure

Read article
Decide with Jev: Turn AI Answers into Decisions with PHP Rules image

Decide with Jev: Turn AI Answers into Decisions with PHP Rules

Read article
Skuul: Open-Source School Management Built on Laravel image

Skuul: Open-Source School Management Built on Laravel

Read article
Laravel Read Replicas: Prevent Stale Reads After a Write image

Laravel Read Replicas: Prevent Stale Reads After a Write

Read article