boltdb_storage_service

package
v0.12.1-rc.6 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2022 License: Apache-2.0 Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const DEV_SUB_DIRECTORY = "./buckets/"

Variables

This section is empty.

Functions

func New

func New() (storage.StorageService, error)

New - Create a new BoltDB Storage plugin

Types

type BoltStorageService

type BoltStorageService struct {
	storage.UnimplementedStoragePlugin
	// contains filtered or unexported fields
}

func (*BoltStorageService) Delete

func (s *BoltStorageService) Delete(bucket string, key string) error

Delete - deletes an item from Storage

func (*BoltStorageService) Read

func (s *BoltStorageService) Read(bucket string, key string) ([]byte, error)

Read - reads an item from Storage

func (*BoltStorageService) Write

func (s *BoltStorageService) Write(bucket string, key string, object []byte) error

Write - will create a new item or overwrite an existing item in storage

type Object

type Object struct {
	Key  string `storm:"id"`
	Data []byte
}

Jump to

Keyboard shortcuts

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