I am developing an app that allows users to post to rooms/pages, much like a forum or here (stackoverflow). I have already built out the entire app, however, I have one last obstacle to climb: How to handle updating posts for a user.
I have done alot of research into the topic, and I believe Long Polling is the way to go, at least until I get an immense amount of traffic (if that happens, I'll figure out how to implement websockets). This is because Long Polling will be easier to implement, it is more widely supported, and given that I am deploying to heroku it will be easy to upgrade my server resources quickly. Anyway, I wanted to know what the best practices are of long polling, both in terms of user interaction, and server load.
Should I automatically place posts on the page, or create an alert system such as the one here on stackoverflow?
Any and all input would be appreciated. If you think my logic is wrong in anyway, please tell me!
For a system like this we suggest using something like pusher. Check out the documentation for more details as to how to do it. https://devcenter.heroku.com/articles/pusher
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With