server

package
v0.0.0-...-f164c2a Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2021 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compress

func Compress(value string) ([]byte, error)

func CopyOnWrite

func CopyOnWrite(key string) error

func CopyOnWriteNil

func CopyOnWriteNil(key string) error

func CreateData

func CreateData(key, value string) bool

func CreateShards

func CreateShards()

func CreateSnapshot

func CreateSnapshot() string

func Decompress

func Decompress(compressedValue []byte) (string, error)

func DeleteData

func DeleteData(key string) bool

func GetName

func GetName(key string) string

func GetPath

func GetPath() string

func GetSnapshots

func GetSnapshots() []string

func Hash

func Hash(key string) []byte

func ReadCompressed

func ReadCompressed(key string) ([]byte, error)

func ReadData

func ReadData(key string) (string, error)

func ReadSnapshot

func ReadSnapshot(snapshot, key string) (string, error)

func ServerCreate

func ServerCreate(writer http.ResponseWriter, request *http.Request)

func ServerCreateSnapshot

func ServerCreateSnapshot(writer http.ResponseWriter, request *http.Request)

func ServerDelete

func ServerDelete(writer http.ResponseWriter, request *http.Request)

func ServerRead

func ServerRead(writer http.ResponseWriter, request *http.Request)

func ServerReadSnapshot

func ServerReadSnapshot(writer http.ResponseWriter, request *http.Request)

func ServerUpdate

func ServerUpdate(writer http.ResponseWriter, request *http.Request)

func SetPath

func SetPath(fp string)

func SetShards

func SetShards(num int)

func Shard

func Shard(key string) string

func UpdateData

func UpdateData(key, value string) bool

Types

type Snapshot

type Snapshot struct {
	Snapshot string `json:"snapshot"`
}

type Value

type Value struct {
	Value string `json:"value"`
}

Jump to

Keyboard shortcuts

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