VB9 and Atom
Don Box: This program is a console app that serves up an ATOM feed containing data about the running processes of the host machine.
The XML/Templating features are cool, but that’s not what I want to talk about, with one exception: it is interesting to note that namespaces declared in the feed do not appear to be available to the entry. This looks like an area where “blue collar” programmers are likely to make mistakes.
Also unrelated to what either of us want to talk about, Process.GetProcesses()
produces a whole series of errors on my machine.
Now, onto what I really wanted to talk about:
- atom:link has a rel attribute, which defaults to “alternate”. In this case, it appears to me that “self” would be more appropriate.
- Similarly, atom:entry elements that contain no child atom:content element MUST contain at least one atom:link element with a rel attribute value of “alternate”.
- on my machine, updated gets values like
5/18/2006 8:47:11 AM
which is the wrong date format and is missing time zone information. Something likeDateTime.Now.ToUniversalTime().ToString("s")+"Z"
would be more appropriate. - of course, assigning new atom:updated times on each request fetch is probably not a good idea.
- not that the above matters any, because you are minting new atom:ids on every request. The spec says that they MUST NOT change.
Recommendation: DO NOT DEPLOY
On a more serious note, any chance you could use your influence to get pluralsight to upgrade your Atom feed from 0.3 to 1.0?