Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Text updates: rabbitmq/rabbitmq-monitoring #316

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion integrations/rabbitmq/rabbitmq-monitoring/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,13 @@ to [Semantic Versioning][semver].

## Unreleased

- N/A
- Remove linux and darwin tags in integration yaml
- Revise text labels and prompts in configuration modal
- Add summary for success screen in integration yaml file
- Restore separate Alerts section in README
- Add and revise setup steps and options in README
- Revise reference documentation list in README


## [ 20220421.0.0 ] - 2022-04-21

Expand Down
53 changes: 39 additions & 14 deletions integrations/rabbitmq/rabbitmq-monitoring/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,11 @@

<!-- Sensu Integration description; supports markdown -->

The [RabbitMQ] monitoring integration provides metrics from a RabbitMQ cluster running the [`rabbitmq_prometheus` Rabbitmq plugin](https://www.rabbitmq.com/prometheus.html#installation).

[RabbitMQ]: https://www.rabbitmq.com
The RabbitMQ Monitoring integration collects metrics from RabbitMQ clusters that run the [`rabbitmq_prometheus` plugin][rabbit-prom-plugin].

<!-- Provide a high level overview of the integration contents (e.g. checks, filters, mutators, handlers, assets, etc) -->

This integration includes the following resources:
This integration includes the following Sensu resources:

* `rabbitmq-monitoring` [check]
* `sensu/http-checks:0.7.0` [asset]
Expand All @@ -21,46 +19,71 @@ This integration includes the following resources:

<!-- ![](img/dashboard.png) -->

There are no compatible dashboards for this integration.
The RabbitMQ Metrics integration does not have compatible dashboards.

## Setup

<!-- Sensu Integration setup instructions, including Sensu agent configuration and external component configuration -->
<!-- EXAMPLE: what configuration (if any) is required in a third-party service to enable monitoring? -->

1. **[OPTIONAL] Configure custom request headers**
1. Get the RabbitMQ target URL. You will need these target URL elements to install this integration:

- Protocol (`http` or `https`)
- Host (hostname, IP address, or domain name)
- Port number (default is `15692`)
- Path (`/metrics`)

1. Decide which Sensu agents should execute the `rabbitmq-monitoring` check. You will need the agent [subscription] names when you install this integration.

To add custom request headers, install this integration, then modify the resulting Sensu Check resource with one or more `--header` flags.
1. If you want to use a Sensu [pipeline] to process RabbitMQ Monitoring integration data, you will need the pipeline name when you install this integration.

Example:
1. **Optional** Configure custom request headers.

To use custom request headers, install this integration. Then, update the `rabbitmq-monitoring` check to add one or more `--header` flags in the check's `command` attribute.

<details><summary><strong>Example: Custom request header configuration</strong></summary>

```yaml
spec:
command: >-
http-get
--timeout 10
--url "http://127.0.0.1:15692/
--url "http://127.0.0.1:15692/"
--header "Content-Type: text/plain"
--header "X-Example-Header: helloworld"
```

</details>
<br>

## Plugins

<!-- Links to any Sensu Integration dependencies (i.e. Sensu Plugins) -->

The RabbitMQ Monitoring integration uses the following Sensu [plugins]:

- [sensu/http-checks][http-checks-bonsai] ([GitHub][http-checks-github])

## Metrics & Events
## Alerts

<!-- List of all alerts generated by this integration. -->

The RabbitMQ Monitoring integration does not produce any events that should be processed by an alert or incident management pipeline.

## Metrics

<!-- List of all metrics or events collected by this integration. -->

This integration collects a wide range of [metrics], depending on the configuration of your Rabbitmq cluster. For a full list, see the [Rabbitmq metrics documentation](https://www.rabbitmq.com/monitoring.html#rabbitmq-metrics).
The RabbitMQ Monitoring integration collects many [metrics], depending on the RabbitMQ cluster configuration. For a complete list of metrics, read [RabbitMQ Metrics].

# Reference Documentation
## Reference Documentation

<!-- Please provide links to any relevant reference documentation to help users learn more and/or troubleshoot this integration; specifically including any third-party software documentation. -->

1. This integration uses [Sensu Tokens][tokens] for variable substitution.
* [Token substitution] (Sensu documentation): the RabbitMQ Monitoring integration supports Sensu tokens for variable substitution with data from Sensu entities
* [Monitoring with Prometheus & Grafana][rabbit-prom-plugin] (RabbitMQ documentation)
* [RabbitMQ Metrics] (RabbitMQ documentation)


<!-- Links -->
[entity]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/observe-entities/entities/
Expand All @@ -76,7 +99,9 @@ This integration collects a wide range of [metrics], depending on the configurat
[pipeline]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/observe-process/pipelines/
[secret]: https://docs.sensu.io/sensu-go/latest/operations/manage-secrets/secrets/
[secrets]: https://docs.sensu.io/sensu-go/latest/operations/manage-secrets/secrets/
[tokens]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/observe-schedule/tokens/
[Token substitution]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/observe-schedule/tokens/
[sensu-plus]: https://sensu.io/features/analytics
[http-checks-bonsai]: https://bonsai.sensu.io/assets/sensu/http-checks
[http-checks-github]: https://github.com/sensu/http-checks
[RabbitMQ Metrics]: https://www.rabbitmq.com/monitoring.html#rabbitmq-metrics
[rabbit-prom-plugin]: https://www.rabbitmq.com/prometheus.html
83 changes: 43 additions & 40 deletions integrations/rabbitmq/rabbitmq-monitoring/sensu-integration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,43 +7,41 @@ metadata:
spec:
class: community
provider: monitoring
display_name: RabbitMQ monitoring
short_description: Collect metrics from rabbitmq_prometheus rabbitmq plugin
display_name: RabbitMQ Monitoring
short_description: Collect metrics from the rabbitmq_prometheus plugin
supported_platforms:
- darwin
- linux
tags:
- rabbitmq
- metrics
- prometheus
- linux
- darwin
contributors:
- "@sensu"
- "@thoward"
- "@nixwiz"
- "@jspaleta"
prompts:
- type: section
title: RabbitMQ Prometheus Metrics HTTP Endpoint Configuration
title: RabbitMQ HTTP Endpoint Configuration
- type: markdown
body: |
Configure HTTP Endpoint monitoring with the following parameters:
Provide these configuration parameters for the `rabbitmq_prometheus` HTTP endpoint:

* **URL**: the target URL to monitor (e.g. `https://api.mycompany.com:443/health`)
* **Protocol**: select http or https request
* **Host**: provide a hostname, IP address, or domain name
* **Port**: provide the port to check (e.g. `80` for HTTP, `443` for HTTPS)
* **Path**: provide the URL path to check (e.g. `/healthz`)
* **Interval**: how often to monitor the HTTP endpoint (in seconds)
* Target URL to collect metrics from, such as `https://127.0.0.1:15692/metrics`, separated into:
* Protocol (`http` or `https`)
* Host (hostname, IP address, or domain name)
* Port number (`15692`)
* Path (`/metrics`)
* Interval for collecting metrics from the endpoint (in seconds)
- type: question
name: protocol
required: true
input:
type: string
title: HTTP Endpoint Protocol
title: Target URL protocol
description: >-
Provide the HTTP endpoint protocol (i.e. "http" or "https").
Select the protocol for the `rabbitmq_prometheus` target URL (`http` or `https`)
enum:
- http
- https
Expand All @@ -53,77 +51,75 @@ spec:
required: true
input:
type: string
title: HTTP Endpoint Host
title: Target URL host
description: >-
Provide the HTTP endpoint host (e.g. "127.0.0.1")
Enter the host for the `rabbitmq_prometheus` target URL
default: 127.0.0.1
- type: question
name: port
required: true
input:
type: integer
title: HTTP Endpoint Port
title: Target URL port
description: >-
Provide the HTTP endpoint port (e.g. 15692 is the default for the rabbitmq_promethus plugin)
Enter the port for the `rabbitmq_prometheus` target URL (`rabbitmq_prometheus` default is `15692`)
default: 15692
- type: question
name: path
required: true
input:
type: string
title: HTTP Endpoint Path
title: Target URL path
description: >-
Provide the HTTP endpoint path (e.g. "/metrics"; NOTE: this configuration MUST begin with a "/")
Enter the path for the `rabbitmq_prometheus` target URL (MUST begin with `/`)
default: "/metrics"
- type: question
name: interval
input:
type: integer
title: Interval
description: >-
Configure the HTTP endpoint monitoring interval, in seconds (60 = one minute, 300 = five minutes, 600 = 10 minutes, etc)
Specify the metrics collection interval, in seconds (60 = 1 minute, 300 = 5 minutes, 600 = 10 minutes)
default: 30
- type: question
name: labels
input:
type: object
title: Labels
description: Key/value metadata
format: io.sensu.meta.label
additionalProperties:
type: string
- type: section
title: Configure Sensu Subscriptions
title: Check Labels and Sensu Subscriptions
- type: markdown
body: |
Configure which Sensu Agent subscriptions this check should be run on.

E.G. A subscription that maps to the hosts that are running RabbitMQ server with the rabbitmq_prometheus plugin enabled.
Specify the subscriptions for Sensu agents that should execute the `rabbitmq-monitoring` check and the metadata labels to add to the check definition.
- type: question
name: subscriptions
input:
type: array
items:
type: string
title: Subscriptions (Origins)
title: Subscriptions
ref: core/v2/entity/subscriptions
default:
- rabbitmq
- type: question
name: labels
input:
type: object
title: Check labels
description: Add metadata labels for the `rabbitmq-monitoring` check
format: io.sensu.meta.label
additionalProperties:
type: string
- type: section
title: Pipeline Configuration
- type: markdown
body: |
Configure one or more [pipelines] for processing RabbitMQ Prometheus metrics.
Name the [pipelines] you want to use to process RabbitMQ Monitoring integration data.

[pipelines]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/
[pipelines]: https://docs.sensu.io/sensu-go/latest/observability-pipeline/observe-process/pipelines/
- type: question
name: metrics_pipeline
required: false
input:
type: string
title: Metrics Pipeline
title: Metrics pipeline name
description: >-
How do you want to process metrics collected by this integration?
Which pipeline do you want to use to process the metrics this integration collects?
ref: core/v2/pipeline/metadata/name
refFilter: .labels.provider == "metrics"
resource_patches:
Expand Down Expand Up @@ -158,4 +154,11 @@ spec:
api_version: core/v2
type: Pipeline
name: "[[metrics_pipeline]]"

post_install:
- type: section
title: Success
- type: markdown
body: |
You enabled the RabbitMQ Monitoring integration for `[[protocol]]://[[host]]:[[port]][[path]]`.

The `rabbitmq-monitoring` check will run for all Sensu agents with these subscriptions: [[subscriptions]].