Documentation ¶
Index ¶
Constants ¶
View Source
const NotFound = "storage: not found"
Variables ¶
This section is empty.
Functions ¶
func AutoMigrateDB ¶
func AutoMigrateDB()
func ConnectCache ¶
func ConnectCache()
Types ¶
type MemoryStorage ¶
type MemoryStorage interface { Get(key string) (string, error) GetInt(key string) (int, error) GetBytes(key string) ([]byte, error) Set(key string, value interface{}, exp time.Duration) error IncrBy(key string, value int64) error Delete(key string) error Reset() error Close() error }
var ( DB *gorm.DB Cache MemoryStorage )
Click to show internal directories.
Click to hide internal directories.