db

package
v0.0.0-...-4e6bda9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 20, 2018 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package db implements a simple key-value database. The database is cached in memory and mirrored on disk. It is used to store corpus in syz-manager and syz-hub. The database strives to minimize number of disk accesses as they can be slow in virtualized environments (GCE).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB struct {
	Records map[string]Record // in-memory cache, must not be modified directly
	// contains filtered or unexported fields
}

func Open

func Open(filename string) (*DB, error)

func (*DB) Delete

func (db *DB) Delete(key string)

func (*DB) Flush

func (db *DB) Flush() error

func (*DB) Save

func (db *DB) Save(key string, val []byte, seq uint64)

type Record

type Record struct {
	Val []byte
	Seq uint64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL