| Project: | E-mail Marketing Framework |
| Version: | 6.x-6.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | needs work |
Issue Summary
There are options for sync to run Never, on cron run, and by minute maximums (which the minimum possible time is never less than your cron frequency), but there is no option for the sync to run Immediately upon any subscription/unsubscription added to the request queue.
This option would be a valuable one for pushing subscription/unsubscription requests right away, as I would like people who subscribe to my list to get an email nearly immediately instead of waiting for the next time cron is run. You risk losing a customer if they ask for info and don't get it within a few minutes of them asking for it.
I do understand that if I ran cron every minute, I could essentially have an immediate subscription, but I also don't think that running cron every minute really makes sense because it does a lot of other stuff too that may cause too much load on the server. Its more common for cron to run per hour on a busy site.
So in the interest of allowing subscription/unsubscription to happen immediately, and to separate that dependence on the frequency of cron, I'd like to suggest that we add an Immediate option to the Requests Synchronizations interval list on the Advanced Options page. Would this be of interest to anyone?
Jeremy Zerr
http://www.zerrtech.com
Comments
#1
For now, I'm going to mark this as "by design". Pushing the requests out as soon they happen, might have issues when the service is down or an error occurs.
#2
I can agree with you about that. How about that when an Immediate sync option is selected, it also fires on every cron in addition to firing on subscribe/unsubscribe immediately?
#3
If you have a suggestion to implement this, I'm open for it ;)
#4
See attached patch.
Added a new "Immediate and on every cron" option to the Requests synchronisation interval setting.
Added associated logic to check for the immediate sync option everywhere that a subscribe/unsubscribe request is generated from, which includes the subscribe/unsubscribe Actions, the subscription form, and the user hook when a user is deleted.
Please let me know any feedback you have, and I can test and gen a new patch. Also sorry about the "No newline at end of file" showing up in the patch. Not entirely sure what that is from, I'm editing in vi on linux...
Jeremy Zerr
http://www.zerrtech.com
#5
oops, forgot to move this to needs review...
#6
You also might want to look into Elysia Cron, which enables you to set different cron tasks on different schedules. That way you could run the EMF cron every minute if you wanted to, while setting less frequent intervals for search indexing, etc.
#7
I'm not sure if we need this. I think more frequent cron runs could fix this.
If you still want to work on this, I'd advice you to skip the request table all together. Right now, you're saving a request to immediately remove it.
#8
I think immediate push option makes a lot of sense, especially in cases where a list is double opt-in, and you want the email to go out immediately.