{"id":22096845,"url":"https://github.com/streamnative/pulsar-tracing","last_synced_at":"2025-07-24T22:32:27.320Z","repository":{"id":45133532,"uuid":"254857724","full_name":"streamnative/pulsar-tracing","owner":"streamnative","description":"Tracing instrumentation for Apache Pulsar clients.","archived":false,"fork":false,"pushed_at":"2023-05-09T18:28:33.000Z","size":34,"stargazers_count":21,"open_issues_count":10,"forks_count":10,"subscribers_count":32,"default_branch":"master","last_synced_at":"2024-11-14T20:54:49.058Z","etag":null,"topics":["apache-pulsar","jaeger","messaging","opentelemetry","opentracing","pubsub"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/streamnative.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-04-11T11:57:06.000Z","updated_at":"2024-09-21T05:33:48.000Z","dependencies_parsed_at":"2024-11-19T01:44:20.506Z","dependency_job_id":null,"html_url":"https://github.com/streamnative/pulsar-tracing","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamnative%2Fpulsar-tracing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamnative%2Fpulsar-tracing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamnative%2Fpulsar-tracing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streamnative%2Fpulsar-tracing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/streamnative","download_url":"https://codeload.github.com/streamnative/pulsar-tracing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227482464,"owners_count":17779968,"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":["apache-pulsar","jaeger","messaging","opentelemetry","opentracing","pubsub"],"created_at":"2024-12-01T04:12:50.014Z","updated_at":"2024-12-01T04:12:50.757Z","avatar_url":"https://github.com/streamnative.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Apache Pulsar Client Tracing Instrumentation\nTracing instrumentation for Apache Pulsar client.\n\n## OpenTracing Instrumentation\n### Requirements\n\n- Java 8\n- Pulsar client \u003e= 2.5.0\n\n### Installation\n\nAdd Pulsar client and OpenTracing instrumentation for the Pulsar client.\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eorg.apache.pulsar\u003c/groupId\u003e\n    \u003cartifactId\u003epulsar-client\u003c/artifactId\u003e\n    \u003cversion\u003eVERSION\u003c/version\u003e\n\u003c/dependency\u003e\n```\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eio.streamnative\u003c/groupId\u003e\n    \u003cartifactId\u003eopentracing-pulsar-client\u003c/artifactId\u003e\n    \u003cversion\u003eVERSION\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n### Usage\n\n#### Interceptors based solution\n\n```java\n// Instantiate tracer\nTracer tracer = ...\n\n// Optionally register tracer with GlobalTracer\nGlobalTracer.register(tracer);\n```\n\n**Producer**\n\n```java\n// Instantiate Producer with tracing interceptor.\nProducer\u003cString\u003e producer = client\n    .newProducer(Schema.STRING)\n    .intercept(new TracingProducerInterceptor())\n    .topic(\"your-topic\")\n    .create();\n\n// Send messages.\nproducer.send(\"Hello OpenTracing!\");\n```\n\n**Consumer**\n```java\n// Instantiate Consumer with tracing interceptor.\nConsumer\u003cString\u003e consumer = client.newConsumer(Schema.STRING)\n    .topic(\"your-topic\")\n    .intercept(new TracingConsumerInterceptor\u003c\u003e())\n    .subscriptionName(\"your-sub\")\n    .subscribe();\n\n// Receive messages.\nMessage\u003cString\u003e message = consumer.receive();\n\n// To retrieve SpanContext from the message(Consumer side).\nSpanContext spanContext = TracingPulsarUtils.extractSpanContext(message, tracer);\n```\n\n## License\n\n[Apache 2.0 License](./LICENSE).\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreamnative%2Fpulsar-tracing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstreamnative%2Fpulsar-tracing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreamnative%2Fpulsar-tracing/lists"}