| VENTI(2) | System Calls Manual | VENTI(2) |
Venti - access to Venti content-addressed filestore.
include "venti.m";
venti := load Venti Venti->PATH;
Session: import venti;
init: fn();
Session: adt {
new: fn(fd: ref Sys->FD): ref Session;
read: fn(s: self ref Session, score: Venti->Score, etype: int, maxn: int): array of byte;
write: fn(s: self ref Session, etype: int, buf: array of byte): (int, Venti->Score);
sync: fn(s: self ref Session): int;
};
Score: adt {
a: array of byte;
eq: fn(a: self Score, b: Score): int;
text: fn(a: self Score): string;
parse: fn(s: string): (int, Score);
zero: fn(): Score;
};
Venti is a block storage server intended for archival applications. The Venti module provides low-level access to a Venti server. The module assumes that the physical connection to the server has already been established (for example, by dial (2)). On a Venti server, a block is addressed by the SHA1 hash of the contents of that block, known as a score, and represented as a Score adt. Blocks are additionally tagged with a type, facilitating recovery in the event of corruption. A Session represents a session with a Venti server.
/module/venti.m
/appl/lib/venti.b