Home
Softono

Go Cache

Open source Apache-2.0 Go
150
Stars
11
Forks
2
Issues
8
Watchers
3 years
Last Commit

 About Go Cache

This project encapsulates multiple db servers, redis、ledis、memcache、file、memory、nosql、postgresql

Platforms

Web Self-hosted

Languages

Go

Links

Need Help Installing Go Cache?

We provide expert installation service for this software. Our team will install, configure, and secure Go Cache on your server. plans start at just $30.

go-cache

This project encapsulates multiple db servers, redis、ledis、memcache、file、memory、nosql、postgresql

example

package main

import (
	"github.com/huntsman-li/go-cache"
	_ "github.com/huntsman-li/go-cache/redis"
)

func main() {
	ca, err := cache.Cacher(cache.Options{
		Adapter:       "redis",
		AdapterConfig: "addr=127.0.0.1:6379",
		OccupyMode:    true,
	})

	if err != nil {
		panic(err)
	}

	ca.Put("liyan", "cache", 60)
}