Tuesday, July 21, 2009

SetCronJob Mailer

As said before, SetCronJob is now using GMail as SMTP server to send mails.

When trying to log in, send mail, then quit many times, SetCronJob's mail box was temporarily blocked* by GMail. When I tried logging in with my browser, it required me to enter password as well as captcha (letters in image) before let me in.

A small improvement is re-use the SMTP connection. This helped a little when sending a lot of mails to notify cron jobs nearly expired or unreachable.

After all, I decided to code my own mailer daemon, which will check for new mails, then send them. It will be called every 5 minutes, and send maximum 20 emails once being called.

So, you may see a little (or, a big)  delay time before received messages from SetCronJob.

Let's make a calculation: if there're 100 emails in queue, and once being called, my mailer daemon sends only 20 emails. So, it will send all emails after being called 5 times, or 25 minutes.

So, please patient if you receive nothing after 5 minutes. Late is always better than nothing* :D

Sorry for any inconvenience.

---

* Today, this problem hang my mailer in 3 hours for nothing. Luckily, I'm there, kill it, then apply the 20 mails limitation. Let's see what happen tomorrow, when SetCronJob try to send mail notifying about cron jobs nearly expired.

No comments:

Post a Comment