Skip to content

[FEATURE] Customize or standardize OpenTelemetry span names and attributes #570

@tvardero

Description

@tvardero

Problem

I want to integrate FusionCache with Sentry caching insights. Here are the docs for manual instrumentation.

Currently I'm using OpenTelemetry instrumentation of FusionCache, which then exported to Sentry SDK. Sentry does not have its own native integration with FusionCache, so doesn't FusionCache with Sentry.

Currently in FusionCache span.op names are like get or set from cache and others, which are not recognized by Sentry as caching spans and are treated as just regular trace spans.

Solution

  • A way to customize span operation names via options/factories
  • A way to override span factory of fusion cache with dependency injection
  • Or update fusion cache default span.op names, so they line up with what looks like OTel semantic conventions (here and here). There are no conventions for caching in OTel docs, only for databases, however Sentry has their own conventions here and here.

Alternatives

  • Manually instrumenting caching layer
  • Investigating source code of FusionCache OTel integration and finding what service to override and register in DI.

Additional context

I just like cool graphs.

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