diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..13566b8 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,8 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/ChatGPTCopilotChannelManager.xml b/.idea/ChatGPTCopilotChannelManager.xml new file mode 100644 index 0000000..5cc2066 --- /dev/null +++ b/.idea/ChatGPTCopilotChannelManager.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/integrations.iml b/.idea/integrations.iml new file mode 100644 index 0000000..5e764c4 --- /dev/null +++ b/.idea/integrations.iml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..faddf2d --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/collector/scylla/examples/compose/README.md b/collector/scylla/examples/compose/README.md new file mode 100644 index 0000000..e64811a --- /dev/null +++ b/collector/scylla/examples/compose/README.md @@ -0,0 +1,55 @@ +# Scylla metrics using the OpenTelemetry Collector + +## Overview + + Name: natively exposes a Prometheus endpoint and the OpenTelemetry Collector has a [Prometheus receiver][otel-prom-receiver] that can be used to scrape its Prometheus endpoint. This directory contains an example showing how to configure Name: and the Collector to send metrics to Lightstep Observability. + +## Prerequisites + +* Docker +* Docker Compose +* A Lightstep Observability [access token][ls-docs-access-token] + +## How to run the example + +* Export your Lightstep access token + + ```sh + export LS_ACCESS_TOKEN= + ``` + +* Run the docker compose example + + ```sh + docker-compose up -d + ``` + +### Explore Metrics in Lightstep + +See the [Name: Telemetry Docs][scylla-docs-telemetry] for comprehensive documentation on metrics emitted and the [dashboard documentation][ls-docs-dashboards] for more details. + +## Configure the Collector + +Below is a snippet showing how to configure the Prometheus Receiver to scrape the Prometheus endpoint exposed by the Name: Server. + +```yaml +receivers: + prometheus: + config: + scrape_configs: + - job_name: 'scylladb' + scrape_interval: 10s + static_configs: + - targets: ['localhost:9180'] +``` + + +## Additional information + +- [OpenTelemetry Collector Prometheus Receiver][otel-prom-receiver] +- [Name: Telemetry Reference][scylla-docs-telemetry] + +[ls-docs-access-token]: https://docs.lightstep.com/docs/create-and-manage-access-tokens +[ls-docs-dashboards]: https://docs.lightstep.com/docs/create-and-manage-dashboards +[otel-prom-receiver]: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/prometheusreceiver +[scylla-docs-telemetry]: https://cloud.docs.scylladb.com/stable/monitoring/cloud-prom-proxy.html \ No newline at end of file diff --git a/collector/scylla/examples/compose/collector.yaml b/collector/scylla/examples/compose/collector.yaml new file mode 100644 index 0000000..f7e7f91 --- /dev/null +++ b/collector/scylla/examples/compose/collector.yaml @@ -0,0 +1,26 @@ +receivers: + prometheus: + config: + scrape_configs: + - job_name: 'scylladb' + scrape_interval: 10s + static_configs: + - targets: ['scylladb:9180'] + +processors: + batch: + +exporters: + logging: + loglevel: debug + otlp: + endpoint: ingest.staging.lightstep.com:443 + headers: + - lightstep-access-token: ${LS_ACCESS_TOKEN} + +service: + pipelines: + metrics: + receivers: [prometheus] + processors: [batch] + exporters: [logging,otlp] diff --git a/collector/scylla/examples/compose/docker-compose.yaml b/collector/scylla/examples/compose/docker-compose.yaml new file mode 100644 index 0000000..30f21b1 --- /dev/null +++ b/collector/scylla/examples/compose/docker-compose.yaml @@ -0,0 +1,18 @@ +version: '3.7' +services: + scylladb: + container_name: scylladb + image: scylladb/scylla:latest + ports: + - "9042:9042" + + otel-collector: + container_name: otel-collector + image: otel/opentelemetry-collector-contrib:0.81.0 + hostname: otel-collector + restart: always + command: [ "--config=/conf/collector.yaml" ] + volumes: + - ./collector.yaml:/conf/collector.yaml:rw + environment: + LS_ACCESS_TOKEN: "${LS_ACCESS_TOKEN}"