Skip to content

Backoff queue parameter doesnt work in email #55416

@Arthedian

Description

@Arthedian

Laravel Version

11.44.2

PHP Version

8.2.28

Database Driver & Version

No response

Description

I am trying to send an email through queue, which is working fine. I am trying to set tries (and other) queue parameter in my email class, which doesn't work. The job just fail and doesn't repeat after failing. If I run the worker with proper parameters, than everything is fine php artisan queue:work -v --tries=5

Steps To Reproduce

If I have a Mail class such as this, than the tries function value is not respected

<?php

class BaseMail extends Mailable
{
    use Queueable;
    ...
    public function __construct()
    {
        $this->onQueue('low');
    }

    ....

    public function tries(): int
    {
        return 5;
    }
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions