chcollector

package
v0.1.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChCollector added in v0.0.3

type ChCollector struct {
	Log       glog.Logger
	Metrics   metrics.Metrics
	Events    <-chan *fab.BlockEvent
	DataReady chan<- struct{}
	OutData   chan *collectordto.BlockData
	Parser    ChDataParser
	Cancel    context.CancelFunc
	WgLoop    *sync.WaitGroup
}

func NewCollector

func NewCollector(ctx context.Context,
	parser ChDataParser,
	dataReady chan<- struct{},
	events <-chan *fab.BlockEvent,
	bufSize uint,
) (*ChCollector, error)

func (*ChCollector) Close added in v0.0.3

func (cc *ChCollector) Close()

func (*ChCollector) GetData added in v0.0.3

func (cc *ChCollector) GetData() <-chan *collectordto.BlockData

func (*ChCollector) RaiseReadySignal added in v0.0.3

func (cc *ChCollector) RaiseReadySignal()

type ChDataParser

type ChDataParser interface {
	ExtractData(block *common.Block) (*collectordto.BlockData, error)
}

Jump to

Keyboard shortcuts

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