openreplay/backend/pkg/sessions/redis.go
Alexander 3b3e95a413
Observability upgrade (#3146)
* feat(metrics): grand update

* feat(metrics): fixed missing part in ee tracer

* feat(assets): added missing arg

* feat(metrics): fixed naming problems
2025-03-13 08:09:29 +01:00

31 lines
672 B
Go

package sessions
import (
"errors"
"openreplay/backend/pkg/db/redis"
"openreplay/backend/pkg/metrics/database"
)
type cacheImpl struct{}
func (c *cacheImpl) SetCache(sessID uint64, data map[string]string) error {
return ErrDisabledCache
}
func (c *cacheImpl) GetCache(sessID uint64) (map[string]string, error) {
return nil, ErrDisabledCache
}
func (c *cacheImpl) Set(session *Session) error {
return ErrDisabledCache
}
func (c *cacheImpl) Get(sessionID uint64) (*Session, error) {
return nil, ErrDisabledCache
}
var ErrDisabledCache = errors.New("cache is disabled")
func NewCache(db *redis.Client, metrics database.Database) Cache {
return &cacheImpl{}
}