{"id":15658340,"url":"https://github.com/frigus02/opentelemetry-application-insights","last_synced_at":"2025-04-04T10:05:22.496Z","repository":{"id":41119217,"uuid":"273797104","full_name":"frigus02/opentelemetry-application-insights","owner":"frigus02","description":"OpenTelemetry exporter for Azure Application Insights","archived":false,"fork":false,"pushed_at":"2025-03-22T16:54:59.000Z","size":603,"stargazers_count":27,"open_issues_count":4,"forks_count":18,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-03-28T09:04:36.134Z","etag":null,"topics":["application-insights","opentelemetry"],"latest_commit_sha":null,"homepage":"https://docs.rs/opentelemetry-application-insights","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/frigus02.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","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-06-20T22:57:52.000Z","updated_at":"2025-03-22T16:54:59.000Z","dependencies_parsed_at":"2023-01-21T18:01:43.611Z","dependency_job_id":"eab6dee4-b11c-4bfc-82a9-08a7545fc1d6","html_url":"https://github.com/frigus02/opentelemetry-application-insights","commit_stats":{"total_commits":178,"total_committers":11,"mean_commits":"16.181818181818183","dds":0.1460674157303371,"last_synced_commit":"15be4bcdb2b0dc6ee1b10fd9205f30d70c18e397"},"previous_names":[],"tags_count":42,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frigus02%2Fopentelemetry-application-insights","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frigus02%2Fopentelemetry-application-insights/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frigus02%2Fopentelemetry-application-insights/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frigus02%2Fopentelemetry-application-insights/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/frigus02","download_url":"https://codeload.github.com/frigus02/opentelemetry-application-insights/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247156284,"owners_count":20893197,"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":["application-insights","opentelemetry"],"created_at":"2024-10-03T13:12:00.888Z","updated_at":"2025-04-04T10:05:22.463Z","avatar_url":"https://github.com/frigus02.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Crates.io](https://img.shields.io/crates/v/opentelemetry-application-insights.svg)](https://crates.io/crates/opentelemetry-application-insights)\n[![Documentation](https://docs.rs/opentelemetry-application-insights/badge.svg)](https://docs.rs/opentelemetry-application-insights)\n[![Workflow Status](https://github.com/frigus02/opentelemetry-application-insights/workflows/CI/badge.svg)](https://github.com/frigus02/opentelemetry-application-insights/actions?query=workflow%3A%22CI%22)\n\n# opentelemetry-application-insights\n\nAn [Azure Application Insights](https://docs.microsoft.com/en-us/azure/azure-monitor/app/app-insights-overview) exporter implementation for [OpenTelemetry Rust](https://github.com/open-telemetry/opentelemetry-rust).\n\n**Disclaimer**: This is not an official Microsoft product.\n\n## Usage\n\nConfigure a OpenTelemetry pipeline using the Application Insights exporter and start creating spans (this example requires the **opentelemetry-http/reqwest** feature):\n\n```rust,no_run\nuse opentelemetry::{global, trace::Tracer};\nuse opentelemetry_sdk::trace::SdkTracerProvider;\n\nfn main() {\n    let connection_string = std::env::var(\"APPLICATIONINSIGHTS_CONNECTION_STRING\").unwrap();\n    let exporter = opentelemetry_application_insights::Exporter::new_from_connection_string(\n        connection_string,\n        reqwest::blocking::Client::new(),\n    )\n    .expect(\"valid connection string\");\n    let tracer_provider = SdkTracerProvider::builder()\n        .with_batch_exporter(exporter)\n        .build();\n    global::set_tracer_provider(tracer_provider.clone());\n\n    let tracer = global::tracer(\"example\");\n    tracer.in_span(\"main\", |_cx| {});\n\n    tracer_provider.shutdown().unwrap();\n}\n```\n\nSee documentation for more:\n\n- [Logs](https://docs.rs/opentelemetry-application-insights/latest/opentelemetry_application_insights/#logs)\n- [Metrics](https://docs.rs/opentelemetry-application-insights/latest/opentelemetry_application_insights/#metrics)\n- [Simple or Batch](https://docs.rs/opentelemetry-application-insights/latest/opentelemetry_application_insights/#simple-or-batch)\n- [Async runtimes and HTTP clients](https://docs.rs/opentelemetry-application-insights/latest/opentelemetry_application_insights/#async-runtimes-and-http-clients)\n\n## Application Insights integration\n\n### Thanks\n\nHuge thanks goes to [Denis Molokanov](https://github.com/dmolokanov) for the amazing [appinsights](https://github.com/dmolokanov/appinsights-rs) crate. Check it out if you want a more direct integration with Application Insights.\n\n### Documentation\n\nThe only official documentation I could find is this one. Follow the links to see the data model and endpoint description.\n\n\u003e Can I send telemetry to the Application Insights portal?\n\u003e\n\u003e We recommend you use our SDKs and use the [SDK API](https://docs.microsoft.com/en-us/azure/azure-monitor/app/api-custom-events-metrics). There are variants of the SDK for various [platforms](https://docs.microsoft.com/en-us/azure/azure-monitor/app/platforms). These SDKs handle buffering, compression, throttling, retries, and so on. However, the [ingestion schema](https://github.com/microsoft/ApplicationInsights-dotnet/tree/master/BASE/Schema/PublicSchema) and [endpoint protocol](https://github.com/Microsoft/ApplicationInsights-Home/blob/master/EndpointSpecs/ENDPOINT-PROTOCOL.md) are public.\n\u003e\n\u003e -- https://docs.microsoft.com/en-us/azure/azure-monitor/faq#can-i-send-telemetry-to-the-application-insights-portal\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrigus02%2Fopentelemetry-application-insights","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrigus02%2Fopentelemetry-application-insights","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrigus02%2Fopentelemetry-application-insights/lists"}