Documentation ¶
Index ¶
- Constants
- func AppendBlockData(ctx context.Context, w backend.Writer, meta *backend.BlockMeta, ...) (backend.AppendTracker, error)
- func BloomName(shard int) string
- func MarshalObjectToWriter(id common.ID, b []byte, w io.Writer) (int, error)
- func NewAppender(writer io.Writer) common.Appender
- func NewBufferedAppender(writer io.Writer, indexDownsample int, totalObjectsEstimate int) common.Appender
- func NewDedupingIterator(iter common.Iterator, combiner common.ObjectCombiner) (common.Iterator, error)
- func NewIndexReader(index []byte) (common.IndexReader, error)
- func NewIterator(reader io.Reader) common.Iterator
- func NewPageReader(r io.ReaderAt) common.PageReader
- func NewPagedFinder(index common.IndexReader, r common.PageReader, combiner common.ObjectCombiner) common.Finder
- func NewPagedIterator(chunkSizeBytes uint32, indexReader common.IndexReader, ...) common.Iterator
- func NewRecordIterator(r []*common.Record, ra io.ReaderAt) common.Iterator
- func WriteBlockData(ctx context.Context, w backend.Writer, meta *backend.BlockMeta, r io.Reader, ...) error
- func WriteBlockMeta(ctx context.Context, w backend.Writer, meta *backend.BlockMeta, ...) error
Constants ¶
const ( // NameObjects names the backend data object NameObjects = "data" // NameIndex names the backend index object NameIndex = "index" )
Variables ¶
This section is empty.
Functions ¶
func AppendBlockData ¶
func AppendBlockData(ctx context.Context, w backend.Writer, meta *backend.BlockMeta, tracker backend.AppendTracker, buffer []byte) (backend.AppendTracker, error)
AppendBlockData appends the bytes passed to the block data
func MarshalObjectToWriter ¶
func NewAppender ¶
NewAppender returns an appender. This appender simply appends new objects
to the provided io.Writer.
func NewBufferedAppender ¶
func NewBufferedAppender(writer io.Writer, indexDownsample int, totalObjectsEstimate int) common.Appender
NewBufferedAppender returns an bufferedAppender. This appender builds a writes to
the provided writer and also builds a downsampled records slice.
func NewDedupingIterator ¶
func NewDedupingIterator(iter common.Iterator, combiner common.ObjectCombiner) (common.Iterator, error)
NewDedupingIterator returns a dedupingIterator. This iterator is used to wrap another
iterator. It will dedupe consecutive objects with the same id using the ObjectCombiner.
func NewIndexReader ¶
func NewIndexReader(index []byte) (common.IndexReader, error)
NewIndexReader returns an index reader for a byte slice of marshalled ordered records.
func NewPageReader ¶
func NewPageReader(r io.ReaderAt) common.PageReader
NewPageReader returns a new v0 pageReader. A v0 pageReader is basically a no-op. It retrieves the requested byte ranges and returns them as is. A pages "format" is a contiguous collection of objects | -- object -- | -- object -- | ...
func NewPagedFinder ¶
func NewPagedFinder(index common.IndexReader, r common.PageReader, combiner common.ObjectCombiner) common.Finder
NewPagedFinder returns a paged. This finder is used for searching
a set of records and returning an object. If a set of consecutive records has matching ids they will be combined using the ObjectCombiner.
func NewPagedIterator ¶
func NewPagedIterator(chunkSizeBytes uint32, indexReader common.IndexReader, pageReader common.PageReader) common.Iterator
NewPagedIterator returns a backendIterator. This iterator is used to iterate
through objects stored in object storage.
func NewRecordIterator ¶
NewRecordIterator returns a recordIterator. This iterator is used for iterating through
a series of objects by reading them one at a time from Records.
Types ¶
This section is empty.