tchannel

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2018 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	// CollectorHostPorts are host:ports of a static list of Jaeger Collectors.
	CollectorHostPorts []string `yaml:"collectorHostPorts"`

	// MinPeers is the min number of servers we want the agent to connect to.
	// If zero, defaults to min(3, number of peers returned by service discovery)
	DiscoveryMinPeers int `yaml:"minPeers"`

	// CollectorServiceName is the name that Jaeger Collector's TChannel server
	// responds to.
	CollectorServiceName string `yaml:"collectorServiceName"`
	// contains filtered or unexported fields
}

Builder Struct to hold configurations

func NewBuilder

func NewBuilder() *Builder

NewBuilder creates a new reporter builder.

func (*Builder) CreateReporter

func (b *Builder) CreateReporter(mFactory metrics.Factory, logger *zap.Logger) (*Reporter, error)

CreateReporter creates the TChannel-based Reporter

func (*Builder) WithChannel

func (b *Builder) WithChannel(c *tchannel.Channel) *Builder

WithChannel sets tchannel channel

func (*Builder) WithCollectorServiceName

func (b *Builder) WithCollectorServiceName(s string) *Builder

WithCollectorServiceName sets collector service name

func (*Builder) WithDiscoverer

func (b *Builder) WithDiscoverer(d discovery.Discoverer) *Builder

WithDiscoverer sets service discovery

func (*Builder) WithDiscoveryNotifier

func (b *Builder) WithDiscoveryNotifier(n discovery.Notifier) *Builder

WithDiscoveryNotifier sets service discovery notifier

type Reporter

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

Reporter forwards received spans to central collector tier over TChannel.

func New

func New(
	collectorServiceName string,
	channel *tchannel.Channel,
	peerListMgr *peerlistmgr.PeerListManager,
	mFactory metrics.Factory,
	zlogger *zap.Logger,
) *Reporter

New creates new TChannel-based Reporter.

func (*Reporter) Channel

func (r *Reporter) Channel() *tchannel.Channel

Channel returns the TChannel used by the reporter.

func (*Reporter) EmitBatch

func (r *Reporter) EmitBatch(batch *jaeger.Batch) error

EmitBatch implements EmitBatch() of Reporter

func (*Reporter) EmitZipkinBatch

func (r *Reporter) EmitZipkinBatch(spans []*zipkincore.Span) error

EmitZipkinBatch implements EmitZipkinBatch() of Reporter

Jump to

Keyboard shortcuts

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