MCPcopy
hub / github.com/uselotus/lotus / Set

Method Set

go/event-ingestion/cache/cache.go:37–45  ·  view source on GitHub ↗
(key string, value interface{}, expiration *time.Duration)

Source from the content-addressed store, hash-verified

35}
36
37func (c *RedisCache) Set(key string, value interface{}, expiration *time.Duration) error {
38 var realExpiration time.Duration
39 if expiration == nil {
40 realExpiration = c.defaultExpiration
41 } else {
42 realExpiration = *expiration
43 }
44 return c.rdb.Set(ctx, key, value, realExpiration).Err()
45}
46
47func New(config config.Config) (Cache, error) {
48

Callers

nothing calls this directly

Calls 1

SetMethod · 0.65

Tested by

no test coverage detected