{"id":18767770,"url":"https://github.com/lightstep/opentelemetry-examples","last_synced_at":"2026-03-05T08:02:46.090Z","repository":{"id":37057659,"uuid":"234150325","full_name":"lightstep/opentelemetry-examples","owner":"lightstep","description":"Example code and resources for working with OpenTelemetry, provided by Lightstep","archived":false,"fork":false,"pushed_at":"2024-03-13T22:12:16.000Z","size":5599,"stargazers_count":58,"open_issues_count":48,"forks_count":31,"subscribers_count":48,"default_branch":"main","last_synced_at":"2025-04-20T07:45:10.213Z","etag":null,"topics":["opentelemetry"],"latest_commit_sha":null,"homepage":"https://lightstep.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lightstep.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-15T18:55:09.000Z","updated_at":"2024-11-27T12:03:09.000Z","dependencies_parsed_at":"2023-10-02T18:17:39.556Z","dependency_job_id":"47d8998d-64ef-4f5f-936b-29542e70466f","html_url":"https://github.com/lightstep/opentelemetry-examples","commit_stats":{"total_commits":296,"total_committers":25,"mean_commits":11.84,"dds":0.6351351351351351,"last_synced_commit":"f074eff0fb916a708a524e36f1ba0ecd3ea774c3"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lightstep/opentelemetry-examples","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightstep%2Fopentelemetry-examples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightstep%2Fopentelemetry-examples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightstep%2Fopentelemetry-examples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightstep%2Fopentelemetry-examples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lightstep","download_url":"https://codeload.github.com/lightstep/opentelemetry-examples/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightstep%2Fopentelemetry-examples/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263226879,"owners_count":23433798,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["opentelemetry"],"created_at":"2024-11-07T19:08:30.465Z","updated_at":"2026-03-05T08:02:41.041Z","avatar_url":"https://github.com/lightstep.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cloud Observability OpenTelemetry Examples\n\nThis repository contains example code and resources for configuring a variety of languages with OpenTelemetry. The directory structure for each language looks like this:\n\n```\ngo\n├── opentelemetry - these applications are configured and instrumented using opentelemetry\n                    directly\n└── opentracing - these applications are using the OpenTracing bridge available in\n                  OpenTelemetry. The code is instrumented using OpenTracing.\n```\n\n### Running examples\n\nAll the applications in this repository can be launched using docker-compose. In order to send data to Cloud Observability, you can update the configuration using the steps below before starting docker-compose:\n\n```bash\ngit clone https://github.com/lightstep/opentelemetry-examples \u0026\u0026 cd opentelemetry-examples\n\n# copy the example environment variable file\n# and update the access token\ncp ./config/example.env .env\nsed -i '' 's/\u003cACCESS TOKEN\u003e/YOUR TOKEN HERE/' .env\n# if using the AWS OpenTelemetry Distro, use `example-aws-collector-config.yaml`\ncp ./config/example-collector-config.yaml ./config/collector-config.yaml\nsed -i '' 's/\u003cACCESS TOKEN\u003e/YOUR TOKEN HERE/' ./config/collector-config.yaml\n\ndocker-compose up\n```\n\nThe following client/server applications use different mechanism for sending data to Cloud Observability. The following examples are configured in the `docker-compose.yml` file:\n\n| name             | description                                                  |\n| ---------------- | ------------------------------------------------------------ |\n| go-opentracing   | client/server example instrumented via lightstep-tracer-go   |\n| go-opentelemetry | client/server example instrumented via OpenTelemetry and the OTLP exporter |\n| py-collector     | client/server example instrumented via OpenTelemetry and the OTLP exporter combined with the OpenTelemetry Collector |\n| py-opentelemetry | client/server example instrumented via OpenTelemetry and the OTLP exporter |\n| java             | client/server example instrumented via special agent         |\n| java-otlp        | client/server example instrumented via OpenTelemetry and the OTLP exporter |\n| js-ot-shim       | client/server example instrumented via OpenTelemetry and JS Launcher with OpenTracing |\n\n### OpenTelemetry Collector Integrations\n\nAdditionally, the repo contains example for producing telemetry via various OpenTelemetry Collector Integrations. The integrations can be found under `./collector/\u003cintegration\u003e`. To produce telemetry using these integrations:\n\n1. Clone this repository and `cd` into the directory for the integration of choice:\n\n    `cd ./collector/mysql`\n\n2. Export your Cloud Observability Access Token\n\n    `export LS_ACCESS_TOKEN=\u003cyour token\u003e`.\n\n3. Run the environment using Docker compose\n\n    `docker compose up`\n\n4. Access the Cloud Observability dashboard for the integration.\n\n------\n\n*Made with* ![:heart:](https://a.slack-edge.com/production-standard-emoji-assets/10.2/apple-medium/2764-fe0f.png) *@ [Cloud Observability](https://lightstep.com/)*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flightstep%2Fopentelemetry-examples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flightstep%2Fopentelemetry-examples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flightstep%2Fopentelemetry-examples/lists"}