Skip to content

Conversation

@lukaslihotzki-f
Copy link
Contributor

@lukaslihotzki-f lukaslihotzki-f commented Mar 18, 2025

Remaining todos:

  • documentation
  • testing

Metrics will be done in a separate PR.

This PR does nothing without explicit configuration.

Add this to homeserver.yaml:

opentracing:
  enabled: true
  backend: otlp

Add this to your log config YAML:

handlers:
  otlp:
    class: synapse.logging.handlers.OtlpHandler
root:
  handlers: […, otlp]

Note that the logging OtlpHandler does not use a formatter, because it is designed for structured logging.

Then, set the otlp endpoint using environment variables (e.g., OTEL_EXPORTER_OTLP_ENDPOINT).

@CLAassistant
Copy link

CLAassistant commented Apr 2, 2025

CLA assistant check
All committers have signed the CLA.

@lukaslihotzki-f lukaslihotzki-f marked this pull request as ready for review April 2, 2025 15:36
@lukaslihotzki-f lukaslihotzki-f requested a review from a team as a code owner April 2, 2025 15:36
@lukaslihotzki-f lukaslihotzki-f force-pushed the ll/opentelemetry branch 3 times, most recently from 95381dc to 6328f20 Compare April 9, 2025 21:10
Copy link
Member

@nico-famedly nico-famedly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, but I didn't test it yet. Long term we might want to integrate otlp better by removing the opentracing support and reorganizing some things to allow dynamic tracing of endpoints, but for now this looks good. Thanks a lot!

@lukaslihotzki-f lukaslihotzki-f merged commit 1556930 into master Apr 11, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants