1
0
mirror of https://github.com/open-telemetry/opentelemetry-go.git synced 2024-12-04 09:43:23 +02:00
Commit Graph

250 Commits

Author SHA1 Message Date
dependabot[bot]
83513f70f3
Bump google.golang.org/api from 0.32.0 to 0.36.0 in /exporters/trace/jaeger (#1398)
* Bump google.golang.org/api in /exporters/trace/jaeger

Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client) from 0.32.0 to 0.36.0.
- [Release notes](https://github.com/googleapis/google-api-go-client/releases)
- [Changelog](https://github.com/googleapis/google-api-go-client/blob/master/CHANGES.md)
- [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.32.0...v0.36.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-12-14 08:21:38 -08:00
dependabot[bot]
a354fc4152
Bump github.com/prometheus/client_golang from 1.7.1 to 1.8.0 in /exporters/metric/prometheus (#1397)
* Bump github.com/prometheus/client_golang in /exporters/metric/prometheus

Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.7.1 to 1.8.0.
- [Release notes](https://github.com/prometheus/client_golang/releases)
- [Changelog](https://github.com/prometheus/client_golang/blob/master/CHANGELOG.md)
- [Commits](https://github.com/prometheus/client_golang/compare/v1.7.1...v1.8.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-12-14 08:16:26 -08:00
dependabot[bot]
3528e42c93
Bump google.golang.org/grpc from 1.32.0 to 1.34.0 in /exporters/otlp (#1396)
* Bump google.golang.org/grpc from 1.32.0 to 1.34.0 in /exporters/otlp

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.32.0 to 1.34.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.32.0...v1.34.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
2020-12-14 08:11:22 -08:00
Johannes Liebermann
c3c4273ecc
Add RO/RW span interfaces (#1360)
* Store span data directly in the span

- Nesting only some of a span's data in a `data` field (with the rest
  of the data living direclty in the `span` struct) is confusing.
- export.SpanData is meant to be an immutable *snapshot* of a span,
  not the "authoritative" state of the span.
- Refactor attributesMap.toSpanData into toKeyValue and make it
  return a []label.KeyValue which is clearer than modifying a struct
  passed to the function.
- Read droppedCount from the attributesMap as a separate operation
  instead of setting it from within attributesMap.toSpanData.
- Set a span's end time in the span itself rather than in the
  SpanData to allow reading the span's end time after a span has
  ended.
- Set a span's end time as soon as possible within span.End so that
  we don't influence the span's end time with operations such as
  fetching span processors and generating span data.
- Remove error handling for uninitialized spans. This check seems to
  be necessary only because we used to have an *export.SpanData field
  which could be nil. Now that we no longer have this field I think we
  can safely remove the check. The error isn't used anywhere else so
  remove it, too.

* Store parent as trace.SpanContext

The spec requires that the parent field of a Span be a Span, a
SpanContext or null.

Rather than extracting the parent's span ID from the trace.SpanContext
which we get from the tracer, store the trace.SpanContext as is and
explicitly extract the parent's span ID where necessary.

* Add ReadOnlySpan interface

Use this interface instead of export.SpanData in places where reading
information from a span is necessary. Use export.SpanData only when
exporting spans.

* Add ReadWriteSpan interface

Use this interface instead of export.SpanData in places where it is
necessary to read information from a span and write to it at the same
time.

* Rename export.SpanData to SpanSnapshot

SpanSnapshot represents the nature of this type as well as its
intended use more accurately.

Clarify the purpose of SpanSnapshot in the docs and emphasize what
should and should not be done with it.

* Rephrase attributesMap doc comment

"refreshes" is wrong for plural ("updates").

* Refactor span.End()

- Improve accuracy of span duration. Record span end time ASAP. We
  want to measure a user operation as accurately as possible, which
  means we want to mark the end time of a span as soon as possible
  after span.End() is called. Any operations we do inside span.End()
  before storing the end time affect the total duration of the span,
  and although these operations are rather fast at the moment they
  still seem to affect the duration of the span by "artificially"
  adding time between the start and end timestamps. This is relevant
  only in cases where the end time isn't explicitly specified.
- Remove redundant idempotence check. Now that IsRecording() is based
  on the value of span.endTime, IsRecording() will always return
  false after span.End() had been called because span.endTime won't
  be zero. This means we no longer need span.endOnce.
- Improve TestEndSpanTwice so that it also ensures subsequent calls
  to span.End() don't modify the span's end time.

* Update changelog

Co-authored-by: Tyler Yahn <codingalias@gmail.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-12-10 21:15:44 -08:00
Tyler Yahn
61e07a0d62
Release v0.15.0 (#1392) 2020-12-10 21:00:59 -08:00
José Carlos Chávez
787e3f457a
chore(zipkin-exporter): relay on the status code for the request but still read the response body. (#1328)
* chore(zipkin-exporter): relay on the status code for the request but still read the response body.

* fix(zipkin-exporter): fix tests.

* chore(zipkin-exporter): adds changelog.

* chore: 202 -> http.StatusAccepted

Co-authored-by: Chris Bandy <bandy.chris@gmail.com>

* chore: 202 -> http.StatusAccepted

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>

Co-authored-by: Chris Bandy <bandy.chris@gmail.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-12-03 09:51:09 -08:00
dependabot[bot]
e1ff2d15cf
Bump github.com/google/go-cmp from 0.5.3 to 0.5.4 (#1374)
* Bump github.com/google/go-cmp from 0.5.3 to 0.5.4

Bumps [github.com/google/go-cmp](https://github.com/google/go-cmp) from 0.5.3 to 0.5.4.
- [Release notes](https://github.com/google/go-cmp/releases)
- [Commits](https://github.com/google/go-cmp/compare/v0.5.3...v0.5.4)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-30 10:31:41 -08:00
Krzesimir Nowak
5a728db2e9
Another batch of cleanups in otlp exporter (#1357)
* Move connection logic into grpcConnection object

If we will need to maintain more than one connection in future, this
splitting off will come in handy.

Co-authored-by: Stefan Prisca <stefan.prisca@gmail.com>

* Make another channel a signal channel

There is another channel that serves as a one-time signal, where
channel's data type does not matter.

* Reorder and document connection members

This is to make clear that the lock is guarding only the connection
since it can be changed by multiple goroutines, and other members are
either atomic or read-only.

* Move stop signal into connection

The stop channel was rather useless on the exporter side - the primary
reason for existence of this channel is to stop a background
reconnecting goroutine. Since the goroutine lives entirely within
grpcConnection object, move the stop channel here. Also expose a
function to unify the stop channel with the context cancellation, so
exporter can use it without knowing anything about stop channels.

Also make export functions a bit more consistent.

* Do not run reconnection routine when being stopped too

It's possible that both disconnected channel and stop channel will be
triggered around the same time, so the goroutine is as likely to start
reconnecting as to return from the goroutine. Make sure we return if
the stop channel is closed.

* Nil clients on connection error

Set clients to nil on connection error, so we don't try to send the
data over a bad connection, but return a "no client" error
immediately.

* Do not call new connection handler within critical section

It's rather risky to call a callback coming from outside within a
critical section. Move it out.

* Add context parameter to connection routines

Connecting to the collector may also take its time, so it can be
useful in some cases to pass a context with a deadline. Currently we
just pass a background context, so this commit does not really change
any behavior. The follow-up commits will make a use of it, though.

* Add context parameter to NewExporter and Start

It makes it possible to limit the time spent on connecting to the
collector.

* Stop connecting on shutdown

Dialling to grpc service ignored the closing of the stop channel, but
this can be easily changed.

* Close connection after background is shut down

That way we can make sure that there won't be a window between closing
a connection and waiting for the background goroutine to return, where
the new connection could be established.

* Remove unnecessary nil check

This member is never nil, unless the Exporter is created like
&Exporter{}, which is not a thing we support anyway.

* Update changelog

Co-authored-by: Stefan Prisca <stefan.prisca@gmail.com>
2020-11-24 11:50:05 -08:00
Tyler Yahn
575df22b79
Release v0.14.0 (#1355)
* Prepare for releasing v0.14.0

* Update changelog
2020-11-20 08:36:54 -08:00
Krzesimir Nowak
6eb68013b5
Some cleanups in otlp exporter (#1350)
* Drop WorkerCount option

This is not a good option - the user isn't likely to know how many
worker goroutines is optimal. This should be something that an
exporter should figure out itself. The second problem with the option
is that it is specific to the metric transformation from SDK export
format into protobuf. When the exporter starts supporting other
protocols (HTTP/JSON for example), this option may be of no use. So
the option should rather belong to the protocol, not to the
exporter. Currently both mean the same, but later they will be
separated, and this option breaks the separation.

* Make stop channel a typical signalling channel

Signalling channels are idiomatically defined as chan struct{}, so
let's make it so, to avoid confusion about the meaning of the bool
type.

* Close a race when grpc connection is closed multiple times

If several goroutines call Shutdown at the same time, then the
following scenario is possible:

goroutine A locks a mutex, reads a started member, unlocks the mutex
and gets preempted

goroutine B locks a mutex, reads a started member, unlocks the mutex
and gets preempted

goroutine A does not return early in the "if !started" conditional and
continues to close the connection and execute the rest of the function
(where it finally sets the started member to false), gets preempted

goroutine B also does not return early, because it got a copy of
started before goroutine A set it to false, so it tries to close the
connection again.

* Update changelog
2020-11-19 21:03:25 -05:00
Tyler Yahn
5b5b4ab1ea
Update OTLP to v0.6.0 (#1354)
* Update opentelemetry-proto submodule to v0.6.0

* Update generated code

* Update the OTLP exporter with new proto

* Update CHANGELOG
2020-11-19 20:57:17 -05:00
Hanshuo Tan
fd3c82bec5
support exact kind in OTLP metrics exporter (#1309)
* support exact kind in OTLP metrics exporter

* add change log

* rename function

* inline start time and end time variables

* fix test

* add test for exact int data points

* add test for exact float data points

* use newly introduced number package for numbers according to upstream change

* fix package ref
2020-11-18 14:35:37 -05:00
Krzesimir Nowak
3d6e8b5078
Move Version function and code from global to toplevel (#1330)
* Move global code to toplevel package

* Move version function to toplevel package

* Update changelog

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-16 09:30:54 -08:00
dependabot[bot]
20c78fed0a
Bump github.com/google/go-cmp from 0.5.2 to 0.5.3 (#1339)
* Bump github.com/google/go-cmp from 0.5.2 to 0.5.3

Bumps [github.com/google/go-cmp](https://github.com/google/go-cmp) from 0.5.2 to 0.5.3.
- [Release notes](https://github.com/google/go-cmp/releases)
- [Commits](https://github.com/google/go-cmp/compare/v0.5.2...v0.5.3)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-16 09:11:53 -08:00
Andrew Hsu
27aa1f6011
update go documentation badge image (#1322)
Signed-off-by: Andrew Hsu <xuzuan@gmail.com>

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-12 07:33:04 -08:00
Krzesimir Nowak
75d4911c95
Move metric code to a separate package (#1321)
* Move metrics code to metric package

* Update changelog
2020-11-12 07:28:32 -08:00
Krzesimir Nowak
386331a472
Prepare to move metrics code to separate subpackage (#1316)
* Move registry package under metric

* Move Number type to the metric/number subpackage

This also renames NumberKind type to Kind.

* Update changelog

* Drop outdated comment
2020-11-11 07:24:12 -08:00
Joshua MacDonald
f9984f2d4e
Support configurable AggregationTemporality in exporters; add OTLP missing sum point temporality/monotonic fields (#1296)
* Restructure ExportKindSelector helpers; eliminate PassThroughExportKind; add StatelessExportKindSelector()

* WithExportKindSelector(); Additional testing

* Changelog update

* Test the new selectors

* From review feedback

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-10 07:44:42 -08:00
Tawhid Hannan
b7508da6fa
Export non monotonic counters as gauge values from the prometheus exporter (#1269)
* Export non monotonic counters as gauge values from the prometheus exporter

* Add a test to ensure the pre-existing LastValue pathway on the collector exports the last value

* Add a TODO around refactoring the prometheus test to verify metadata as well

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-11-09 13:52:05 -08:00
Krzesimir Nowak
3268501910
Move tracing code to trace package (#1307)
* Move tracing code to trace package

* Update changelog
2020-11-06 17:13:31 -05:00
José Carlos Chávez
e22a48de5a
chore: adds vanity import for files that don't have it. (#1297) 2020-11-04 09:10:58 -08:00
Joshua MacDonald
187adeb251
Change resource.New() to use functional options; add builtin attributes for (host.*, telemetry.sdk.*) (#1235)
* Add a resource.Configure() with functional options

* Add a changelog

* Add tests for builtin resources

* Rename to WithoutBuiltin

* Add new test; restore environment after tests

* Apply feedback

* Apply suggestions from code review

❤️

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>

* Comment edits

* Rename New, former method NewFromAttributes

* NewFromAttributes->NewWithAttributes

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-10-31 11:16:55 -07:00
Tyler Yahn
034195692a
Update README and documentation to better communicate pre-GA state (#1281)
* Update README

Move project status to top of project documentation and add explicit
warnings that this project may introduce breaking changes.

* Add disclaimer to public packages docs

* Use explicit warning in README
2020-10-29 09:23:13 -07:00
Hui Kang
d75ccbb378
Add a Shutdown method to sdk TraceProvider (#1227)
* Add a Shutdown method to api TraceProvider

- sdktraceprovider shutdown span processors
- In examples, replace processosr shutdown with
  traceprovider's shutdown

Signed-off-by: Hui Kang <kangh@us.ibm.com>

* remove shutdown in the api provider interface

* Add context in parameter and return error

* handle error in shutdown

* Update CHANGELOG.md

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-10-26 09:20:49 -07:00
Tyler Yahn
d6dd84f6fa
Move the otel/api/global package to otel/global (#1262)
* Move otel/api/global to otel/global

* Update global package references

* Add changes to CHANGELOG
2020-10-17 10:03:48 -07:00
Tyler Yahn
818c7b14b3
Move metric api package into otel (#1252)
* Update metric Kind to InstrumentKind

* Update all the other modules with Kind rename

* Update metric Descriptor with instrument Kind rename

* Update other modules with Descriptor method rename

* Update OTLP exporter test field name

* Rename kind filenames

* Add changes to CHANGELOG

* Fix documentation for Grouping and PrecomputedSum

* Rename meter.go to metric.go

* Move descriptor.go into metric.go

* Move must.go into metric.go

* Move instruments into metric_instrument.go

* Rename metric api_test.go to metric_test.go

* Move instrumentkind_test.go into metric_test.go

* Rename sdkapi.go metric_sdkapi.go

* Move api/metric into otel

* Update to use moved packages

* Rename otel.go to error_handler.go

* Add changes to CHANGELOG

* Fix merge conflict resolution error
2020-10-17 09:48:21 -07:00
Tyler Yahn
396dd6053c
Rename Kind from the api/metric package (#1240)
* Update metric Kind to InstrumentKind

* Update all the other modules with Kind rename

* Update metric Descriptor with instrument Kind rename

* Update other modules with Descriptor method rename

* Update OTLP exporter test field name

* Rename kind filenames

* Add changes to CHANGELOG

* Fix documentation for Grouping and PrecomputedSum
2020-10-13 07:55:31 -07:00
Tyler Yahn
7ecc55581b
Update documentation for the OTLP exporter (#1242)
* Update documentation for the OTLP exporter

Update package documentation to reflect the contents of the package.

Fix lint issues by adding documentation for all exported types.

Update file comment location in otlp.go so golint does not interpret it
as package documentation.

* Apply suggestions from code review

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-10-11 19:57:50 -07:00
alrex
25ccf5a08a
Update proto v0.5.0 (#1230)
* Updating version of OTLP to 0.5.0

* updating trace transform to use latest protos

* update otlp span test

* forgot one test

* finishing the rest of the implementation

In this change:
- MetricDescriptor is no longer a member of the metric
- splitting Sum, Gauge, Histogram by Int/Float
- SummaryDataPoints are no longer around, MinMaxSumCount is now a Histogram

* update changelog

* Update CHANGELOG.md

Move changes to the Unreleased section. This is to account for the recent release.

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-10-08 20:07:39 -07:00
Tyler Yahn
27c84d689d
Move trace api package into otel (#1229)
* Move trace API to otel

* Move tracetest to oteltest

* Update package documentation

* Remove old api/trace package

* Lint

* Add changes to CHANGELOG

* Add tests for rest of trace API

* Apply suggestions from code review

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>

* Documentation fixes

Includes resolutions for review issues.

* Correct CHANGELOG post release

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-10-08 19:58:56 -07:00
Anthony Mirabella
9ebca887f0
Pre release v0.13.0 (#1231)
* Prepare for releasing v0.13.0

* Update CHANGELOG.md for v0.13.0 release
2020-10-08 18:18:50 -04:00
Tyler Yahn
5660b0b59f
Update label.ArrayValue to store copies of 1D arrays (#1226)
* Update label.ArrayValue to store copies of 1D arrays

* Update OTLP transform of array attributes

* Add changes to CHANGELOG

* Add PR number to changes

* Update value function documentation

* Remove redundant checks

* Add Array test for invalid array types

* Add test to ensure return from AsArray is a type

* Clean up iteration
2020-10-05 17:09:03 -07:00
Tyler Yahn
577b21745b
Update codes to match specification (#1214)
* Update codes to match specification

* Add changes to changelog

* go mod tidy

* Add unit tests for codes

* Update SetStatus methods to only filter Unset

* Update apitest code being tested
2020-10-05 11:36:03 -07:00
dependabot[bot]
e9c80e62a4
Bump github.com/openzipkin/zipkin-go from 0.2.4 to 0.2.5 in /exporters/trace/zipkin (#1224)
* Bump github.com/openzipkin/zipkin-go in /exporters/trace/zipkin

Bumps [github.com/openzipkin/zipkin-go](https://github.com/openzipkin/zipkin-go) from 0.2.4 to 0.2.5.
- [Release notes](https://github.com/openzipkin/zipkin-go/releases)
- [Commits](https://github.com/openzipkin/zipkin-go/compare/v0.2.4...v0.2.5)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-10-05 09:17:02 -07:00
ET
04297f4d04
Enable exporting Histogram aggregation to OTLP metric (#1209)
* Add Count() to Histogram interface

* Fix copy/pasted comment for Count() interface

* Implement Histogram conversion to OTLP protobuf

* Add CHANGELOG message

* Filled in PR # for Changelog

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-09-28 17:58:15 -07:00
Anthony Mirabella
0b348c345f
Prepare v0.12.0 release (#1205)
* Prepare for releasing v0.12.0

* Update CHANGELOG.md for v0.12.0 release

* Update CHANGELOG.md

Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
2020-09-24 19:01:48 -04:00
Joshua MacDonald
8c3cc43992
Use LastValue by default for ValueObserver instruments (#1165)
* Use LastValue by default for ValueObserver instruments

* Update test

* Update test with feedback

* Update fix

* Update changelog

* sum->scalar

* Tests pass

* Add a test

* Undo incorrect proto adds

* Restore origin protos

* Restore

* Upstream

* Add more tests

* Precommit

* Typo

* ore test feedback
2020-09-24 18:30:55 -04:00
Dan Rusei
559fecd73e
Update the attribute names for the OTel attributes for the zipkin exporter (#1201)
Based on the spec change: https://github.com/open-telemetry/opentelemetry-specification/pull/967
2020-09-23 22:42:05 -04:00
Tyler Yahn
7d71867644
Rename *Provider names (#1190)
* Rename *Provider names

There is overlap in naming with MeterProviders and TracerProviders. This
is means the specification is not implemented and these types can not
exist in the same package (#1179). This makes each type and related
functions and types explicit.

* Add changes to CHANGELOG
2020-09-23 18:16:13 -04:00
dependabot[bot]
fa741472e7
Bump google.golang.org/api from 0.31.0 to 0.32.0 in /exporters/trace/jaeger (#1188)
* Bump google.golang.org/api in /exporters/trace/jaeger

Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client) from 0.31.0 to 0.32.0.
- [Release notes](https://github.com/googleapis/google-api-go-client/releases)
- [Changelog](https://github.com/googleapis/google-api-go-client/blob/master/CHANGES.md)
- [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.31.0...v0.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-21 12:06:05 -04:00
Tyler Yahn
4b46365d1d
Move api/unit to top level (#1185)
* Move api/unit to top level

* Add changes to CHANGELOG
2020-09-20 13:54:21 -04:00
Anthony Mirabella
d91de437b2
Recommend use of initializers for config structs (#1163)
* Recommend use of initializers for config structs

Updates style guide and changes existing configure() implementations to
newConfig() as appropriate.

* Add CHANGELOG.md entry

* Update stdout exporter config initializer

* Add documentation to exported functions

* Convert otlp.Config to unexported otlp.config
2020-09-11 14:14:25 -07:00
dependabot[bot]
9a4981cc67
Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /sdk (#1145)
* Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /sdk

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.31.1 to 1.32.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.31.1...v1.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Aneurysm9 <Aneurysm9@users.noreply.github.com>
Co-authored-by: Anthony J Mirabella <a9@aneurysm9.com>
2020-09-09 13:25:27 -04:00
Tyler Yahn
422188a85f
Correct SDK trace Exporter interface (#1078)
* Update trace export interface

Move to conforming to the specification.

* Update documentation in export trace

* Update sdk trace provider to support new trace exporter

* Update SpanProcessors

Support the Provider changes and new trace exporter.

* Update the SDK to support the changes

* Update trace Provider to not return an error

* Update sdk with new Provider return

Also fix the testExporter ExportSpans method

* Update exporters with changes

* Update examples with changes

* Update Changelog

* Move error handling to end of shutdown

* Update exporter interface

Rename to SpanExporter to match specification. Add an error return value
to the Shutdown method based on feedback. Propagate these changes.

Remove the Stop method from the OTLP exporter to avoid confusion and
redundancy.

* Add test to check OTLP Shutdown honors context

* Add Jaeger exporter test for shutdown

* Fix race in Jaeger test

* Unify shutdown behavior and testing

* Update sdk/trace/simple_span_processor.go

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>

Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 10:19:03 -07:00
dependabot[bot]
da96fd0c5e
Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/otlp (#1146)
* Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/otlp

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.31.1 to 1.32.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.31.1...v1.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 13:06:59 -04:00
dependabot[bot]
a1b43b4b03
Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/stdout (#1148)
* Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/stdout

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.31.1 to 1.32.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.31.1...v1.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 13:02:31 -04:00
dependabot[bot]
932638697a
Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/trace/jaeger (#1151)
* Bump google.golang.org/grpc in /exporters/trace/jaeger

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.31.1 to 1.32.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.31.1...v1.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 12:58:23 -04:00
dependabot[bot]
e58e347f93
Bump google.golang.org/grpc from 1.31.1 to 1.32.0 in /exporters/trace/zipkin (#1149)
* Bump google.golang.org/grpc in /exporters/trace/zipkin

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.31.1 to 1.32.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.31.1...v1.32.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 12:41:45 -04:00
dependabot[bot]
dd3d4f2ae0
Bump github.com/openzipkin/zipkin-go from 0.2.3 to 0.2.4 in /exporters/trace/zipkin (#1150)
* Bump github.com/openzipkin/zipkin-go in /exporters/trace/zipkin

Bumps [github.com/openzipkin/zipkin-go](https://github.com/openzipkin/zipkin-go) from 0.2.3 to 0.2.4.
- [Release notes](https://github.com/openzipkin/zipkin-go/releases)
- [Commits](https://github.com/openzipkin/zipkin-go/compare/v0.2.3...v0.2.4)

Signed-off-by: dependabot[bot] <support@github.com>

* Auto-fix go.sum changes in dependent modules

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
2020-09-09 12:29:08 -04:00
JBD
a2c75c6d78
Unexport NoopXXX trace types (#1134)
* Unexport NoopXXX trace types

The change unexports the noop implementations and provide the NoopProvider function for user to construct noop providers. Users can access noop tracer and noop spans by using the provider.

This change removes the types users should never be directly using from the package. It improves the usability of the API by reducing the API surface to half and helping the user to focus on the canonical APIs.

Fixes #1133

* Provide noop tracer and span for internal use

* Remove obsolete doc

* Use noop span instead of nil

* Fix the broken  build
2020-09-08 20:43:35 -04:00