# \[SOLVED\] Mautic 5.2.2 switch email sending to doctrine queue problem

**URL:** <https://forum.mautic.org/t/solved-mautic-5-2-2-switch-email-sending-to-doctrine-queue-problem/35064>\
**Category:** Product Support\
**Created:** [February 19, 2025, 1:40pm UTC](https://forum.mautic.org/t/solved-mautic-5-2-2-switch-email-sending-to-doctrine-queue-problem/35064 "2025-02-19T13:40:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![magma](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/magma/32/433_2.png) [@magma](https://forum.mautic.org/u/magma)\
**Post date:** [February 19, 2025, 1:40pm UTC](https://forum.mautic.org/t/solved-mautic-5-2-2-switch-email-sending-to-doctrine-queue-problem/35064/1 "2025-02-19T13:40:26Z")

</div>

**Your software**  
My Mautic version is: 5.2.2  
My PHP version is: 8.3  
My Database type and version is: mariadb-10.6.20

**Your problem**  
My problem is: switching to doctrine queue dosen’t work

These errors are showing in the log:

Steps I have tried to fix the problem:  
According to documentation I switched under Queue setting to:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/8/88775cf56e3c96fcd5b767418b5313d3822d55b0.png)

Send test message give: “Success!”

then I run under console:

```auto
/usr/local/php83/bin/php /home/xxx/mautic/bin/console messenger:consume email -vvv

```

got:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/f/f672fede1fc8426a028f4484d44e3c3cbc16cf87.png)

nothing happen even I force sending from mautic (whether they are broadcats or campaign emails)

and it is strange, because table `messenger_messages` in database is still empty BUT emails are sent.  
I assume there are sent in regular way, not using queue.

My cron run every minute:

```php
php $M_CMD mautic:segments:update
php $M_CMD mautic:campaigns:update.
php $M_CMD mautic:campaigns:rebuild
php $M_CMD mautic:campaigns:trigger
php $M_CMD mautic:broadcasts:send

```

I saw this tutorial:

> **[Configuring Doctrine for Email Queue Management in Mautic with Cron Jobs -...](https://kb.mautic.org/article/configuring-doctrine-for-email-queue-management-in-mautic-with-cron-jobs.html)**
>
> This guide details how to configure Mautic with Doctrine for managing email queues, automate the process with cron jobs, and monitor the system to ensure efficient and reliable email delivery.

And in second point there is modification local.php file but there is different format than I have in version 5.2.2

EDIT:  
I also try to add MESSENGER\_TRANSPORT\_DSN=doctrine://default to .env, clear:cache - nothing changed.

What I should change to send mails by queue?

---

<div class="post-metadata">

**Author:** ![magma](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/magma/32/433_2.png) [@magma](https://forum.mautic.org/u/magma)\
**Post date:** [February 23, 2025, 10:42pm UTC](https://forum.mautic.org/t/solved-mautic-5-2-2-switch-email-sending-to-doctrine-queue-problem/35064/2 "2025-02-23T22:42:40Z")

</div>

When I restart fpm worker for PHP, it start works. Probably part of configuration was stored in cache (i use opcache)
