Add db to enable stale cache record metdata #105

Open
lash wants to merge 8 commits from lash/stalecache into master
Showing only changes of commit 659fd00c53 - Show all commits

View File

@ -92,11 +92,6 @@ func(tib *TimedDb) Put(ctx context.Context, key []byte, val []byte) error {
return nil return nil
} }
func(tib *TimedDb) Get(ctx context.Context, key []byte) ([]byte, error) {
v, err := tib.Db.Get(ctx, key)
return v, err
}
func(tib *TimedDb) Stale(ctx context.Context, pfx uint8, sessionId string, key []byte) bool { func(tib *TimedDb) Stale(ctx context.Context, pfx uint8, sessionId string, key []byte) bool {
tib.tdb.SetSession("") tib.tdb.SetSession("")
b := db.ToSessionKey(pfx, []byte(sessionId), key) b := db.ToSessionKey(pfx, []byte(sessionId), key)