Problem/Motivation
When records with dud emails like john@gmail or john@localhost are in the queue these records keeps on clogging it.
It would be great to set an option where the user can assign a retry amount.
Proposed resolution
Instead of just using an exception, which causes drupal to try again; We can Add $message[fail_count]
Add logic if fail count matches we skip that from creating a record at record _queue_mail_get_queue()->createItem($message);
Remaining tasks
Review patch
User interface changes
Could add a field to set retry limit
API changes
none
Data model changes
none
| Comment | File | Size | Author |
|---|---|---|---|
| #14 | 3000104-14.patch | 4.5 KB | larowlan |
| #14 | 3000104-14.interdiff.txt | 1.55 KB | larowlan |
| #12 | 3000104-retry-limit-pacth-11.patch | 4.42 KB | pasan.gamage |
Comments
Comment #2
pasan.gamage commentedComment #3
larowlantypo: threshold
should use [] short array syntax
this comment is kind of off.
Suggest:
Prevent retrying until specified interval has elapsed
out of scope change?
Could use a comment here.
Something like:
Add back to the queue with an updated fail count.
no need for a break here, it will throw out the log
use short array syntax here (I realise the module does not, but we shouldn't introduce new issues)
Comment #4
pasan.gamage commentedIncluded a patch with
- Adds post update for existing users.
- Code review fixes
Comment #5
pasan.gamage commentedComment #6
larowlanThis should just be 'Contains post update hooks for the module'
The module is named queue_mail, so this won't work - remove the `er` from the function name
Comment #7
pasan.gamage commentedComment #8
pasan.gamage commentedComment #9
larowlanThis looks good to me, thanks @pasan.gamage
Comment #10
pasan.gamage commentedThanks @larowlan for pointing out the operator bug :)
Attached is the fix.
Comment #11
larowlanrequeue will keep it at the top of the queue.
We need
instead
Comment #12
pasan.gamage commentedComment #13
pasan.gamage commentedComment #14
larowlanComment #16
sinn commentedComment #17
larowlanthanks!
Comment #19
larowlanIs there a chance of a new release containing this?