From 425e01772e4fe4a81c78b86c02d0385dd05d8aec Mon Sep 17 00:00:00 2001 From: klakshma21 Date: Fri, 19 Jan 2024 05:56:01 +0530 Subject: [PATCH] chore(RHTAPWATCH-592): Create a README.md under o11y/exporters and blurb about exporters in the root README.md Signed-off-by: Kousalya Lakshmanan --- README.md | 34 +++++++++++++++++++++++++++++++--- exporters/dsexporter/README.md | 25 +++++++++++++++++++++++++ 2 files changed, 56 insertions(+), 3 deletions(-) create mode 100644 exporters/dsexporter/README.md diff --git a/README.md b/README.md index ee743b60..7fe19fbd 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,7 @@ This repository contains the following definitions for RHTAP: * Prometheus alerting rules (deployed to RHOBS) * Grafana dashboards (deployed to AppSRE's Grafana) + * Availability exporters ## Alerting Rules @@ -99,8 +100,35 @@ to RHOBS. If additional metrics or labels are needed, add them by following the described in the [monitoring stack documentation](https://github.com/redhat-appstudio/infra-deployments/blob/main/components/monitoring/prometheus/README.md#federation-and-remote-write) +## Availability exporters + +In order to be able to evaluate the overall availability of the Konflux ecosystem, we +need to be able to establish the availability of each of its components. + +By leveraging the existing [Konflux monitoring stack](https://gitlab.cee.redhat.com/konflux/docs/documentation/-/blob/main/o11y/monitoring/monitoring.md) based on Prometheus, we create Prometheus exporters that +generate metrics that are scraped by the User Workload Monitoring Prometheus instance +and remote-written to RHOBS. + +### Prometheus Exporters + +Prometheus exporters expose metrics from a system or application in a format that can +be scraped and monitored by Prometheus. The exporter may be an integral part of the +component that it's monitoring (self-instrumenting), or it can generate metrics for +another system/component. + +### Availability Exporter Example +The o11y team provides an example availability exporter that can be used as reference, +especially in the case in which the exporter is external to the code it's monitoring. + +- [Exporter code](https://github.com/redhat-appstudio/o11y/tree/main/exporters/dsexporter) +- [Exporter and service Monitor Kubernetes Resources](https://github.com/redhat-appstudio/o11y/tree/main/config/exporters/monitoring/grafana/base) + +### References + +- [Availability exporters deatiled documentation](https://gitlab.cee.redhat.com/konflux/docs/documentation/-/blob/main/o11y/monitoring/availability_exporters.md?ref_type=heads) +- [Prometheus exporters](https://www.airplane.dev/blog/prometheus-exporters) + ## Support -The RHTAP o11y team maintains this repository. -Reach out to us on our [slack channel](https://redhat-internal.slack.com/archives/C04FDFTF8EB) -for further assistance. +- Slack: [#forum-konflux-o11y](https://app.slack.com/client/E030G10V24F/C04FDFTF8EB) + diff --git a/exporters/dsexporter/README.md b/exporters/dsexporter/README.md new file mode 100644 index 00000000..d123f796 --- /dev/null +++ b/exporters/dsexporter/README.md @@ -0,0 +1,25 @@ +# dsexporter + +## Overview + +The `dsexporter` is a specialized Prometheus exporter designed to provide availability metrics for the components +within the Konflux ecosystem. It generates a custom metric (`request_count`) related to the number of requests handled +by an HTTP handler, enabling the evaluation of overall availability. + +## Purpose + +In the context of the Konflux ecosystem, the `dsexporter` serves as an Availability Exporter, contributing to the +evaluation of the availability of each component within the system. By exposing the `request_count` metric, it allows +for monitoring and analyzing the workload and performance of the associated service. + +## Prometheus Exporters + +A **Prometheus exporter** exposes metrics from a system or application in a format that Prometheus can ingest and monitor. +The `dsexporter` follows the Prometheus exposition format, providing a web endpoint that outputs metrics in a well-known format. + +## Getting Started + +To use the `dsexporter`, follow these steps: + +1. Import the necessary packages in your code. +2. Start the HTTP server and the exporter will be accessible at the respected endpoint.