RPM Community Forums

Mailing List Message of <rpm-devel>

Re: Hierarchical data cache using UUID's

From: Dmitry V. Levin <ldv@altlinux.org>
Date: Wed 14 May 2008 - 01:08:00 CEST
Message-ID: <20080513230759.GC1539@wo.int.altlinux.org>
On Tue, May 13, 2008 at 05:25:36PM -0400, Jeff Johnson wrote:
[...]
> There's a problem with throwing thousands of files into one directory  
> however.
> The fix is what I'm calling "terminfo-like", where all terminfo  
> entries that start
> with 'a' are save as a/a*, etc etc to statistically minimize the  
> number of files
> in each sub-directory.
> 
> Someone, somewhere, has done the implementation I've just described, its
> too obvious and too simple not to have been attempted (my guess).
> 
> So I'm looking for pointers to existing implementations in C.

Something similar, implemented in C:
Git stores objects in filesystem using SHA-1 as a hash.
It uses simple dir/file scheme:
hex presentation of the first byte forms directory name, and hex
presentation of remained 19 bytes forms file name within this
directory, e.g. de/adbeefdeadc0decafef00dbadc0deddeadbeef.


-- 
ldv


  • application/pgp-signature attachment: stored
Received on Wed May 14 01:13:33 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.