Symfony. Introducción al componente Messenger (I)

Cómo emplear el componente Messenger para implementar colas de acciones

Image for post
Image for post

Conceptos básicos

Image for post
Image for post
Symfony Messenger
Image for post
Image for post
Symfony Messenger con RabbitMQ

Ejemplo básico

composer require symfony/messenger
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post
Image for post

Symfony Messenger y RabbitMQ

Image for post
Image for post
MESSENGER_DSN = amqp://guest:guest@localhost:5672/%2f/messages
Image for post
Image for post
Image for post
Image for post

Consumiendo mensajes

bin/console messenger:consume-messages
bin/console messenger:consume-messages messenger.default_receiver
Notification sent to foo@mail.comNotification sent to bar@mail.com

¿Quieres recibir más artículos como este?

Entre paseo y paseo con Simba desarrollo en Symfony y React

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store