Reputation: 2078
I have developed a chat application and now I want to update the status of my buddies (my friends list) with the message online or offline based on their status. How frequent I should update status of user to the db and how frequent my client application should check for their status ?
Upvotes: 0
Views: 1661
Reputation: 1901
Are you sure you want to update the status at regular intervals? Depending on your server side, you can find a solution that will not poll the server, and notify the client. In any case, the implementation long polling pattern will positively affect the performance of your application. I had server side on PHP and use control WebBrowser in my WP App to subscribe to status updates, etc.. The client code was written in Java Script and it works fine. But there are more interesting solutions, I advise you to read about the library http://signalr.net/.
Upvotes: 1