* Split stdout exporter into stdouttrace and stdoutmetric
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Remove unused options from stdouttrace and stdoutmetric exporters
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update stdout exporter references in website docs
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update docs to include correct import paths, properly describe exporter scope
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Remove pointless options to disable signals from what are now single-signal exporters
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Rename exporters/metric/prometheus
* Rename exporters/trace/jaeger
* Rename exporters/trace/zipkin
* Fix dependabot config and make test
* Update README docs
* Deprecate exporters instead of remove them
* Update dependabot with old modules
* Run crosslink
* Add lint override for known deprecated pkg
* Update PR number
* Remove trace export support from exporters/otlp
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update otlp exporter example test to use metric/global package
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update CHANGELOG
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* completely excise exporters/otlp
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Declare internal/metric module to version it separately
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Remove dependency on metrics module from soon-to-be-stable modules
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Add PR ID to CHANGELOG
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* rename metric/oteltest to metric/metrictest
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Fix metrictest package name in CHANGELOG
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Move global code to toplevel package
* Move version function to toplevel package
* Update changelog
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* 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
* Make metric test helpers public
* Move everything metric test related to api/metric/metrictest
* Unify metric measurement assertions
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* Remove the push controller named Meter map
* Checkpoint
* Remove Provider impls
* Add a test
* Expose Provider() getter instead of implementing the interface
* api/metric changes from jmacd:jmacd/batch_obs_2
* Add an SDK test
* Use a single collector method
* Two fixes
* Comments; embed AsyncRunner
* Comments
* Comment fix
* More comments
* Renaming for clarity
* Renaming for clarity (fix)
* Lint
* 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>
* Add skeleton uniqueness checker
* Fix the build w/ new code in place
* Add sync tests
* More test
* Implement global uniqueness checking
* Set the library name
* Ensure ordered global initialization
* Use proper require statement for errors
* Comment
* Apply feedback fixes
* Comment and rename from feedback
* 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)
* 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>
* 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
* 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>
* wip: observers
* wip: float observers
* fix copy pasta
* wip: rework observers in sdk
* small fix in global meter
* wip: aggregators and selectors
* wip: monotonicity option for observers
* some refactor
* wip: docs
needs more package docs (especially for api/metric and sdk/metric)
* fix ci
* Fix copy-pasta in docs
Co-Authored-By: Mauricio Vásquez <mauricio@kinvolk.io>
* recycle unused recorders in observers
if a recorder for a labelset is unused for a second collection cycle
in a row, drop it
* unregister
* thread-safe set callback
* Fix docs
* Revert "wip: aggregators and selectors"
This reverts commit 37b7d05aed5dc90f6d5593325b6eb77494e21736.
* update selector
* tests
* Rework number equality
Compare concrete numbers, so we can get actual numbers in the error
message when they are not equal, not some uint64 representation. This
also uses InDelta for comparing floats.
* Ensure that Observers are registered in the same order
* Run observers in fixed order
So the tests can be reproducible - iterating a map made the order of
measurements random.
* Ensure the proper alignment of the delegates
This wasn't checked at all. After adding the checks, the test-386
failed.
* Small tweaks to the global meter test
* Ensure proper alignment of the callback pointer
test-386 was complaining about it
* update docs
* update a TODO
* address review issues
* drop SetCallback
Co-authored-by: Mauricio Vásquez <mauricio@kinvolk.io>
Co-authored-by: Rahul Patel <rghetia@yahoo.com>
* Add comments on needed filed alignment
Add comment about alignment requirements to all struct fields who's
values are passed to 64-bit atomic operations.
Update any struct's field ordering if one or more of those fields has
alignment requirements to support 64-bit atomic operations.
* Add 64-bit alignment tests
Most `struct` that have field alignment requirements are now statically
validated prior to testing. The only `struct`s not validated that have
these requirements are ones defined in tests themselves where multiple
`TestMain` functions would be needed to test them. Given the fields are
already identified with comments specifying the alignment requirements
and they are in the test themselves, this seems like an OK omission.
Co-authored-by: Liz Fong-Jones <elizabeth@ctyalcove.org>
* Initial skeleton
* Revert noop provider removal
* Checkpoint
* Checkpoint
* Implement Bound instrument and LabelSet
* Add test
* Add a benchmark
* Add a release test
* Document LabelSetDelegator
* Lint and comments
* Add a second Meter test; fix typo; add a panic
* Add a test for the builtin SDK
* Address feedback