debugger

package
v1.3.0-rc.3 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2022 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type Cache

type Cache struct {
	KeyTTL      time.Duration // Time after which the data will be expired and removed from the cache
	CleanupFreq time.Duration // This is the time at which a cleaner goroutines  checks whether the data is expired in cache
	Size        int           // This is the size upto which this cache can store a value corresponding to any key
	// contains filtered or unexported fields
}
Cache is an in-memory cache. Each key-value pair stored in this cache have a TTL and one goroutine removes the

key-value pair form the cache which is older than TTL time.

func (*Cache) ReadAndPopData

func (cache *Cache) ReadAndPopData(key string) [][]byte
ReadAndPopData reads the data by taking a string key,

if there is any data available corresponding to the given key then it removes the data from the cache and returns it in the form of []byte

func (*Cache) Update

func (cache *Cache) Update(key string, value []byte)

Update Inserts the data in the cache, This method expects a string as a key and []byte as the data

type Transformer

type Transformer interface {
	Transform(data interface{}) ([]byte, error)
}

type Uploader

type Uploader struct {
	Client sysUtils.HTTPClientI
	// contains filtered or unexported fields
}

func (*Uploader) RecordEvent

func (uploader *Uploader) RecordEvent(data interface{})

RecordEvent is used to put the event batch in the eventBatchChannel, which will be processed by handleEvents.

func (*Uploader) Setup

func (uploader *Uploader) Setup()

func (*Uploader) Start

func (uploader *Uploader) Start()

func (*Uploader) Stop

func (upload *Uploader) Stop()

type UploaderI

type UploaderI interface {
	Start()
	Stop()
	RecordEvent(data interface{})
}

func New

func New(url string, transformer Transformer) UploaderI

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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