Skip to content

threeaccents/pebble

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pebble (Not For Use)

GRPC based cache with a customizable backend. Default is badgerDB.

###Run

./cache --db-dir="path/to/db" --port=":5555"

###Example

package main

import (
	"context"
	"fmt"

	"github.com/oriiolabs/pebble/api"
)

func main() {
	ctx := context.Background()

	c, err := api.NewClient(":4200", nil)
	if err != nil {
		panic(err)
	}

	if err := c.Set(ctx, "hello", []byte("world")); err != nil {
		panic(err)
	}

	value, err := c.Get(ctx, "hello")
	if err != nil {
		panic(err)
	}

	fmt.Printf("value: %s\n", string(value))
}

About

Cache on top of badger DB. With GRPC transport

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages