MT-Redland Search Feeds

April 8th, 2005 5:01 AM

With a few code cleanups, and checks to make sure the query returns the appropriate nodes, I’ve got a working version of an RDQL search returning RSS, and using it in an aggregator:

Screenshot of a Movable Type RDQL search returning RSS and being used in an aggregator

I’m not sure what the best way to approach the distribution of this search code is, since it would most likely require a patch to the MT code (which people really wouldn’t like), or re-distributing the MT Search class (which is a violation of the code’s license). I could just replace the method in question, but replacing a 100 line method just to add 2 lines seems like overkill, and would prevent easy upgrades to the MT code. In some areas, Movable Type can be quite extensible, while in others it’s really quite a hassle to cleanly override (like the nearly 600 line edit_object method in the CMS class).

I put version 0.006 online on Wednesday evening, including a README and Changelog. The biggest change was the use of the blogcomments vocabulary for attaching comments to entries (which will show up in the exported RDF).

The other somewhat major change was some code changes that attempt to speed things up when interacting with Redland. The code is really quite slow to use on a regular basis; It’s performing faster than I had initially thought it might (passable, but not quick), but it’s really too slow to be generally acceptable. I test on a dual 1.8GHz G5, so I’m worried that I’m testing on a machine that’s going to be faster than most webservers, but I also have another model in Redland with over five million statements in it, so some of the slowdown might be coming from that. Either way, the new code tentatively requires the Tie::Cache::LRU module.

More later. Enjoy.