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

[receiver/lightprometheus] Add README.md #3049

Merged
merged 3 commits into from
May 2, 2023
Merged
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
46 changes: 46 additions & 0 deletions internal/receiver/lightprometheusreceiver/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Light Prometheus Receiver

| Status | |
| ------------------------ |---------------|
| Stability | [development] |
| Supported pipeline types | metrics |
| Distributions | splunk |

[development]: https://github.com/open-telemetry/opentelemetry-collector#development

## Overview

Light Prometheus Receiver is a component that can scrape Prometheus metrics from a Prometheus exporter endpoint and
convert them to OTLP metrics. It is intended to be used as a replacement for the [Simple Prometheus
Receiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/simpleprometheusreceiver)
as it is more efficient and has a smaller memory footprint.

The receiver is under active development which means that configuration interface can change.

## Configuration

The following settings are required:

- `endpoint` (no default): Address to request Prometheus metrics. This is the same endpoint that
Prometheus scrapes to collect metrics. IMPORTANT: This receiver currently does require the metric path to be included
in the endpoint. For example, if the endpoint is `localhost:1234`, the metrics path must be included, e.g.
`localhost:1234/metrics`. This likely will be changed in the future.

The following settings can be optionally configured:

- `collection_interval` (default = 30s): The internal at which metrics should be scraped by this receiver.
- `resource_attributes`: Resource attributes to be added to all metrics emitted by this receiver. The following options
are available to configure resource attributes:
- `service.name`:
- `enabled`: (default: true)
- `service.instance.id`:
- `enabled`: (default: true)
- `net.host.name`:
- `enabled`: (default: false)
- `net.host.port`:
- `enabled`: (default: false)
- `http.scheme`:
- `enabled`: (default: false)
- [HTTP Client Configuration options](https://github.com/open-telemetry/opentelemetry-collector/tree/main/config/confighttp#client-configuration)

The full list of configuration options exposed for this receiver are documented [here](./config.go) with an example [here](./testdata/config.yaml).