Skip to content
This repository was archived by the owner on May 23, 2023. It is now read-only.
This repository was archived by the owner on May 23, 2023. It is now read-only.

Clarify if null values are considered valid tag values? #158

@slto

Description

@slto

Background

We are testing with java-span-reporter as our tracer:
https://github.com/opentracing-contrib/java-span-reporter

We noticed if we call setTag on a span with non-null key and a null value, we get an exception. If we switch to Jaeger java tracer, there is no exception.

Problem

I cannot find a clear statement in the OpenTracing spec whether null values are allowed for span tags. If this is left to the tracer implementation it would easily break the ability to switch tracers as the caller might have started with Jaeger tracer and not been checking for null values when calling setTag.

This seems to suggest you can't call setTag with null as a mechanism to "delete" a tag, but not clear if you can pass null tag value in the initial call:
open-telemetry/opentelemetry-go#53 (comment)

Proposal

Indicate in the specification whether an OpenTracing compliant tracer needs to accept a null tag value

Questions to address

  • Are null values allowed for span tags as part of the specification?

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