Emails getting queued up when sent from the server - Auto email function is used with task scheduler.

Hi,
     From our hotel management software we have set up emails to go automatically using the task scheduler.  We use a function to send the mail  and we update that in the schedular. Usually all the emails go through at 11 pm instantly. Now the the mail is getting queued up in the function and the emails  go one by one  and at some point, hundreds of email goes to just one email id. And since it goes slowly and crosses 12 am, the email scheduled for next day comes into account.  We recently did a database merging from 11 databases in to one. We doubt if it has got to do anything with this issue . We send email via SMTP from our server. we have check the exe code and find no issue.  Please provide your inputs on what could be the issue. I have attched the auto email code with this.

Regards
AutoEmail-code.png
gracesoftAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Gautham JanardhanCommented:
Why not send more than one mail in parallel? Have a few threads taking say x records each and send email so that the process runs faster and finishes before 12
0
Scott Fell, EE MVEDeveloper & EE ModeratorCommented:
Personally, I found trying to manage smtp on my own server for things like this problematic and in part for this reason.  I ended up using a 3rd party smtp service.  I have used both sendgrid and mandrill. Both are very good services and you can get all the reporting and api's for opens and bounces etc.   But you can send out many emails at once and put the throttling on their end.  

While these solutions have a small price, it is well worth it.  100,000 monthly emails will cost $20 to $25 per month without a dedicated IP.

http://mandrill.com/
https://sendgrid.com/
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
gracesoftAuthor Commented:
Thanks Gautham. we will try that.  And thanks Scott for the suggestion.
0
Big MontySenior Web Developer / CEO of ExchangeTree.org Commented:
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.