Reputation: 591
I'm curious as how to monitor a website for it's updates in realtime, preferably in node.js.
Let's take Wikipedia for example. Someone decides to update an article with some relevant information. How would I go about subscribing to the page and instantly getting the event in my node.js server without having to poll the website every X seconds?
Upvotes: 3
Views: 4938
Reputation: 664474
In general, you will need to poll the website if there are no other possibilities like a news feed. You can't force them to provide such a service.
For Wikipedia in detail, there are live update IRC streams, one for each project. Wikistream is such an app that reads the feed, you can view it's open source node.js code at github.
Upvotes: 2
Reputation: 5553
In case you have option to "instruct" the website to notify you, you can create webservice that website will call when it content is updated. But of course, that website should have such option.
Upvotes: 2