W3C home > Mailing lists > Public > public-rdf-ruby@w3.org > March 2011

rdf.rb/spira bulk read question

From: Greg Lappen <greg@lapcominc.com>
Date: Wed, 2 Mar 2011 09:20:44 -0500
Message-ID: <AANLkTimTeqMqDNOKp34Jw0D2pQakNq-nEORaeAFCdOT4@mail.gmail.com>
To: public-rdf-ruby@w3.org
Hi all,

We are making good progress with our project, and I've gotten to the point
where I am storing datasets in our rdf repository (rdf.rb based, implemented
on couchdb).  Now I'm building a page that allows the data to be exported in
various formats (xml, csv, etc), but when I iterate over all of the data, it
is extremely slow.  I see Spira querying the repository once for each
instance when I iterate using the model's "each" method.  I understand why,
I'm just wondering if there's a faster way to query all of the instances of
a Spira class.  One thought we had was to use a graph query instead, which
would pull out all the properties in N queries (where N is the number of
properties in the class).  In the example I'm trying, this would be 23
queries, which is better than hundreds or thousands of queries. Is this as
good as it gets?  I'm accustomed to working with RDBMS and ActiveRecord, so
I may just have to shift my expectations a bit, but thought I would ask the
group if there's something I'm missing....thanks as always,

Greg
Received on Wednesday, 2 March 2011 14:21:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 2 March 2011 14:21:37 GMT