store

package
v0.0.132 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2024 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DelayPool

type DelayPool interface {
	Storage
	Delay(deadline time.Duration, fn func()) *DelayTask
}

type DelayPoolImpl

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

func (*DelayPoolImpl) Delay

func (p *DelayPoolImpl) Delay(deadline time.Duration, fn func()) *DelayTask

func (*DelayPoolImpl) Start

func (p *DelayPoolImpl) Start(ctx context.Context) error

func (*DelayPoolImpl) Stop

func (p *DelayPoolImpl) Stop(ctx context.Context)

type DelayTask

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

type HashMapJoinStorage

type HashMapJoinStorage[K comparable] struct {
	// contains filtered or unexported fields
}

func (*HashMapJoinStorage[K]) JoinValue

func (s *HashMapJoinStorage[K]) JoinValue(key K, index int, value interface{}, f JoinValueFunc)

func (*HashMapJoinStorage[K]) Start

func (s *HashMapJoinStorage[K]) Start(ctx context.Context) error

func (*HashMapJoinStorage[K]) Stop

func (s *HashMapJoinStorage[K]) Stop(ctx context.Context)

type Item

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

type JoinStorage

type JoinStorage[K comparable] interface {
	Storage
	JoinValue(key K, index int, value interface{}, f JoinValueFunc)
}

func MakeHashMapJoinStorage

func MakeHashMapJoinStorage[K comparable](m metrics.Metrics, ttl time.Duration, renewTTL bool, streamName string) JoinStorage[K]

func MakeJoinStorage

func MakeJoinStorage[K comparable](m metrics.Metrics, storageType api.JoinStorageType, ttl time.Duration, renewTTL bool, streamName string) JoinStorage[K]

type JoinValueFunc

type JoinValueFunc func(values [][]interface{}) bool

type PriorityQueue

type PriorityQueue []*DelayTask

func (*PriorityQueue) Len

func (pq *PriorityQueue) Len() int

func (*PriorityQueue) Less

func (pq *PriorityQueue) Less(i, j int) bool

func (*PriorityQueue) Pop

func (pq *PriorityQueue) Pop() interface{}

func (*PriorityQueue) Push

func (pq *PriorityQueue) Push(x interface{})

func (*PriorityQueue) Swap

func (pq *PriorityQueue) Swap(i, j int)

type Storage

type Storage interface {
	Start(ctx context.Context) error
	Stop(ctx context.Context)
}

Jump to

Keyboard shortcuts

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