ringbuffer

package
v3.0.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2019 License: Apache-2.0 Imports: 5 Imported by: 10

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RingBuffer

type RingBuffer struct {
	// Channel used to store trace segment received on X-Ray daemon address.
	Channel <-chan *tracesegment.TraceSegment

	// Boolean, set to true of buffer is empty
	Empty bool
	// contains filtered or unexported fields
}

RingBuffer is used to store trace segment received on X-Ray daemon address.

func New

func New(size int, pool *bufferpool.BufferPool) *RingBuffer

New returns new instance of RingBuffer configured with BufferPool pool.

func (*RingBuffer) Close

func (r *RingBuffer) Close()

Close closes the RingBuffer.

func (*RingBuffer) Send

func (r *RingBuffer) Send(s *tracesegment.TraceSegment)

Send sends trace segment s to trace segment channel.

func (*RingBuffer) TruncatedCount

func (r *RingBuffer) TruncatedCount() uint64

TruncatedCount returns trace segment truncated count.

Jump to

Keyboard shortcuts

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