Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SequencerContainer ¶
type SequencerContainer struct {
InChan chan *jsonblock.JsonBlockEssential
// contains filtered or unexported fields
}
func NewSequencerContainer ¶
func NewSequencerContainer(firstOut int64, bloatedCount int, outChan *chan *jsonblock.JsonBlockEssential) *SequencerContainer
NewSequencerContainer creates a SequenceContainer Objects are sent in to SequenceContainer.InChan in a pseudo-sequence. Objects come out of outChan in strict sequence order. The intention is to place this in a pipeline after a thread pool which may have disrupted the original sequence. To compensate for bloating, at a point upstream where things ARE still in sequence, you should call SequencerContainer.WaitForNotBloated() before sending objects to your thread pool.
func (*SequencerContainer) WaitForNotBloated ¶
func (sc *SequencerContainer) WaitForNotBloated()
type SequencerContainerHashes ¶
type SequencerContainerHashes struct {
InChan chan *jsonblock.JsonBlockHashes
// contains filtered or unexported fields
}
func NewSequencerContainerHashes ¶
func NewSequencerContainerHashes(firstOut int64, bloatedCount int, outChan *chan *jsonblock.JsonBlockHashes) *SequencerContainerHashes
NewSequencerContainer creates a SequenceContainer Objects are sent in to SequenceContainer.InChan in a pseudo-sequence. Objects come out of outChan in strict sequence order. The intention is to place this in a pipeline after a thread pool which may have disrupted the original sequence. To compensate for bloating, at a point upstream where things ARE still in sequence, you should call SequencerContainer.WaitForNotBloated() before sending objects to your thread pool.
func (*SequencerContainerHashes) WaitForNotBloated ¶
func (sc *SequencerContainerHashes) WaitForNotBloated()
type WorkerPool ¶
type WorkerPool struct {
InChan chan Task
}
func NewWorkerPool ¶
func NewWorkerPool(concurrency int) *WorkerPool