kafka

package
v0.0.0-...-523a819 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2019 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IncomingByteRateName  = "incoming-byte-rate-for-broker-"
	OutgoingByteRateName  = "outgoing-byte-rate-for-broker-"
	RequestRateName       = "request-rate-for-broker-"
	RequestSizeName       = "request-size-for-broker-"
	RequestLatencyName    = "request-latency-in-ms-for-broker-"
	ResponseRateName      = "response-rate-for-broker-"
	ResponseSizeName      = "response-size-for-broker-"
	BatchSizeName         = "batch-size-for-topic-"
	RecordSendRateName    = "record-send-rate-for-topic-"
	RecordsPerRequestName = "records-per-request-for-topic-"
	CompressionRatioName  = "compression-ratio-for-topic-"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Metrics

type Metrics struct {
	IncomingByteRate  metrics.Gauge
	OutgoingByteRate  metrics.Gauge
	RequestRate       metrics.Gauge
	RequestSize       metrics.Gauge
	RequestLatency    metrics.Gauge
	ResponseRate      metrics.Gauge
	ResponseSize      metrics.Gauge
	BatchSize         metrics.Gauge
	RecordSendRate    metrics.Gauge
	RecordsPerRequest metrics.Gauge
	CompressionRatio  metrics.Gauge

	GoMetricsRegistry gometrics.Registry
}

func New

func New(config localconfig.Kafka, metricsProvider metrics.Provider) (consensus.Consenter, *Metrics)

New创建了一个基于Kafka的同意者。由订购方的main.go调用。

func NewMetrics

func NewMetrics(p metrics.Provider, registry gometrics.Registry) *Metrics

func (*Metrics) PollGoMetrics

func (m *Metrics) PollGoMetrics()

Pollgometrics从Go度量中获取当前度量值并将其发布到 通过Go Kit的度量标准暴露的仪表。

func (*Metrics) PollGoMetricsUntilStop

func (m *Metrics) PollGoMetricsUntilStop(frequency time.Duration, stopChannel <-chan struct{})

pollgometricsuntilstop通常应在专用的go例程上调用。这个例行程序 然后以指定的频率调用pollgometrics,直到stopChannel关闭。

Directories

Path Synopsis
此源码被清华学神尹成大魔王专业翻译分析并修改 尹成QQ77025077 尹成微信18510341407 尹成所在QQ群721929980 尹成邮箱 yinc13@mails.tsinghua.edu.cn 尹成毕业于清华大学,微软区块链领域全球最有价值专家 https://mvp.microsoft.com/zh-cn/PublicProfile/4033620 伪造者生成的代码。
此源码被清华学神尹成大魔王专业翻译分析并修改 尹成QQ77025077 尹成微信18510341407 尹成所在QQ群721929980 尹成邮箱 yinc13@mails.tsinghua.edu.cn 尹成毕业于清华大学,微软区块链领域全球最有价值专家 https://mvp.microsoft.com/zh-cn/PublicProfile/4033620 伪造者生成的代码。

Jump to

Keyboard shortcuts

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