telemetrysender

package
v0.0.0-...-ce7efba Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Anonymize

func Anonymize(str string) string

func CredentialsOperatorRunActiveReporter

func CredentialsOperatorRunActiveReporter(ctx context.Context)

func IncrementUniqueCounterCredentialsOperator

func IncrementUniqueCounterCredentialsOperator(eventType telemetriesgql.EventType, key string)

func IncrementUniqueCounterIntentOperator

func IncrementUniqueCounterIntentOperator(eventType telemetriesgql.EventType, key string)

func IncrementUniqueCounterNetworkMapper

func IncrementUniqueCounterNetworkMapper(eventType telemetriesgql.EventType, key string)

func IntentsOperatorRunActiveReporter

func IntentsOperatorRunActiveReporter(ctx context.Context)

func NetworkMapperRunActiveReporter

func NetworkMapperRunActiveReporter(ctx context.Context)

func SendCredentialsOperator

func SendCredentialsOperator(eventType telemetriesgql.EventType, count int)

func SendIntentOperator

func SendIntentOperator(eventType telemetriesgql.EventType, count int)

func SendNetworkMapper

func SendNetworkMapper(eventType telemetriesgql.EventType, count int)

Types

type CountersByEvent

type CountersByEvent map[UniqueEventMetadata]sets.Set[string]

type TelemetrySender

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

func New

func New() *TelemetrySender

func (*TelemetrySender) HandleCounters

func (t *TelemetrySender) HandleCounters(batch []UniqueEvent) error

func (*TelemetrySender) IncrementCounter

func (t *TelemetrySender) IncrementCounter(component telemetriesgql.Component, eventType telemetriesgql.EventType, key string) error

func (*TelemetrySender) Send

func (t *TelemetrySender) Send(component telemetriesgql.Component, eventType telemetriesgql.EventType, count int) error

type UniqueCounter

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

func NewUniqueCounter

func NewUniqueCounter() *UniqueCounter

func (*UniqueCounter) Get

func (s *UniqueCounter) Get() []UniqueEventCount

func (*UniqueCounter) IncrementCounter

func (s *UniqueCounter) IncrementCounter(component telemetriesgql.Component, eventType telemetriesgql.EventType, eventKey string)

func (*UniqueCounter) Reset

func (s *UniqueCounter) Reset()

type UniqueEvent

type UniqueEvent struct {
	Event UniqueEventMetadata
	Key   string
}

type UniqueEventCount

type UniqueEventCount struct {
	Event UniqueEventMetadata
	Count int
}

type UniqueEventMetadata

type UniqueEventMetadata struct {
	Component telemetriesgql.Component
	EventType telemetriesgql.EventType
}

Jump to

Keyboard shortcuts

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