tcboltdb

package
v0.0.0-...-6f8fa1e Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2016 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package tcboltdb adapter for the boltdb to use a file based cache.

For more details: https://godoc.org/github.com/boltdb/bolt

Index

Constants

This section is empty.

Variables

View Source
var BucketName = []byte("transcache")

BucketName global bucket name for all entries

Functions

func WithDB

func WithDB(db *bolt.DB) transcache.Option

WithDB uses an existing DB and creates a new bucket from variable name BucketName if that bucket does not exists.

func WithFile

func WithFile(path string, mode os.FileMode, options ...*bolt.Options) transcache.Option

WithFile open creates and opens a bolt database at the given path. If the file does not exist then it will be created automatically. If the third argument Options doesn't get applied bolt.DefaultOptions will be used. Creates a new bucket from variable name BucketName if that bucket does not exists.

Types

This section is empty.

Jump to

Keyboard shortcuts

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