Michael Check wrote: > We need to create an email queue for a system in production. This > sounds like a good way to go. > > For those of you that have created a queue for email, how do you > manage the queue processing? With a separate process, launched at > startup, that wakes up every x interval, like A4D_Housekeeper? > Yes. > Any examples of this type of 4D cron utility that you could point us to? > Basically just run an endless loop that checks for unsent messages at some interval and sends them. When you send messages check for errors. When using 4DIC SMTP commands check for errors. If you encounter them you'll need to try to send again. Various external factors such as the network, or a busy mail server can cause random failures. You can either delete successfully sent messages or leave them for a designated period if you need an audit mechanism.
If you will possibly have this code running on more than one machine, then use a semaphore to ensure that two processes don't process the queue at the same time. HTH, Brad > Thanks, > > Michael Check > Consultant > Solo Group, Inc. > www.sologroup.com > > On Thu, Apr 26, 2007 at 10:40 AM, Aparajita Fishman > <[email protected]> wrote: > >>> We'd also decided not too long ago that we'd add another table for the >>> sole purpose of being the "Sent/Received Mail" box. >>> >> What I did is create a TaskQueue table which is generalized. The info for >> the task is saved in an ObjectTools object which is then saved in a blob in >> the task queue. >> >> Regards, >> >> Aparajita >> www.aparajitaworld.com >> >> "If you dare to fail, you are bound to succeed." >> - Sri Chinmoy | www.srichinmoylibrary.com >> >> >> _______________________________________________ >> Active4D-dev mailing list >> [email protected] >> http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev >> Archives: http://mailman.aparajitaworld.com/archive/active4d-dev/ >> >> > > > > _______________________________________________ Active4D-dev mailing list [email protected] http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev Archives: http://mailman.aparajitaworld.com/archive/active4d-dev/
