I am developing a web application and I seek some suggestion for following scenario.
Our site is a place where buyer and seller talk to each other. buyer comes and put a request for some service. Sellers gets registered to provide some services. When buyer comes and put a request for some service(s), we will store all the data in database and [background process]at the same time seller should be notified for that service via email and couple other things should be done too for that service. [/background process] Actually the problem is not that how can I send email or store data in database? but the thing is , when and where I should start processing the stuff?
If I do it when there is a request for some service from buyer then it would increase the response time for that buyer. I think I should start a thread and do it periodically.