How to create your Gush RSS feed list - Applied XQuery
By FB2
Monday, February 09, 2004
I've recently came across a new Jabber client called Gush. First of all, please take a look at the screenshots - these may explain my excitement. Surprisingly, the application is written in Python. I think they're using a custom windowing toolkit; at least it's something I can't identify. Let me know if this is based on an existing framework, it looks very cool!
I think the novel approach in Gush is that instead of a Buddy List window, and several conversation windows floating around on my desktop, they have created a "messaging desktop" in the main application window. This main desktop contains the messaging features, chat windows, and the RSS reader. Check out the website for the detailed feature list. One thing that bothers me about this app is that they've created a quite exciting platform, based on the Jabber messaging protocol, and the GUI toolkit, which could be used for many more things. Just by playing with Gush for a few minutes, I've already had a good couple of ideas I'd love to implement within the app itself. The application is closed source, which would not bother me at all, if there'd be a plug-in API or an SDK, or any other way to integrate new modules into the main desktop.
One idea was that I could use something like this to do lightweight task tracking for my projects. I could just IM a task for my project members, which they could discuss with me in the IM window. The task would be automatically added to a task list on their messaging desktop. If they complete the task, the status could be published automatically as a Gush Announcement and I could review the status anytime just by looking at the Group Announcements page.
There could be great potentials if the company would treat this app as a platform, if it's technically possible. Of course if the application is pretty much just hacked together, it might be that extensibility is not an option, but if that's not the case, this could be a lightweight, simple alternative for Groove. I think there are great opportunities for desktop-based messaging-driven collaboration applications and platforms.
Anyway, one of the features I wanted to investigate is the RSS feed support. With Gush, you can subscribe to your favorite news feeds, and it will update them periodically. The interface is integrated with the rest of the messaging features - basically you see an RSS feed the same way as you'd see someone's Announcement page. I did not want to enter my favorite feeds' list manually, so I've looked around in the program directories to see how the subscription list is stored. Luckily it's an XML document, specifically an OPML outline of feeds. Since I'm quite familiar with the way my current reader application stores the feed list, it took me about 2 minutes to create a simple XQuery, to transform the RSS Bandit feed list into the OPML structure.
Here's the XQuery:
declare namespace fd = "http://www.25hoursaday.com/2003/RSSBandit/feeds/"; <opml version="1.0"> <head/> <body> { let $banditDoc := doc('feedlist.xml') for $category in distinct-values($banditDoc//fd:feed/@category) return <outline text="{string($category)}"> {for $feed in $banditDoc//fd:feed where $feed/@category=$category return<outline xmlurl="{string($feed/fd:link)}" text="{string($feed/fd:title)}" type="rss"/> } </outline> } </body> </opml>
I'd recommend Stylus Studio to run this transformation, or get an alternative XQuery engine mentioned in my XQuery article.
It's a pity that I don't have access to the rest of the data store for the application. The settings, contacts, and the stored conversations are persisted in some sort of binary format. For example, it'd be great if I could migrate the contact data stored in my Gaim messenger application. I think I'm spoiled - after seeing how much fun and functionality I can get from some of my applications, just because they store data in an accessible format, I am disappointed if I'm locked out from my own data stores. I will certainly keep Gush, let's hope they open up some sort of API!