github.com/netdata/go.d.plugin@v0.58.1/modules/pulsar/integrations/apache_pulsar.md (about)

     1  <!--startmeta
     2  custom_edit_url: "https://github.com/netdata/go.d.plugin/edit/master/modules/pulsar/README.md"
     3  meta_yaml: "https://github.com/netdata/go.d.plugin/edit/master/modules/pulsar/metadata.yaml"
     4  sidebar_label: "Apache Pulsar"
     5  learn_status: "Published"
     6  learn_rel_path: "Data Collection/Message Brokers"
     7  most_popular: True
     8  message: "DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE"
     9  endmeta-->
    10  
    11  # Apache Pulsar
    12  
    13  
    14  <img src="https://netdata.cloud/img/pulsar.svg" width="150"/>
    15  
    16  
    17  Plugin: go.d.plugin
    18  Module: pulsar
    19  
    20  <img src="https://img.shields.io/badge/maintained%20by-Netdata-%2300ab44" />
    21  
    22  ## Overview
    23  
    24  This collector monitors Pulsar servers.
    25  
    26  
    27  It collects broker statistics using Pulsar's [Prometheus endpoint](https://pulsar.apache.org/docs/en/deploy-monitoring/#broker-stats).
    28  
    29  
    30  This collector is supported on all platforms.
    31  
    32  This collector supports collecting metrics from multiple instances of this integration, including remote instances.
    33  
    34  
    35  ### Default Behavior
    36  
    37  #### Auto-Detection
    38  
    39  By default, it detects Pulsar instances running on localhost.
    40  
    41  
    42  #### Limits
    43  
    44  The default configuration for this integration does not impose any limits on data collection.
    45  
    46  #### Performance Impact
    47  
    48  The default configuration for this integration is not expected to impose a significant performance impact on the system.
    49  
    50  
    51  ## Metrics
    52  
    53  Metrics grouped by *scope*.
    54  
    55  The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels.
    56  
    57  - topic_* metrics are available when `exposeTopicLevelMetricsInPrometheus` is set to true.
    58  - subscription_* and namespace_subscription metrics are available when `exposeTopicLevelMetricsInPrometheus` si set to true.
    59  - replication_* and namespace_replication_* metrics are available when replication is configured and `replicationMetricsEnabled` is set to true.
    60  
    61  
    62  ### Per Apache Pulsar instance
    63  
    64  These metrics refer to the entire monitored application.
    65  
    66  This scope has no labels.
    67  
    68  Metrics:
    69  
    70  | Metric | Dimensions | Unit |
    71  |:------|:----------|:----|
    72  | pulsar.broker_components | namespaces, topics, subscriptions, producers, consumers | components |
    73  | pulsar.messages_rate | publish, dispatch | messages/s |
    74  | pulsar.throughput_rate | publish, dispatch | KiB/s |
    75  | pulsar.storage_size | used | KiB |
    76  | pulsar.storage_operations_rate | read, write | message batches/s |
    77  | pulsar.msg_backlog | backlog | messages |
    78  | pulsar.storage_write_latency | <=0.5ms, <=1ms, <=5ms, =10ms, <=20ms, <=50ms, <=100ms, <=200ms, <=1s, >1s | entries/s |
    79  | pulsar.entry_size | <=128B, <=512B, <=1KB, <=2KB, <=4KB, <=16KB, <=100KB, <=1MB, >1MB | entries/s |
    80  | pulsar.subscription_delayed | delayed | message batches |
    81  | pulsar.subscription_msg_rate_redeliver | redelivered | messages/s |
    82  | pulsar.subscription_blocked_on_unacked_messages | blocked | subscriptions |
    83  | pulsar.replication_rate | in, out | messages/s |
    84  | pulsar.replication_throughput_rate | in, out | KiB/s |
    85  | pulsar.replication_backlog | backlog | messages |
    86  
    87  ### Per namespace
    88  
    89  TBD
    90  
    91  This scope has no labels.
    92  
    93  Metrics:
    94  
    95  | Metric | Dimensions | Unit |
    96  |:------|:----------|:----|
    97  | pulsar.namespace_broker_components | topics, subscriptions, producers, consumers | components |
    98  | pulsar.namespace_messages_rate | publish, dispatch | messages/s |
    99  | pulsar.namespace_throughput_rate | publish, dispatch | KiB/s |
   100  | pulsar.namespace_storage_size | used | KiB |
   101  | pulsar.namespace_storage_operations_rate | read, write | message batches/s |
   102  | pulsar.namespace_msg_backlog | backlog | messages |
   103  | pulsar.namespace_storage_write_latency | <=0.5ms, <=1ms, <=5ms, =10ms, <=20ms, <=50ms, <=100ms, <=200ms, <=1s, >1s | entries/s |
   104  | pulsar.namespace_entry_size | <=128B, <=512B, <=1KB, <=2KB, <=4KB, <=16KB, <=100KB, <=1MB, >1MB | entries/s |
   105  | pulsar.namespace_subscription_delayed | delayed | message batches |
   106  | pulsar.namespace_subscription_msg_rate_redeliver | redelivered | messages/s |
   107  | pulsar.namespace_subscription_blocked_on_unacked_messages | blocked | subscriptions |
   108  | pulsar.namespace_replication_rate | in, out | messages/s |
   109  | pulsar.namespace_replication_throughput_rate | in, out | KiB/s |
   110  | pulsar.namespace_replication_backlog | backlog | messages |
   111  | pulsar.topic_producers | a dimension per topic | producers |
   112  | pulsar.topic_subscriptions | a dimension per topic | subscriptions |
   113  | pulsar.topic_consumers | a dimension per topic | consumers |
   114  | pulsar.topic_messages_rate_in | a dimension per topic | publishes/s |
   115  | pulsar.topic_messages_rate_out | a dimension per topic | dispatches/s |
   116  | pulsar.topic_throughput_rate_in | a dimension per topic | KiB/s |
   117  | pulsar.topic_throughput_rate_out | a dimension per topic | KiB/s |
   118  | pulsar.topic_storage_size | a dimension per topic | KiB |
   119  | pulsar.topic_storage_read_rate | a dimension per topic | message batches/s |
   120  | pulsar.topic_storage_write_rate | a dimension per topic | message batches/s |
   121  | pulsar.topic_msg_backlog | a dimension per topic | messages |
   122  | pulsar.topic_subscription_delayed | a dimension per topic | message batches |
   123  | pulsar.topic_subscription_msg_rate_redeliver | a dimension per topic | messages/s |
   124  | pulsar.topic_subscription_blocked_on_unacked_messages | a dimension per topic | blocked subscriptions |
   125  | pulsar.topic_replication_rate_in | a dimension per topic | messages/s |
   126  | pulsar.topic_replication_rate_out | a dimension per topic | messages/s |
   127  | pulsar.topic_replication_throughput_rate_in | a dimension per topic | messages/s |
   128  | pulsar.topic_replication_throughput_rate_out | a dimension per topic | messages/s |
   129  | pulsar.topic_replication_backlog | a dimension per topic | messages |
   130  
   131  
   132  
   133  ## Alerts
   134  
   135  There are no alerts configured by default for this integration.
   136  
   137  
   138  ## Setup
   139  
   140  ### Prerequisites
   141  
   142  No action required.
   143  
   144  ### Configuration
   145  
   146  #### File
   147  
   148  The configuration file name for this integration is `go.d/pulsar.conf`.
   149  
   150  
   151  You can edit the configuration file using the `edit-config` script from the
   152  Netdata [config directory](https://github.com/netdata/netdata/blob/master/docs/configure/nodes.md#the-netdata-config-directory).
   153  
   154  ```bash
   155  cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata
   156  sudo ./edit-config go.d/pulsar.conf
   157  ```
   158  #### Options
   159  
   160  The following options can be defined globally: update_every, autodetection_retry.
   161  
   162  
   163  <details><summary>Config options</summary>
   164  
   165  | Name | Description | Default | Required |
   166  |:----|:-----------|:-------|:--------:|
   167  | update_every | Data collection frequency. | 1 | no |
   168  | autodetection_retry | Recheck interval in seconds. Zero means no recheck will be scheduled. | 0 | no |
   169  | url | Server URL. | http://127.0.0.1:8080/metrics | yes |
   170  | timeout | HTTP request timeout. | 1 | no |
   171  | username | Username for basic HTTP authentication. |  | no |
   172  | password | Password for basic HTTP authentication. |  | no |
   173  | proxy_url | Proxy URL. |  | no |
   174  | proxy_username | Username for proxy basic HTTP authentication. |  | no |
   175  | proxy_password | Password for proxy basic HTTP authentication. |  | no |
   176  | method | HTTP request method. | GET | no |
   177  | body | HTTP request body. |  | no |
   178  | headers | HTTP request headers. |  | no |
   179  | not_follow_redirects | Redirect handling policy. Controls whether the client follows redirects. | no | no |
   180  | tls_skip_verify | Server certificate chain and hostname validation policy. Controls whether the client performs this check. | no | no |
   181  | tls_ca | Certification authority that the client uses when verifying the server's certificates. |  | no |
   182  | tls_cert | Client TLS certificate. |  | no |
   183  | tls_key | Client TLS key. |  | no |
   184  
   185  </details>
   186  
   187  #### Examples
   188  
   189  ##### Basic
   190  
   191  A basic example configuration.
   192  
   193  ```yaml
   194  jobs:
   195    - name: local
   196      url: http://127.0.0.1:8080/metrics
   197  
   198  ```
   199  ##### HTTP authentication
   200  
   201  Basic HTTP authentication.
   202  
   203  <details><summary>Config</summary>
   204  
   205  ```yaml
   206  jobs:
   207    - name: local
   208      url: http://127.0.0.1:8080/metrics
   209      username: username
   210      password: password
   211  
   212  ```
   213  </details>
   214  
   215  ##### HTTPS with self-signed certificate
   216  
   217  Do not validate server certificate chain and hostname.
   218  
   219  
   220  <details><summary>Config</summary>
   221  
   222  ```yaml
   223  jobs:
   224    - name: local
   225      url: https://127.0.0.1:8080/metrics
   226      tls_skip_verify: yes
   227  
   228  ```
   229  </details>
   230  
   231  ##### Multi-instance
   232  
   233  > **Note**: When you define multiple jobs, their names must be unique.
   234  
   235  Collecting metrics from local and remote instances.
   236  
   237  
   238  <details><summary>Config</summary>
   239  
   240  ```yaml
   241  jobs:
   242    - name: local
   243      url: http://127.0.0.1:8080/metrics
   244  
   245    - name: remote
   246      url: http://192.0.2.1:8080/metrics
   247  
   248  ```
   249  </details>
   250  
   251  
   252  
   253  ## Troubleshooting
   254  
   255  ### Debug Mode
   256  
   257  To troubleshoot issues with the `pulsar` collector, run the `go.d.plugin` with the debug option enabled. The output
   258  should give you clues as to why the collector isn't working.
   259  
   260  - Navigate to the `plugins.d` directory, usually at `/usr/libexec/netdata/plugins.d/`. If that's not the case on
   261    your system, open `netdata.conf` and look for the `plugins` setting under `[directories]`.
   262  
   263    ```bash
   264    cd /usr/libexec/netdata/plugins.d/
   265    ```
   266  
   267  - Switch to the `netdata` user.
   268  
   269    ```bash
   270    sudo -u netdata -s
   271    ```
   272  
   273  - Run the `go.d.plugin` to debug the collector:
   274  
   275    ```bash
   276    ./go.d.plugin -d -m pulsar
   277    ```
   278  
   279