I have a algorithm to calculate the ranking for posts on a website (uses votes, views, comments and lifespan ). I am going to be using a shared hosting provider, so I am thinking that I would start a thread in the Application_Start method of Global.asax.
Is this the only/best way to do it?
How often should I calculate the ranking? (the result will be stored in the same db table as the post.)
Would you use Thread.Sleep(T) to make the calculation happen every T often?
Why do you need to calculate lifespan?) it can be calculated on the fly from start or end date at UI.
Just in case. For the rest you can use triggers at your DB. Every new post or view or something may update corresponding counter.