pulsar

package
v0.28.1 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: GPL-3.0 Imports: 10 Imported by: 1

README

Apache Pulsar monitoring with Netdata

Apache Pulsar is an open-source distributed pub-sub messaging system.

This module will monitor one or more Apache Pulsar instances, depending on your configuration.

It collects broker statistics from the prometheus endpoint.

pulsar module is tested on the following versions:

  • v2.5.0

Charts

It produces the following charts:

Summary
  • Broker Components in num
  • Messages Rate in messages/s
  • Throughput Rate in KiB/s
  • Storage Size in KiB
  • Messages Backlog Size in messages
  • Storage Write Latency Histogram in entries/s
  • Entry Size Histogram in entries/s
  • Subscriptions Delayed for Dispatching in message batches

If exposeTopicLevelMetricsInPrometheus is set to true:

  • Subscriptions Redelivered Message Rate in messages/s
  • Subscriptions Blocked On Unacked Messages in subscriptions

If replication is configured and replicationMetricsEnabled is set to true:

  • Replication Rate in messages/s
  • Replication Throughput Rate in messages/s
  • Replication Backlog in messages
Namespace
  • Broker Components in num
  • Messages Rate in messages/s
  • Throughput Rate in KiB/s
  • Storage Size in KiB
  • Storage Read/Write Operations Rate in message batches/s
  • Messages Backlog Size in messages
  • Storage Write Latency Histogram in entries/s
  • Entry Size Histogram in entries/s
  • Subscriptions Delayed for Dispatching in message batches

If exposeTopicLevelMetricsInPrometheus is set to true:

  • Subscriptions Redelivered Message Rate in messages/s
  • Subscriptions Blocked On Unacked Messages in subscriptions

If replication is configured and replicationMetricsEnabled is set to true:

  • Replication Rate in messages/s
  • Replication Throughput Rate in messages/s
  • Replication Backlog in messages
Topic

Topic charts are only available when exposeTopicLevelMetricsInPrometheus is set to true. In addition, you need to set topic_filer configuration option. If you have a lot of topics this is highly unrecommended.

  • Producers in producers
  • Subscriptions in producers
  • Consumers in producers
  • Publish Messages Rate in publishes/s
  • Dispatch Messages Rate in dispatches/s
  • Publish Throughput Rate in KiB/s
  • Dispatch Throughput Rate in KiB/s
  • Storage Size in KiB
  • Storage Read Rate in message batches/s
  • Storage Write Rate in message batches/s
  • Messages Backlog Size in messages
  • Subscriptions Delayed for Dispatching in message batches
  • Subscriptions Redelivered Message Rate in messages/s
  • Subscriptions Blocked On Unacked Messages in blocked subscriptions

If replication is configured and replicationMetricsEnabled is set to true:

  • Topic Replication Rate From Remote Cluster in messages/s
  • Topic Replication Rate To Remote Cluster in messages/s
  • Topic Replication Throughput Rate From Remote Cluster in KiB/s
  • Topic Replication Throughput Rate To Remote Cluster in KiB/s
  • Topic Replication Backlog in KiB/s

Configuration

Edit the go.d/pulsar.conf configuration file using edit-config from the Netdata config directory, which is typically at /etc/netdata.

cd /etc/netdata # Replace this path with your Netdata config directory
sudo ./edit-config go.d/pulsar.conf

Needs only url to server's /metrics endpoint. Here is an example for 2 servers:

jobs:
  - name: local
    url: http://127.0.0.1:8080/metrics

  - name: remote
    url: http://203.0.113.10:8080/metrics

For all available options please see module configuration file.

Topic filtering

By default module collects data for all topics but it supports topic filtering. Filtering doesnt exclude a topic stats from the summary/namespace stats, it only removes the topic from the topic charts.

To check matcher syntax see matcher documentation.

  - name: local
    url: http://127.0.0.1:8080/metrics
    topic_filter:
      includes:
        - matcher1
        - matcher2
      excludes:
        - matcher1
        - matcher2

Update every

Module default update_every is 60.

Apache Pulsar doesnt expose raw counters, it exposes rate. It counts rates every statsUpdateFrequencyInSecs. Default value is 60 seconds.

Module update_every should be equal to statsUpdateFrequencyInSecs.

Troubleshooting

To troubleshoot issues with the pulsar collector, run the go.d.plugin with the debug option enabled. The output should give you clues as to why the collector isn't working.

First, navigate to your plugins directory, usually at /usr/libexec/netdata/plugins.d/. If that's not the case on your system, open netdata.conf and look for the setting plugins directory. Once you're in the plugin's directory, switch to the netdata user.

cd /usr/libexec/netdata/plugins.d/
sudo -u netdata -s

You can now run the go.d.plugin to debug the collector:

./go.d.plugin -d -m pulsar

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chart

type Chart = module.Chart

type Charts

type Charts = module.Charts

type Config

type Config struct {
	web.HTTP   `yaml:",inline"`
	TopicFiler matcher.SimpleExpr `yaml:"topic_filter"`
}

type Dim

type Dim = module.Dim

type Dims

type Dims = module.Dims

type Opts

type Opts = module.Opts

type Pulsar

type Pulsar struct {
	module.Base
	Config `yaml:",inline"`
	// contains filtered or unexported fields
}

func New

func New() *Pulsar

func (*Pulsar) Charts

func (p *Pulsar) Charts() *Charts

func (*Pulsar) Check

func (p *Pulsar) Check() bool

func (Pulsar) Cleanup

func (Pulsar) Cleanup()

func (*Pulsar) Collect

func (p *Pulsar) Collect() map[string]int64

func (*Pulsar) Init

func (p *Pulsar) Init() bool

Jump to

Keyboard shortcuts

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