Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

BladeRunner's avatar

Laravel websockets and queued jobs

I have laravel websockets which broadcast some info needed on front end. On the other hand I have jobs that are run on different servers (workers).

Is this going to work or do i need centralized websockets?

0 likes
2 replies
LaraBABA's avatar

I would believe that if you set your:

window.Echo = new Echo({
    broadcaster: 'pusher',
    key: 'your-pusher-channels-key',
    client: client
});

On each server and push your jobs to your web socket server, it should be able to echo to any places you like as long as you have the key set on the client machines.

BladeRunner's avatar

What is exactly "your-pusher-channels-key". Is that the key I set up in Laravel .env file?

Please or to participate in this conversation.