实时或几乎实时获取 RSS 的最佳方式是什么
我想知道实时获取 RSS 提要的最佳方法是什么,而无需下载整个提要,即使它没有更改。 我并不介意语言,我只是在寻找最好的方法。
I would like to know what's the best way to fetch RSS feeds in real time without having to download the entire feed even when it hasn't been changed.
I don't really mind the language, I'm just looking for the best way to do that.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用
ETag
和If-Modified-Since
标头 HTTP 标头参数。下面是一个示例 python 代码:
该代码可以转换为任何语言,只需添加必要的标头标签并检查返回的代码即可。
更新:查看此博客文章:针对 RSS 黑客的 HTTP 条件 GET
You can use
ETag
andIf-Modified-Since
header HTTP header parameters.Here is a sample python code:
The code can be transferred to any language where you just add the necessary header tags and check the returned code.
UPDATE: Checkout this blog entry: HTTP Conditional GET for RSS Hackers