Documentation ¶
Overview ¶
Package bit (Big Immutable Table) provides a way to build a constant hashmap/table, and then use that hashmap without reading/hydrating it into your program's heap.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
Builder is used to construct a big immutable table from key/value pairs.
func NewBuilder ¶
NewBuilder creates a Builder that can be used to construct a Table. Building should happen once, and the table
type Table ¶
type Table struct {
// contains filtered or unexported fields
}
Table represents an on-disk big immutable table. The contents of the table are `mmap(2)`'d into your process's address space, which (1) lets the OS manage keeping hot parts of the table in its LRU-based page cache, and (2) enables you to access big immutable tables whose contents are larger than you have RAM+swap for. It is robust to corruption -- we validate that (a) keys passed to Get exactly match the key in the entry, and (b) the value's checksum matches one we stored at table build time.
Directories ¶
Path | Synopsis |
---|---|
internal
|
|
datafile
Package datafile contains structures for building and reading static mappings from keys to data that may be too big to fit in memory or too expensive to compute on each process start.
|
Package datafile contains structures for building and reading static mappings from keys to data that may be too big to fit in memory or too expensive to compute on each process start. |
exp/mmap
Package mmap provides a way to memory-map a file.
|
Package mmap provides a way to memory-map a file. |
zero
Package zero provides functions to zero slices of specific types.
|
Package zero provides functions to zero slices of specific types. |