[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: random access delta streams

From: Jim Blandy <jimb_at_zwingli.cygnus.com>
Date: 2000-11-14 16:21:20 CET

> It should be possible, i guess. Right now, our delta format doesn't
> allow such random-access applying of deltas simply because the windows
> aren't indexed. You'd have to store a window lookup table with the
> delta in order to convert seek offsets appropriate windows.

Yep. Just on the techno-wanking side, I was thinking of a
hierarchical index: after every tenth window, store a little table of
pointers to the windows. After every tenth little table, store a
little table of pointers to little tables of pointers to windows.
After every tenth... you see what I mean. Then you can start at the
end of the file and find any window in logarithmic time. That
procedure always emits balanced trees. Use 100 instead of ten, and
your tree has 1/100th the number of nodes as your file has windows,
and is very shallow.

You're right that locality is a big concern --- I wonder how much
locality this will have.

> I'm wondering, though: when would you want to put such a large file
> under revision control? Typically it'll be a database, which has
> its own consistency and versioning mechanism, or a media file
> (e.g., video), which is streamy by nature. I'm not saying it doesn't
> make sense to store large files, I only think that the applications
> for that are relatively few.
>
> Another question: when do you need random access to old versions?
> And if you do, wouldn't it make more sense to store them in the
> clear, anyway, without having to apply a series of deltas every
> time? That's what any caching scheme will boil down to, anyway.

Greg S. asked some mild questions, and I'm inferring from there.
The thought arose from the intersection of these issues:
- Subversion wants to use deltas to store multiple versions of files
  in a compact way.
- Subversion wants to provide a uniform interface for accessing both
  old and new versions of nodes.
- HTTP or DAV has some way to ask about substrings of files.

I have no compelling application in mind; I'm just trying to meet all
the promises we're making.
Received on Sat Oct 21 14:36:14 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.