spatie / mailcoach-support

Questions and support for Mailcoach
https://mailcoach.app
31 stars 2 forks source link

Campaign never stops "sending" status #208

Closed beberlei closed 4 years ago

beberlei commented 4 years ago

Screenshot_2020-06-05 Campaigns Mailcoach

I cant seem to find out why this "sending" status never goes away. 1 e-mail seems to be unsent, but never gets sent (for days now).

goaround commented 4 years ago

Try to raise the timeout for the send-campaign queue. If the job times out, it will stay like you described it

beberlei commented 4 years ago

@goaround any pointers how that is done? I don't usually use Laravel only for Mailcoach.

goaround commented 4 years ago

In config/horizon.php I created a supervisor just for the queue send-campaign and there you can raise the timeout

Here is my supervisor:

            'mailcoach-send-campaign' => [
                'connection' => 'mailcoach-redis',
                'queue' => ['send-campaign'],
                'balance' => 'auto',
                'minProcesses' => 1,
                'maxProcesses' => 3,
                'tries' => 3,
                'timeout' => 60 * 60,
            ],

Be sure to remove the queue send-campaign from the default mailcoach supervisor

riasvdv commented 4 years ago

@goaround his solution should work! Thanks

@beberlei You could also check Horizon to see what went wrong with the send campaign job. If it's something other than a timeout please open a new issue

beberlei commented 4 years ago

@riasvdv can you explain what "checking horizon" entails? I have no clue

riasvdv commented 4 years ago

You can access horizon at https://your-mailcoach-domain.com/horizon and get information on the queues

beberlei commented 4 years ago

@riasvdv alright, then I think i have the bug. During attempting to send an email it fails, and the failure reason is stored, but that fails with a database column length error:

Screenshot_2020-06-26 Horizon - Failed Jobs