[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

New snapshot: optional RDF subqueries, improved pagination, 0.6.1 RC1

From: Dmitry Borodaenko
Subject: New snapshot: optional RDF subqueries, improved pagination, 0.6.1 RC1
Date: Sat, 16 Feb 2008 00:04:33 +0200

Greetings everyone!

New snapshot is out, check samizdat package in

Main feature of this snapshot is the new DataSet based pagination
system. See lib/samizdat/engine/dataset.rb for implementation details,
it's no rocket science.

What was rocket science was the long major overhaul of the RDF storage
library that this feature required. To integrate all multi-page
controllers with datasets cleanly, I wanted RDF library to support
optional sub-queries. In order to exclude translations from the
replies list, MessageComponent#messages() used to use a nasty
post-processing of results of a Squish query, which didn't sit well
with DataSet class (which encapsulates a single query and shouldn't
care about how the results are processed after having been fetched).
Now, it's all done with a single query that relates a message to a
Translation focus in an optional part, and then requires that the
optional part doesn't resolve.

To add this functionality, first I had to refactor and prettify the
RDF code so that I can understand it again (yes I was afraid to
approach it because I forgot how it works!). I got rid of most
single-letter variable names, extracted a whole lot of smaller methods
and a whole new SqlMapper class (and created two new utility classes),
the resulting code is 50% larger and also much more modular and
readable. There's still room for improvement, but at least now other
people beside me can figure out how the RDF->SQL query mapping is
supposed to work.

I have also noticed that it's been over a year since our last stable
release, so I've postponed CAPTCHA support until later releases. This
feature seems less urgent now than it was a year ago after the CMS
Survey report, and, with new pagination system in place, this snapshot
can now be a feature-complete release candidate of Samizdat 0.6.1.

So now is the time to test it, and send in translations updates,
one-line bugfixes, and other small and easy stuff. After couple of
weeks and one or two more bugfix releases, Samizdat 0.6.1 will be
released, even if your favorite bug isn't fixed or your favorite
language is missing a few strings.

Here's how to do translations:*checkout*/samizdat/samizdat/doc/translations.txt?revision=1.99

Dmitry Borodaenko

reply via email to

[Prev in Thread] Current Thread [Next in Thread]