joist/internal/storage/storage.go
2025-09-06 23:46:27 -04:00

15 lines
342 B
Go

package storage
import (
"context"
"time"
)
type Storer interface {
Close() error
Delete(ctx context.Context, key string) error
Get(ctx context.Context, key string) ([]byte, error)
GetForPrefix(ctx context.Context, prefix string) (map[string][]byte, error)
Put(ctx context.Context, key string, val []byte, ttl time.Duration) error
}