blobpacked

package
v0.0.0-...-89f6ccf Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetRecovery

func SetRecovery()

SetRecovery notes that the user ran the camlistored binary with the --recovery flag. It means that any blobpacked storage subsequently initialized will automatically start with rebuilding its meta index of zip files.

func UnsetRecovery

func UnsetRecovery()

See SetRecovery.

func WipeMeta

func WipeMeta(s blobserver.Storage) error

Types

type BlobAndPos

type BlobAndPos struct {
	blob.SizedRef
	Offset int64 `json:"offset"`
}

A BlobAndPos is a blobref, its size, and where it is located within a larger group of bytes.

type Manifest

type Manifest struct {
	// WholeRef is the blobref of the entire file that this zip is
	// either fully or partially describing.  For files under
	// around 16MB, the WholeRef and DataBlobsOrigin will be
	// the same.
	WholeRef blob.Ref `json:"wholeRef"`

	// WholeSize is the number of bytes in the original file being
	// cut up.
	WholeSize int64 `json:"wholeSize"`

	// WholePartIndex is the chunk number (0-based) of this zip file.
	// If a client has 'n' zip files with the same WholeRef whose
	// WholePartIndexes are contiguous (including 0) and the sum of
	// the DataBlobs equals WholeSize, the client has the entire
	// original file.
	WholePartIndex int `json:"wholePartIndex"`

	// DataBlobsOrigin is the blobref of the contents of the first
	// file in the zip pack file. It is the origin of all the logical data
	// blobs referenced in DataBlobs.
	DataBlobsOrigin blob.Ref `json:"dataBlobsOrigin"`

	// DataBlobs describes all the logical blobs that are
	// concatenated together in the first file in the zip file.
	// The offsets are relative to the beginning of that first
	// file, not the beginning of the zip file itself.
	DataBlobs []BlobAndPos `json:"dataBlobs"`
}

Manifest is the JSON description type representing the "camlistore/camlistore-pack-manifest.json" file found in a blobpack zip file.

Jump to

Keyboard shortcuts

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