[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    caching techniques
From:       "Nathan Bradshaw" <nathanlbradshaw () gmail ! com>
Date:       2008-06-21 19:52:01
Message-ID: 92af7fc70806211252q6d8b4956xb0c479c0e606fc9c () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hi all, I'm working away on the kmusicbrainz library and one of the things I
want to do is create a query cache so that common lookups don't need to
always wait on the network or can be retrieved from cache when the client is
not connected to the net.

The queries themselves are typically either a UUID type string, an artist or
album name or a disc Id string. The results are chunks of XML. Is there a
standard key / value style string caching mechanism in any of the libs or
that could be borrowed from an application?

If not, what approach would anyone suggest to an issue like this? I'd like
to have a few features supported:
1. query aging: after a (configurable) period of time, a known query should
go stale so it can be re queried and the data refreshed
2. Performant for string keys: sadly most of the keys will be strings
(sometimes pretty aribitary ones) so fast string key lookup would be a good
thing (tm)

If I end up writing this from scratch, would a file approach be best or
should I look at using sqllite or similar?

cheers
Nathan

[Attachment #5 (text/html)]

Hi all, I&#39;m working away on the kmusicbrainz library and one of the things I want \
to do is create a query cache so that common lookups don&#39;t need to always wait on \
the network or can be retrieved from cache when the client is not connected to the \
net. <br> <br>The queries themselves are typically either a UUID type string, an \
artist or album name or a disc Id string. The results are chunks of XML. Is there a \
standard key / value style string caching mechanism in any of the libs or that could \
be borrowed from an application?<br> <br>If not, what approach would anyone suggest \
to an issue like this? I&#39;d like to have a few features supported:<br>1. query \
aging: after a (configurable) period of time, a known query should go stale so it can \
be re queried and the data refreshed<br> 2. Performant for string keys: sadly most of \
the keys will be strings (sometimes pretty aribitary ones) so fast string key lookup \
would be a good thing (tm)<br><br>If I end up writing this from scratch, would a file \
approach be best or should I look at using sqllite or similar?<br> \
<br>cheers<br>Nathan<br>



>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic