mercredi 2 décembre 2015

Fire Event To store prepared Email information to database while using Queue Function

Requirement:

Fire specific event to store email related information in database like to, body etc when email ready to send under queue.

Detail:

Basically, in my current project, i'm developing the campaign module in which user can create campaign and attach multiple target list can be more than one modules with more than 100 records for each module, however it's not limited. And the second portion is, user can create Email marketing with campaign which also can be more than one, totally depend on user. So basically, if total record 500 and email marketing have 3 email to send then total iteration would be 500x3, which definitely i believe can cause the execution time, so I queue these requirement with mail::queue function which not trigger mailer.sending. And secondly, store sent email information to database which would help to user/admin to identify which campaign run, what email sent with what information and email sent time etc etc all kind of information.

So, I'm looking a way to handle such requirement, whenever email ready to send and some event should trigger which can help me to store information in database by catching event with related data.

Except get information about prepared email, what email ready to send using event trigger or something while using mail:queue method, everything else completed and working fine but however any good idea to accomplished such requirement are welcome, on priority looking for get prepared email information which ready to send.



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/21uIm77
via IFTTT

Aucun commentaire:

Enregistrer un commentaire