Skip to content

Falsey tags are being dropped from metrics #321

Description

@streed

Hey all!

Ran into a problem where having a tag that looks like { some_tag: false } would result in the tag being dropped. This appears to be occurring because of the following line: https://github.com/DataDog/dogstatsd-ruby/blob/master/lib/datadog/statsd/serialization/tag_serializer.rb#L62

The output over the wire looks like:

some_counter:1|c when called with a hash that looks like { some_tag: false }

The expected output would be:

some_counter:1|c|#some_tag:false when the tag hash looks like { some_tag: false }

This isn't a breaking change, but the behavior resulted in unexpected results.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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