spandex-project / spandex

A platform agnostic tracing library
MIT License
335 stars 53 forks source link

Support a `strict` mode #49

Closed zachdaniel closed 5 years ago

zachdaniel commented 6 years ago

Right now, the library does everything it can not to fail any operations whatsoever, at all. This can mean that updates to spans might fail if they are not valid, or that entire traces aren't started. This also happens silently, currently. We want some kind of strict mode that fails on any issue w/ any operation, or perhaps a log_errors configuration.

zachdaniel commented 6 years ago

The datadog api server should also use strict mode to validate its outgoing spans, for instance that they all have a resource (or that the top one does, I think). https://github.com/zachdaniel/spandex/issues/56

zachdaniel commented 5 years ago

If this were to exist, it would need to exist at the adapter level anyway. I think that with explicit returns, and the API changes we're looking to make, that the essence of this will be included in all of those changes anyway.