Skip to content

Allow using the module without specifying an exporter #61

@akheron

Description

@akheron

Is your feature request related to a problem? Please describe

For some use cases, it might be beneficial to use this module even without specifying an exporter at all, or "exporting" the traces by printing/logging.

Use cases:

  • Running the same code in different environments (local/test/staging/production) is useful, even if some of the environments don't have a service to export the traces to. If the otel module is not loaded in other environments, a bug might only be discovered in production!
  • Enabling the otel module might be useful even if the traces are not exported anywhere. By propagating the context, the trace id and parent span id can still be logged in all services to enable log correlation.

Describe the solution you'd like

Don't require an otel_exporter section at all, or allow configuring a printing/logging exporter in otel_exporter section.

Describe alternatives you've considered

Alternatively, only require otel_exporter section if tracing on; is used in a location block. tracing off; would not require it. This is the "worst" option in my opinion, but would also be a workaround to allow enabling the module.

Additional context

None

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions