tracer

package
v1.409.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	// contains filtered or unexported fields
}

Cache for tracer.

func NewCache

func NewCache(kind string, tracer trace.Tracer, cache cache.Cache) *Cache

NewCache for tracer.

func (*Cache) Close

func (c *Cache) Close(ctx context.Context) error

Close the cache.

func (*Cache) Get

func (c *Cache) Get(ctx context.Context, key string, value any) error

Get a cached value.

func (*Cache) Persist

func (c *Cache) Persist(ctx context.Context, key string, value any, ttl time.Duration) error

Persist a value with key and TTL.

func (*Cache) Remove

func (c *Cache) Remove(ctx context.Context, key string) error

Remove a cached key.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL