Bazaar, OLPC, and the "no-packs" repository format.

John Arbash Meinel john at arbash-meinel.com
Thu Dec 20 12:25:38 GMT 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Aaron Bentley wrote:
> Hi all,
> 
> I was talking with Mike Fletcher of the OLPC project yesterday, and he
> was saying there's a good chance that OLPC will promote Bazaar.
> 
> The OLPC laptop is a unique device, and two differences are especially
> important when considering Bazaar:
> 
> 1. Its primary storage is flash memory, so its developers are write-phobic.
> 2. Instead of a conventional filesystem, it has a special file API that
> is backed by an SQLite database
> 
> 1 is a definite negative for Bazaar, since our new pack format does
> rewrites quite frequently.  But 2 works in our favour, for reasons I'll
> explain.
> 

...

> 
> Such a design could be very efficient on OLPC, and because its storage
> is flash-based, data retrieval is very, very fast.
> 
> Aaron

I think this is a good analysis, and certainly something we could do. I
actually think we could do it with existing packs, and just turn off the
autopack functionality (or just set it to run much less often).

We would still need a form of index that could handle this sort of thing,
though. At the moment packs start to perform poorly when you have too many of
them. Because it is bisecting each index looking for the key you requested.

Robert has at least conceptualized a hash-based index, so lookups become more
of an O(1) operation. Which makes it O(N) for N packs, but that is better than
O(N log(M)) for our current indexes. I wonder if you could even combine the
hash maps to make it O(1) across all indexes that you have read...

Alternatively, we could just insert the data into the SQLite DB. I know I
looked into it in the past.  SQLite ended up taking a bit longer to start up,
and created larger files (once you include appropriate indexes). If it is the
native storage format, it seems like you would get some benefits to avoiding
the translation layer.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHal9CJdeBCYSNAAMRAojMAJ4nidHci8PtMfcKdzwzKgzcspnRiACgiMVD
/lOZ3I/R9h85jVPnqIMKD5o=
=TE+e
-----END PGP SIGNATURE-----



More information about the bazaar mailing list