Solved

Need help to understand how RSS reader works.

Posted on 2007-11-15
6
285 Views
Last Modified: 2013-11-18
I'm new at RSS. I need help to understand how RSS (and RSS reader) works.

Basically I have a JAVA program that runs every 5 minutes and creates an RSS XML file by grabbing data from database and put it into the file.

The RSS XML file looks like what I have in the code snippet:

(1.)
My first question is:
How does an RSS reader work? How does it detect new item from an RSS feed? Does it detect new item based on uniqueID, guid element, or something else?

(2.)
How often does an RSS reader will look for update?

(3.) When generating the RSS feed, it is possible for my RSS feed to have this case below:

Let say at minute 0, there's one item.
item with ID 0 and description element "lalalala"

then at minute 1, there's one more item.
item with ID 1 and description element "lililili"
so now there are two items listed in the file.

then at minute 2, the description element for ID 0 changed to "lolololo"
will RSS reader detect this?

<?xml version="1.0" encoding="ISO-8859-1"?>

<rss version="2.0">

<channel>

<title>Hello World</title>	

<link>.....[this channel ink].....</link>	

<description>.....[description about this channel].....</description>	

.....

<item uniqueID="5623078">

<title>item lalala</title>

<link>.....[link to this data].....</link>	

<description>.....[description about this data].....</description>

<guid isPermaLink="false">5623078</guid>		

<pubDate>Thu, 15 Nov 2007 09:13:42 PST</pubDate>

</item>

.....

......

</channel>

</rss>

Open in new window

0
Comment
Question by:rnicholus
  • 2
  • 2
  • 2
6 Comments
 
LVL 8

Expert Comment

by:Wikkard
ID: 20292947
0
 
LVL 8

Expert Comment

by:Wikkard
ID: 20292967
The RSS reader will download the latest xml file and update its local database with the information in it. And depending on how you have subscribed to the feed it will download the content.
How often it loads the xml file will depend on the different readers.



0
 
LVL 5

Accepted Solution

by:
usarian earned 100 total points
ID: 20293001
(1.)How does an RSS reader work? How does it detect new item from an RSS feed? Does it detect new item based on uniqueID, guid element, or something else?

(A)
Put simply, RSS readers discard the current feed and pulla fresh copy.  They do not universally detect new content.  If you have one that does, it's buffering the old version and comparing it at every refresh.


(2.)
How often does an RSS reader will look for update?

(A)
Usually that is set by the user.  Some feeds once per day is plenty, others once every 10 minutes is good.  Consider: How often do you check for new email messages?

(3.) When generating the RSS feed, it is possible for my RSS feed to have this case below: (bla bla bla)

(A)  An RSS read may or may not detect the change.  It is a feature that a developer can choose to create or not choose to create.

Usarian
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:rnicholus
ID: 20293985
Wikkard,

Thanks for the link. I've seen them before.

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
The RSS reader will download the latest xml file and update its local database with the information in it. And depending on how you have subscribed to the feed it will download the content.
How often it loads the xml file will depend on the different readers.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
So are you saying that any change in the RSS feed will be detected by the RSS reader eventhough it's not a new item? Let say the description element of an old item has changed.
0
 

Author Comment

by:rnicholus
ID: 20294007
usarian,
>>>>>>>>>>>>>>>>>>>>>>>>>>
Put simply, RSS readers discard the current feed and pulla fresh copy.  They do not universally detect new content.  If you have one that does, it's buffering the old version and comparing it at every refresh.
>>>>>>>>>>>>>>>>>>>>>>>>>>
Why do you mean that they do not detect new content? Could you please explain more on this?

>>>>>>>>>>>>>>>>>>>>>>>>>>
An RSS read may or may not detect the change.  It is a feature that a developer can choose to create or not choose to create.
>>>>>>>>>>>>>>>>>>>>>>>>>>
You mean that there's no universal standard to detect new content in RSS feed?

0
 
LVL 5

Assisted Solution

by:usarian
usarian earned 100 total points
ID: 20294652
>You mean that there's no universal standard to detect new content in RSS feed?

Nope.  Not even if that feature exists.
If you know any programming languages, RSS readers are really cool starter projects.  I don't know of any language that isn't capable of creating one.
All you do is download an xml file, organize text in it and display it.  If you know the URL of the XML file itself, you can download it and open it in notepad or Excel.

Alot of websites have these buttons now for specific readers instead of making the RSS feed itself available directly.. that's more difficult to work with.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Preface This article introduces an authentication and authorization system for a website.  It is understood by the author and the project contributors that there is no such thing as a "one size fits all" system.  That being said, there is a certa…
This article covers the basics of the Sass, which is a CSS extension language. You will learn about variables, mixins, and nesting.
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now