mixerclient

package
v0.0.0-...-e3e1183 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddAttributeToGlobalList

func AddAttributeToGlobalList(attr string)

func GlobalList

func GlobalList() []string

func Report

func Report(reportCluster string, attributes *v1.Attributes)

Report attributes to mixer server

Types

type AttributeCompressor

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

AttributeCompressor for compress attributes

func NewAttributeCompressor

func NewAttributeCompressor() *AttributeCompressor

NewAttributeCompressor return AttributeCompressor

func (*AttributeCompressor) Compress

func (a *AttributeCompressor) Compress(attributes *v1.Attributes, pb *v1.CompressedAttributes)

Compress attributes into CompressedAttributes

func (*AttributeCompressor) CreateBatchCompressor

func (a *AttributeCompressor) CreateBatchCompressor() BatchCompressor

CreateBatchCompressor for create BatchCompressor

type BatchCompressor

type BatchCompressor interface {
	// Add an attribute set to the batch
	Add(attributes *v1.Attributes)

	// Finish the batch and create the batched report request
	Finish() *v1.ReportRequest

	// Get the batched size
	Size() int

	// Reset the object data
	Clear()
}

BatchCompressor is attribute batch compressor for report

func NewBatchCompressor

func NewBatchCompressor(globalDict *GlobalDictionary) BatchCompressor

NewBatchCompressor return BatchCompressor

type GlobalDictionary

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

GlobalDictionary store global dictionary

func (*GlobalDictionary) GetIndex

func (g *GlobalDictionary) GetIndex(key string) (index int32, exist bool)

GetIndex return key index

type MixerClient

type MixerClient interface {
	// Report RPC
	Report(attributes *v1.Attributes)

	// SendReport
	SendReport(request *v1.ReportRequest) *v1.ReportResponse
}

MixerClient for communicate with mixer server

func NewMixerClient

func NewMixerClient(reportCluster string) MixerClient

NewMixerClient return MixerClient

Jump to

Keyboard shortcuts

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