-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot get current attempt #14
Comments
@korridor Couldn't you setup a dead-letter queue that passed on the dead jobs to another Lambda function that use typed events to locate this specific event type and create the notification? |
Indeed, if your goal is to alert after retrying, using a dead letter queue is the best solution. You can even set up email alerts via SNS without writing code, I documented that on my blog recently: https://mnapoli.fr/sqs-dead-letter-queue-alarm/ |
This is a Laravel thing. In Vapor, they just re-create the job and store the current atempt in the job payload: laravel/framework#35444 |
@mnapoli @danniehansen I could use a dead-letter queue, but this way a few Laravel internal functionalities would not work. For example, as stated here in Laravel documentation the |
See #28 |
Is there any way to find out how often a job already failed, inside the job?
For example: If I configure the queue like in the example with
maxReceiveCount: 3
, I would like to know if the current execution is the first or the last job execution.Especially knowing if it is the last execution is important, because I would like to send a notification to the developers only the last time.
The
failed
function inside of a job would be perfect for that, but as far as I understand this does not work with this package.Is there any solution to this problem or am I missing something?
The text was updated successfully, but these errors were encountered: