{"id":21424807,"url":"https://github.com/opentelemetry-php/contrib-auto-ext-rdkafka","last_synced_at":"2026-03-11T02:01:35.276Z","repository":{"id":249893959,"uuid":"832902836","full_name":"opentelemetry-php/contrib-auto-ext-rdkafka","owner":"opentelemetry-php","description":"[READONLY] OpenTelemetry RdKarka instrumentation","archived":false,"fork":false,"pushed_at":"2025-05-20T01:39:35.000Z","size":18,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-21T02:32:42.265Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":false,"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/opentelemetry-php.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,"zenodo":null}},"created_at":"2024-07-24T00:58:39.000Z","updated_at":"2025-06-23T23:58:39.000Z","dependencies_parsed_at":"2025-04-13T03:43:20.915Z","dependency_job_id":"97a9ff6d-d702-4d9d-a1e6-915382e578c2","html_url":"https://github.com/opentelemetry-php/contrib-auto-ext-rdkafka","commit_stats":null,"previous_names":["opentelemetry-php/contrib-auto-ext-rdkafka"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/opentelemetry-php/contrib-auto-ext-rdkafka","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opentelemetry-php%2Fcontrib-auto-ext-rdkafka","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opentelemetry-php%2Fcontrib-auto-ext-rdkafka/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opentelemetry-php%2Fcontrib-auto-ext-rdkafka/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opentelemetry-php%2Fcontrib-auto-ext-rdkafka/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/opentelemetry-php","download_url":"https://codeload.github.com/opentelemetry-php/contrib-auto-ext-rdkafka/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opentelemetry-php%2Fcontrib-auto-ext-rdkafka/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30367799,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"online","status_checked_at":"2026-03-11T02:00:07.027Z","response_time":84,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-11-22T21:24:39.801Z","updated_at":"2026-03-11T02:01:35.259Z","avatar_url":"https://github.com/opentelemetry-php.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"This is a read-only subtree split of https://github.com/open-telemetry/opentelemetry-php-contrib.\n\n# OpenTelemetry ext-rdkafka auto-instrumentation\n\nPlease read https://opentelemetry.io/docs/instrumentation/php/automatic/ for instructions on how to\ninstall and configure the extension and SDK.\n\n## Overview\n\nAuto-instrumentation hooks are registered via composer. There will be a new span created for each message that is\nconsumed. The goal of this instrumentation is to allow distributed traces to happen across Kafka in PHP. This means that\nthe following should happen:\n\n- A span should be created for each message that is consumed\n- The span should be created with the correct parent context- should the inbound message contain a traceparent header\n- The span should be ended when the message offset is `committed`\n- Any messages produced should have the traceparent header injected into the message headers\n\nThis is done by hooking into three methods:\n\n- `\\RdKafka\\KafkaConsumer::consume`- For span creation and context propagation on inbound messages.\n- `\\RdKafka\\ProducerTopic::producev`- For injecting the traceparent header into the message headers of produced\n  messages.\n    - Note there is an old method called `produce`. This does not support headers, and thus there was no point hooking\n      into this\n- `\\RdKafka\\KafkaConsumer::commit` / `\\RdKafka\\KafkaConsumer::commitAsync` - For ending the span when the message offset\n  is committed.\n\n## Versions\n\n* Tested on PHP 8.2 and 8.3 with success\n\n## Configuration\n\nThe extension can be disabled\nvia [runtime configuration](https://opentelemetry.io/docs/instrumentation/php/sdk/#configuration):\n\n```shell\nOTEL_PHP_DISABLED_INSTRUMENTATIONS=ext-rdkafka\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopentelemetry-php%2Fcontrib-auto-ext-rdkafka","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopentelemetry-php%2Fcontrib-auto-ext-rdkafka","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopentelemetry-php%2Fcontrib-auto-ext-rdkafka/lists"}