census-instrumentation / opencensus-csharp

Distributed tracing and stats collecting framework
https://opencensus.io
Apache License 2.0
139 stars 32 forks source link

Should the concrete classes be hidden? #28

Closed ndrwrbgs closed 5 years ago

ndrwrbgs commented 6 years ago

In the java source version, the concrete classes are created by AutoValue which, from my limited understanding, does not expose the concrete types. If we want to preserve that intention, then I'd propose our concrete classes (like BucketBoundaries, should not be sealed, but rather be static with just the Create method, and have private sealed implementation classes.

If the intention is to expose these concrete types (which may result in folks programming to those rather than the intended interfaces) then that's fine too - but at that point we may want to consider if we want to expose interfaces at all.

SergeyKanzhelev commented 5 years ago

This will be handled in OpenTelemetry project