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

153 Commits

Author SHA1 Message Date
Joshua MacDonald
9401bd9cda
Remove Context arguments from Aggregator.Checkpoint and Integrator.Process (#803)
* Typo

* Swap order of ddsketch.New for consistency w/ histogram.New

* Remove Integrator.Process ctx argument

* Remove Aggregator.Checkpoint ctx argument

* Revert bugfix
2020-06-09 11:00:50 -07:00
Tyler Yahn
3e95c9c78e
Update error handling exporters to use global.Handle 2020-06-02 12:30:55 -07:00
Tyler Yahn
289f372308
Merge branch 'master' into otlp 2020-06-02 10:41:44 -07:00
Anthony J Mirabella
0e8fb1cb4f Ensure zipkin exporter reads and closes response body 2020-06-02 11:46:34 -04:00
Tyler Yahn
9c6c712c54
Merge branch 'master' into otlp 2020-06-01 09:15:29 -07:00
Tyler Yahn
0c3127c27e
Update README.md with batcher comment 2020-06-01 09:09:26 -07:00
Joshua MacDonald
86a10268b8
Minor cleanups in sdk/metric/aggregator (#781)
* Typo

* Swap order of ddsketch.New for consistency w/ histogram.New
2020-05-30 20:16:40 -07:00
Tyler Yahn
5d9472beab
Remove nolint and update misspell to ignore cancelled 2020-05-29 11:11:19 -07:00
Tyler Yahn
d917dd7d79
Lint 2020-05-29 11:04:57 -07:00
Tyler Yahn
b2ec53f483
Merge remote-tracking branch 'upstream/master' into otlp 2020-05-29 10:26:41 -07:00
Tyler Yahn
2b1998f1b4
Remove tests
The lack of programmatic enablement of retries means testing is going to
be flaky or cumbersome.
2020-05-29 10:23:01 -07:00
Tyler Yahn
45a679730d
"Working" tests with failure
Needs to be run `GRPC_GO_RETRY=on go test .` to not fail the failing
tests because retries are not enabled by default, nor can they be
enabled programmatically.
2020-05-29 10:18:36 -07:00
Tyler Yahn
07ccb274d2
Update options 2020-05-29 10:17:57 -07:00
Tyler Yahn
7cf20c3af9
Update README
Add information about setup, options, and retries.
2020-05-29 10:13:00 -07:00
Paul Thomson
6929c15957 Add application/json header 2020-05-29 06:24:22 +10:00
Tyler Yahn
a5e9204b58
Merge branch 'master' into pre_release_v0.6.0 2020-05-21 15:45:47 -07:00
Joshua MacDonald
b17a7845df
Rename Register* to New* (#761) 2020-05-21 15:42:14 -07:00
Tyler Yahn
ad37aae65c
Prepare for releasing v0.6.0 2020-05-21 12:10:12 -07:00
Tyler Yahn
e0256f9e94
First try at a failing suite 2020-05-21 12:05:59 -07:00
Tyler Yahn
0d3daf02b1
Merge branch 'master' into jmacd/prom_res 2020-05-21 11:55:41 -07:00
Tyler Yahn
40324a744a
Split into different files 2020-05-21 10:44:46 -07:00
Tyler Yahn
4bb182a91c
Break up to trace and metric suite 2020-05-21 10:31:57 -07:00
jmacd
dacebd6430 Use []float64 for boundaries 2020-05-21 10:29:03 -07:00
jmacd
3d2493463c Comments 2020-05-21 09:53:34 -07:00
Tyler Yahn
c38abde14b
Proof of concept 2020-05-21 09:45:24 -07:00
jmacd
48a8a869fe Upstream 2020-05-21 02:01:06 -07:00
jmacd
7172b30492 Add resources in the Prom tests 2020-05-21 01:38:43 -07:00
jmacd
196d7740bd Add resource support 2020-05-21 01:29:09 -07:00
jmacd
c829d3ea67 Tests pass 2020-05-21 00:36:17 -07:00
jmacd
0b5080372a Add benchmark 2020-05-21 00:19:08 -07:00
Anthony J Mirabella
923a6c8afc Replace sdktrace.WithResourceAttributes() with WithResource() 2020-05-20 16:08:43 -04:00
Joshua MacDonald
5461669733
Add a pull controller, use it for Prometheus (#751)
* Checkpoint new pull controller

* Tests pass

* Fix example

* Example fix

* Add a test

* Comment

* address MrAlias's feedback
2020-05-20 10:27:26 -07:00
Vladimir Mihailenco
244ed23e44
Rename ScheduleDelayMillis to BatchTimeout (#752)
Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-05-20 10:12:57 -07:00
Joshua MacDonald
1fab21ddbf
Support use of synchronous instruments in async callbacks (#725)
* Support use of synchronous instruments in async callbacks

* Add a test
2020-05-19 21:33:10 -07:00
Joshua MacDonald
21d094af43
Refactor the api/metrics push controller; add CheckpointSet synchronization (#737)
* Checkpoint

* Finish tests

* Checkpoint

* Checkpoint (builds)

* Checkpoint + RWMutex interface

* Comments

* Remove commitLock

* Apply feedback
2020-05-18 18:37:41 -07:00
Joshua MacDonald
69da3056f2
Move Resource into the metric export Record (#739)
* Checkpoint

* Tests pass
2020-05-18 17:44:28 -07:00
Joshua MacDonald
ee3c9ed1a5
Rename Observer to ValueObserver (#734)
* Observer -> ValueObserver

* Move wrappers into async.go
2020-05-18 11:03:43 -07:00
Joshua MacDonald
76baa9cc7a
Remove the push controller named Meter map (#738)
* Remove the push controller named Meter map

* Checkpoint

* Remove Provider impls

* Add a test

* Expose Provider() getter instead of implementing the interface
2020-05-18 10:48:58 -07:00
Joshua MacDonald
2dee67652a
Histogram aggregator initial state (fix #735) (#736)
* Add a test

* Add comments and description options

* Another test

* Undo buffer re-use

* Mod tidy

* Precommit

* Again

* Copyright

* Undo rename
2020-05-18 09:44:33 -07:00
Joshua MacDonald
6bc14ffd2c
Replace Measure instrument by ValueRecorder instrument (#732)
* Measure->Value recorder and cleanups re: measure

* More edits

* More edits

* Feedback
2020-05-15 22:11:12 -07:00
Tyler Yahn
ce266f9656
Prepare for releasing v0.5.0 2020-05-13 17:11:23 -07:00
Joshua MacDonald
587cde3352
Remove NewKey and update doc comment (#721)
* Update doc comment

* Remove NewKey

* NewKey->Key
2020-05-13 16:21:23 -07:00
Chen Yixiao
1301b6f3e4
Move core and key to kv package (#720)
* Move core to kv

* Move kv.Value to kv.value.Value

* Move key to kv
2020-05-13 16:06:03 -07:00
Joshua MacDonald
64afb05e53
Metric SDK renames to align with draft SDK spec (#710)
* Replace batcher w/ integrator; rename ungrouped to simple

* SDK -> Accumulator

* Cleamup

* Address feedback
2020-05-11 10:23:06 -07:00
Chen Yixiao
f0855b7d08
Move Number to api/metric package (#706)
Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-05-10 23:44:42 -07:00
Liz Fong-Jones
bafdd1b138
Merge branch 'master' into zipkin_mock_addr 2020-05-05 14:08:30 -04:00
tensorchen
375083a085 Update mockZipkin addr from :0 to 127.0.0.1:0 2020-05-06 01:50:00 +08:00
tensorchen
bae2298a36 Rename trace.TraceID & trace.TraceIDFromHex 2020-05-03 13:48:38 +08:00
tensorchen
c6c155de6f Move SpanContext from core package into trace 2020-05-02 20:17:11 +08:00
Joshua MacDonald
4c9a29d2d7
Add a key benchmark, use reflection in key.Infer() (#679)
* Add a key benchmark, optimize SDK SetAttribute

* Use reflect in key.Infer

* Move to separate benchmark file; remove pointer test; remove dead comment

* Run go mod tidy

* Add license header

* Use the reflect scalar accessors

Co-authored-by: Liz Fong-Jones <lizf@honeycomb.io>
2020-04-30 13:06:00 -07:00
Igor German
5863f8562b
Add jaeger option that allows to specify custom http client (#671) 2020-04-28 14:35:34 -04:00
Rahul Patel
1de7f68bfc
Prepare for releasing v0.4.3 (#664) 2020-04-24 15:24:00 -07:00
Joshua MacDonald
3008c1bf02
Pass Resources through the metrics export pipeline (#659) 2020-04-24 09:44:21 -07:00
Joshua MacDonald
cd1be0e698
Use the label.Set.Equivalent value instead of an encoding in the batcher (#658) 2020-04-24 09:32:49 -07:00
Joshua MacDonald
0bb12d9b1b
New api/label package, common label set impl (#651)
* New label set API

* Checkpoint

* Remove label.Labels interface

* Fix trace

* Remove label storage

* Restore metric_test.go

* Tidy tests

* More comments

* More comments

* Same changes as 654

* Checkpoint

* Fix batch labels

* Avoid Resource.Attributes() where possible

* Update comments and restore order in resource.go

* From feedback

* From feedback

* Move iterator_test & feedback

* Strenghten the label.Set test

* Feedback on typos

* Fix the set test per @krnowak

* Nit
2020-04-23 12:10:58 -07:00
Joshua MacDonald
acb350b8f3
Support JSON marshal of Resources (#654)
* Support JSON marshal of Resources

* Add a test

* Another test

* Fix arch bug

* Fix other test
2020-04-22 14:32:58 -07:00
NiaoGe
d20fc722f2
Fix typo trace.Exporter to trace.SpanSyncer (#653)
Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-04-21 20:34:53 -07:00
Milad
ddad4d45ae
trace exporter: using type names for return values (#648)
* trace exporter: using type names for return values

* Update jaeger.go

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-04-21 20:30:57 -07:00
Krzesimir Nowak
927d9155ae
Increase the visibility of the api/key package (#650)
* Point to the convenience functions in api/key package

This is to increase the visibility of the api/key package through the
api/core package, otherwise developers often tend to miss the api/key
package altogether and write `core.Key(name).TYPE(value)` and complain
at the verbosity of such a construction. The api/key package would
allow them to write `key.TYPE(name, value)`.

* Use the api/key package where applicable

This transforms all the uses of `core.Key(name).TYPE(value)` to
`key.TYPE(name, value)`. This also should help increasing the
visibility of the api/key package for developers reading the otel-go
code.

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-04-21 20:26:51 -07:00
Oleg Shatnyuk
cf7c4e5328
fix zipkin without local endpoint with service name (#644) 2020-04-18 23:02:29 -07:00
Tyler Yahn
ebc245b388
Batch Metrics Exported From the OTLP Exporter (#626)
* Add check to sum transform for unknown NumberKind

* Initial batching

* Move CheckpointSet transform to internal package

* Add tests for the Exporter Export method

Check batching and general output exporter ResourceMetrics are correct.

* Check errors in tests

* Apply suggestions from code review

Co-Authored-By: Krzesimir Nowak <qdlacz@gmail.com>

* Use var instead of multiple calls for group IDs

* Fix otlp metric test reporting

Co-authored-by: Krzesimir Nowak <qdlacz@gmail.com>
2020-04-15 12:04:44 -07:00
Joshua MacDonald
a8f7b3247b
Remove WithKeys() option, defaultkeys batcher (#639) 2020-04-14 16:07:11 -07:00
Oncilla
bcb8b645ab
prometheus: add error wrapping (#631)
* prometheus: add error wrapping

This PR adds error wrapping to the prometheus exporter.
The added context should make it easier to follow the error path.

This is a follow-up to #622

* feedback
2020-04-13 09:48:20 -07:00
Tyler Yahn
0a9e861549
Update the OTLP exporter batching of traces (#623)
Instead of batching based on the Resource pointer which is not guaranteed
to uniquely identify common Resources, use the `String` method which is.

Renames the external test package to be identified as the integration
testing. This testing structure (the mock exporter) batches exported
resources transmitted from the resource. This is needed as there is no
guarantees that a batch will be exported in a single payload, therefore,
it is not an ideal place to add resource batch testing for the exporter
itself.

Add unit tests to ensure the Exporter is correctly batching spans by
resource.
2020-04-08 16:49:53 -07:00
Tyler Yahn
856aad92ef
Update OTLP SpanData transform (#614)
* Update OTLP SpanData transform

The ParentSpanId needs to be empty for root spans according to the OTLP
[docs](6c2a86ed2f/gen/go/trace/v1/trace.pb.go (L284-L286)).
This updates the SpanData transform function to not add the ParentSpanID
if it is not a valid span ID (which includes if it is the nil span ID
used for an unset ID).

Additionally, this adds a test to prevent regression.

* Simplify test to just check parent span ID transform

Co-authored-by: Rahul Patel <rahulpa@google.com>
2020-04-07 15:14:23 -07:00
Oncilla
6005d01854
prometheus: check return value from CheckpointSet.ForEach (#622)
This PR modifies prometheus.Collect to reflect the change introduced
by #557.

The `export{Counter,Histogram,LastValue,Summary}` methods now all return
an error instead of calling the error callback directly.
The callback is now only called on the returned error from `ForEach`.

fixes #563

Co-authored-by: Rahul Patel <rahulpa@google.com>
2020-04-07 10:58:49 -07:00
Owais Lone
446727b90d
Updated default port for OTLP exporter (#611)
OpenCensus used `55678` as the default. OTLP used `55680`. This commit fixes the incorrect default port specified for the OTLP exporter.
2020-04-02 10:04:57 -07:00
Oncilla
8ef02a61aa
prometheus: add histogram support to exporter (#601)
This PR adds histogram support to the prometheus exporter.

- Adds a new aggregator selector that returns a histogram for `MeasureKind`.
  The selector can be constructed using `simple.NewWithHistogramMeasure`
- Adds support for histogram aggregators in prometheus collect method.

With this PR, the default selector is changed to use histograms.

In order to support the prometheus histogram, the `aggregator.Histogram`
interface is extended with the `Sum` method.

fixes #487

Co-authored-by: Rahul Patel <rahulpa@google.com>
2020-04-01 14:36:37 -07:00
Rahul Patel
857e80c270
Prepare for releasing v0.4.2 (#608) 2020-03-31 12:57:37 -07:00
Bogdan Drutu
1f6ffa9ed7
Fix time conversion from internal to otlp (#606)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2020-03-31 10:32:01 -07:00
Liz Fong-Jones
02b6be15e0
Pre release v0.4.1 (#605)
* fix release script for ubuntu

* Prepare for releasing v0.4.1
2020-03-31 13:02:15 -04:00
Rahul Patel
57d5f55600
Prepare for releasing v0.4.0 (#603)
* Prepare for releasing v0.4.0

* update README.

* remove target date for released features.
2020-03-30 14:33:27 -07:00
Andrew Hsu
5d346a4190
update godoc.org links to pkg.go.dev (#602)
Banner at the top of godoc.org pages are already asking users to
redirect to pkg.go.dev as mentioned in blog post
https://blog.golang.org/pkg.go.dev-2020

Signed-off-by: Andrew Hsu <xuzuan@gmail.com>
2020-03-30 15:40:38 -04:00
Joshua MacDonald
e8546e3bc5
Remove Labelset (#595)
* Remove LabelSet frmo api/metric

* SDK tests pass

* Restore benchmarks

* All tests pass

* Remove all mentions of LabelSet

* Test RecordBatch

* Batch test

* Improves benchmark (some)

* Move the benchmark to match HEAD

* Align labels for GOARCH=386

* Add alignment test

* Disable the stress test fo GOARCH=386

* Fix bug

* Move atomic fields into their own file

* Add a TODO

* Comments

* Remove metric.Labels(...)

* FTB

Co-authored-by: Liz Fong-Jones <lizf@honeycomb.io>
2020-03-27 14:06:48 -07:00
Tyler Yahn
e7a9ba1e2e
Remove unneeded allocation on empty labels (#597)
Co-authored-by: Liz Fong-Jones <lizf@honeycomb.io>
2020-03-25 20:17:43 -07:00
Tyler Yahn
c97b4f726c
Update project License headers and checking (#596)
Update license header to standard format for source files missed prior.

Add license header to new source files.

Add Makefile check to test all `*.go` and `*.sh` files have a copyright
notice (or comment about them being auto-generated) within the first few
lines.
2020-03-25 14:47:17 -07:00
Tyler Yahn
c9dcc1be28
Move span transforms of the OTLP exporter to internal (#593)
* Move span transforms of the OTLP exporter to internal

Breakup and move functionality of the `transform_spans.go` file into
appropriate files in the `internal/transform` sub-package. This is in
preparation of using some of the overlapping functionality to implement
Resource support in the metric side of the exporter.

Adds more specific unit tests for some of the functionality transferred.
The tests removed used the exporter as a processing engine and the
replacement tests do not do this. The test found in the `oltp_test.go`
seem to comprehensively cover this type of test.

Include Link `Name` in the exporter span link and adds a test to check
for this.

Resolves #527

* Apply suggestions from code review

Co-Authored-By: Rahul Patel <rghetia@yahoo.com>

* Fix SpanData doc

* Consolidate span comparison

Co-authored-by: Rahul Patel <rghetia@yahoo.com>
Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-03-25 09:04:31 -07:00
Joshua MacDonald
4c69dd3234
Remove dogstatsd and statsd support (#591) 2020-03-24 11:00:59 -07:00
Krzesimir Nowak
d648712cf2
Kick label encoder out of sdk (#574)
* Temporarily opt-out export.Labels from label encoding stuff

* Stop passing label encoding stuff to export.Labels

* Drop label encoding stuff from SDK

* Dogstatd exporter does not need to implement label exporter anymore

* more dogstatd exporter fixes

* export labels get back to encoding stuff

in a lame way, but improvements are coming in following commits

* Get encoded labels through export.Labels

* make SDK to provide its own implementation of export.Labels

* drop dead code

* add noop label exporter

* make export simple labels immutable

* Move the default label encoder to export package

* Simplify the simple export labels a bit

* Reserve some label exporter IDs

* Document and shuffle the code a bit

* Prepare for bring the iterator benchmark test back

We can install a callback to the Batcher's process function - this is
the place where we can access the labels, and thus test the label
iterator.

* Bring back the iterator benchmarks

* Simplifications and docs

* Fix copyright to be consistent with the rest

* Fix typo

* Put reserved label encoder IDs into constants

We get fewer comments about magic numbers that way.

* Fix the label encoder as label exporter thinko
2020-03-24 09:30:12 -07:00
Rahul Patel
6f881b4400
update to proto v0.3.0 (#588) 2020-03-24 08:45:07 -07:00
Tyler Yahn
a485d0ec64
Update License header for all source files (#586)
* Update License header for all source files

- Add Apache 2.0 header to source files that did not have one.
- Update all existing headers dated to 2019 to be 2020
- Remove comma from License header to comply with the Apache 2.0
  guidelines.

* Update Copyright notice

Use the standard Copyright notices outlined by the
[CNCF](https://github.com/cncf/foundation/blob/master/copyright-notices.md#copyright-notices)
2020-03-23 22:41:10 -07:00
Rahul Patel
a1c243965e
Prepare for releasing v0.3.0 (#578) 2020-03-21 14:06:39 -07:00
Krzesimir Nowak
a01f63bec4
Replace Ordered with an iterator in export.Labels. (#567)
* Do not expose a slice of labels in export.Record

This is really an inconvenient implementation detail leak - we may
want to store labels in a different way. Replace it with an iterator -
it does not force us to use slice of key values as a storage in the
long run.

* Add Len to LabelIterator

It may come in handy in several situations, where we don't have access
to export.Labels object, but only to the label iterator.

* Use reflect value label iterator for the fixed labels

* add reset operation to iterator

Makes my life easier when writing a benchmark. Might also be an
alternative to cloning the iterator.

* Add benchmarks for iterators

* Add import comment

* Add clone operation to label iterator

* Move iterator tests to a separate package

* Add tests for cloning iterators

* Pass label iterator to export labels

* Use non-addressable array reflect values

By not using the value created by `reflect.New()`, but rather by
`reflect.ValueOf()`, we get a non-addressable array in the value,
which does not infer an allocation cost when getting an element from
the array.

* Drop zero iterator

This can be substituted by a reflect value iterator that goes over a
value with a zero-sized array.

* Add a simple iterator that implements label iterator

In the long run this will completely replace the LabelIterator
interface.

* Replace reflect value iterator with simple iterator

* Pass label storage to new export labels, not label iterator

* Drop label iterator interface, rename storage iterator to label iterator

* Drop clone operation from iterator

It's a leftover from interface times and now it's pointless - the
iterator is a simple struct, so cloning it is a simple copy.

* Drop Reset from label iterator

The sole existence of Reset was actually for benchmarking convenience.
Now we can just copy the iterator cheaply, so a need for Reset is no
more.

* Drop noop iterator tests

* Move back iterator tests to export package

* Eagerly get the reflect value of ordered labels

So we won't get into problems when several goroutines want to iterate
the same labels at the same time. Not sure if this would be a big
deal, since every goroutine would compute the same reflect.Value, but
concurrent write to the same memory is bad anyway. And it doesn't cost
us any extra allocations anyway.

* Replace NewSliceLabelIterator() with a method of LabelSlice

* Add some documentation

* Documentation fixes
2020-03-19 15:01:34 -07:00
Joshua MacDonald
d8682c1999
Refactor the SDK helpers, create MeterImpl (#560)
* Create MeterImpl interface

* Checkpoint w/ sdk.go building

* Checkpoint working on global

* api/global builds (test fails)

* Test fix

* All tests pass

* Comments

* Add two tests

* Comments and uncomment tests

* Precommit part 1

* Still working on tests

* Lint

* Add a test and a TODO

* Cleanup

* Lint

* Interface()->Implementation()

* Apply some feedback

* From feedback

* (A)Synchronous -> (A)Sync

* Add a missing comment

* Apply suggestions from code review

Co-Authored-By: Krzesimir Nowak <qdlacz@gmail.com>

* Rename a variable

Co-authored-by: Krzesimir Nowak <qdlacz@gmail.com>
2020-03-19 12:02:46 -07:00
Rahul Patel
80b720a771
update stdout trace with resource. (#558)
* update stdout trace with resource.

* convert resource to span attributes.

* remove resource reference after converting to Span Attributes.
2020-03-16 16:48:35 -07:00
Tyler Yahn
435c39aab4
Update OTLP exporter with latest proto (#550)
[Upstream
changes](https://github.com/open-telemetry/opentelemetry-proto/pull/126)

Co-authored-by: Rahul Patel <rahulpa@google.com>
2020-03-16 16:43:54 -07:00
Rahul Patel
74a528520b
update jaeger exporter to translate resources to tags. (#551) 2020-03-16 16:38:21 -07:00
ET
217a97d9b6
Replace ErrNoLastValue and ErrEmptyDataSet by ErrNoData (#557)
Handle ForEach returning an error
2020-03-16 16:28:33 -07:00
Rahul Patel
6ada85adba
add resource option to Provider. (#545)
- update otlp exporter to export resources.
2020-03-13 13:07:36 -07:00
Tyler Yahn
cba1664b46
Add metrics support to the OTLP exporter (#544)
* Initial metrics addition to the OTLP exporter

* Fixes

Update to incorporate merged changes.
Fix lint issues.

* Add sum float64 transform unit test

* Fix static check

* Update comments

Fix malformed License header.
Add documentation for new transform functions.
Remove errant TODO.

* Fix test failures and handle ErrEmptyDataSet

Use `assert.NoError` instead of `assert.Nil` to correctly display
checked errors.

Use the result of `assert.NoError` to guard against `nil` pointer
dereferences.

Add check to skip `Record`s that return an `ErrEmptyDataSet` error and
include test to check this error is correctly returned from the
transform package.

Co-authored-by: Rahul Patel <rahulpa@google.com>
2020-03-13 11:42:20 -07:00
Yoshi Yamaguchi
fcc4aca8c7
Fix typo in module name (#548) 2020-03-12 20:48:49 -07:00
Joshua MacDonald
23e65ac79d
Remove metric options; rename "counter" aggregator to "sum" (#541)
* Remove options (mostly)

* Rename counter aggregator to 'sum'

* Fix prometheus test

* Rewordings from feedback
2020-03-11 20:21:34 -07:00
Krzesimir Nowak
d9210f5676
Zipkin exporter (#495)
* Add zipkin exporter

The zipkin exporter implements the SpanBatcher interface. It follows
the current-at-the-time-of-writing document about conversion from
OpenTelemetry span data to Zipkin spans. Which means that endpoint
information is not yet filled.

* Fix typo in docs

* Add a zipkin example

This sends span information to a locally running zipkin collector.
Currently I have a problem getting the collector to show me the spans
after accepting them with HTTP 202. Not sure if this is because of
missing endpoint information.

* Make gitignore consistent

The fixed paths should be prefixed with a slash. The "relative" paths
mean that git will ignore all the files that end with the path.

* Add tests for zipkin exporter
2020-03-11 14:49:02 -07:00
Joshua MacDonald
4047c0877a
Introduce metric constructor errors, MeterMust wrapper (#529)
* Update api for Must constructors, with SDK helpers

* Update for Must constructors, leaving TODOs about global errors

* Add tests

* Move Must methods into metric.Must

* Apply the feedback

* Remove interfaces

* Remove more interfaces

* Again...

* Remove a sentence about a dead inteface
2020-03-11 11:57:57 -07:00
Gustavo Silva Paiva
85751428a3
add shorter version for global providers (#538) 2020-03-11 08:23:32 -07:00
Joshua MacDonald
9674c81cb7
Drop the gauge instrument (#537)
* drop gauge instrument

* Restore the benchmark and stress test for lastvalue aggregator, but remove monotonic last-value support

* Rename gauge->lastvalue and remove remaining uses of the word 'gauge'

Co-authored-by: Krzesimir Nowak <krzesimir@kinvolk.io>
2020-03-10 16:00:37 -07:00
Matej Gera
fe0099fb3d
[tracing] add simplified export pipeline setup for Jaeger (#459)
* add simplified export pipeline setup for Jaeger

* add With* options to configure SDK options.

* add test for WithRegistration and WithSDK

* rename Registeration with RegisterGlobal

* rename WithRegistration to RegisterAsGlobal

Co-authored-by: rahulpa <rahulpa@google.com>
Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-03-10 13:58:45 -07:00
Nail Islamov
af5428829b
Update OTLP protos, fix imports (#532)
* Update OTLP protos, fix imports

* Update go.sum

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
2020-03-09 22:09:40 -07:00
Joshua MacDonald
3bf3927eb5
Add status message parameter (#524)
* Add status message parameter

* Cleanups around use of codes.OK

* Update for status message
2020-03-07 10:38:59 -08:00
Rahul Patel
5850278197
opentelemetry collector trace exporter (#497)
* opentelemetry collector exporter

- missing load test
- missing resources

* fix review comments.

* add test for each SpanKind and Attribute Type.

* rename otelcol to otlp

* move exporter/trace/otlp to exporters/otlp

* more review comments.

* add alignment test.

* pass context to uploadSpans
2020-03-06 22:01:02 -08:00