* Pool sortables used to create attribute sets
* Move sync pool to attribute pkg
* Add change to changelog
* Fix comment
* Apply suggestions from code review
Co-authored-by: Peter Liu <lpfvip2008@gmail.com>
* Update sdk/metric/instrument.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update comment based on feedback
* Apply feedback
---------
Co-authored-by: Peter Liu <lpfvip2008@gmail.com>
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* new stdoutmetric encoder with ignore timestamp
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
* refactor to avoid using a dedicated encoder
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
* remove useless encoder code
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
* dont't change the original data
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
* Update exporters/stdout/stdoutmetric/exporter.go
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* complete test data and add changelog entry
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
* Move changelog entry to unreleased
---------
Signed-off-by: Peter Liu <lpfvip2008@gmail.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
Co-authored-by: Tyler Yahn <codingalias@gmail.com>
* Update Detect and New to wrap errors
* Add TestNewWrapedError
Test that New returns an error that can be unwrapped.
* Add changes to changelog
* Clarify and simplify errors
* Move ErrorHandler impl to internal
To avoid the import cycle, the otel/metric package needs to not import
otel. To achieve this, the error handling implementation is moved to the
otel/internal/global package where both can import the needed
functionality.
* Add global metric to go.opentelemetry.io/otel
* Crosslink and update to global metric in otel
* Add changes to changelog
* Set PR number in changelog
* Add global metric unit tests
* Rename MeterProivder() to GetMeterProivder()
* Add TODO to remove nolint comments
* Bump mod versions
* Add bridge/opentracing/test to versions.yaml
* Prepare stable-v1 for version v1.14.0
* Prepare experimental-metrics for version v0.37.0
* Prepare experimental-schema for version v0.0.4
* Update changelog
* Replace Unit from metric/unit with string
Deprecate the units package. This package will not be included in the
metric GA.
* Add changes to changelog
* Accept scope attributes during Tracer creation
The OTel specification requires the instrumentation attributes are
accepted by the API for the Tracer. This adds a TracerOption to satisfy
that requirement.
* Do no silently drop unknown schema data
* Add entry to changelog
* Add PR number to changelog
---------
Co-authored-by: Chester Cheung <cheung.zhy.csu@gmail.com>
Co-authored-by: Aaron Clawson <3766680+MadVikingGod@users.noreply.github.com>
* Merge instrument cache to inserter
The current pipeline resolution path will only add the resolved
aggregators to the pipeline when it creates one (cache miss). It will
not add it if there is a cache hit. This means (since we cache
instruments at the meter level, not the pipeline level) the first reader
in a multiple-reader setup is the only one that will collect data for
that aggregator. All other readers will have a cache hit and nothing is
added to the pipeline. This is causing #3720.
This resolves#3720 by moving the instrument caching into the inserter.
This means aggregators are cached at the reader level, not the meter.
* Rename aggCV to aggVal
---------
Co-authored-by: Chester Cheung <cheung.zhy.csu@gmail.com>
* Accept scope attr during Meter creation
* Fix lint
* Add changes to changelog
* Return a Set from InstrumentationAttributes
Likely these attributes will be stored as a Set in the SDK. Don't cause
two conversions because we return a slice here.
* Add config tests
* Fix lint
* Bump CI default version of Go to 1.20
* Use crypto/rand in Jaeger exporter testing
* Use crypto/rand Reader in otlp exporters
* Remove use of dep rand.Seed in prometheus exporter
* Update changelog with public changes
* Quote DEFAULT_GO_VERSION value
* Update .github/workflows/ci.yml
* Update CHANGELOG.md
Co-authored-by: Damien Mathieu <42@dmathieu.com>
---------
Co-authored-by: Damien Mathieu <42@dmathieu.com>
* update versions.yaml for release
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Prepare stable-v1 for version v1.13.0
* Prepare experimental-metrics for version v0.36.0
* Update CHANGELOG
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
---------
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update module versions
* Prepare stable-v1 for version v1.12.0
* Prepare experimental-metrics for version v0.35.0
* Prepare experimental-schema for version v0.0.4
* Update the CHANGELOG
* Undo bump to experimental-schema
Revert to original version as nothing has changed.
* Fix PR number in changelog
* Move change from #3497 into current release
* Use Extrema type for Histogram min/max
* Add case for Extrema in AssertHasAttributes
* Add changes to changelog
* Add NewExtrema
* Add metricdatatest tests
* Use getter for Extrema
* Fix Extrema doc language
* Correct dataset to be one word
* Ensure multiple extrema are tested in a dataset
* Update RegisterCallback and Callback decls
RegisterCallback accept variadic Asynchronous instruments instead of a
slice.
Callback accept an observation result recorder to ensure instruments
that are observed by a callback.
* Update global impl
* Update noop impl
* Update SDK impl
* Fix prometheus example
* Fix metric API example_test
* Remove unused registerabler
* Rename ObservationRecorder to MultiObserver
* Update Callback documentation about MultiObserver
* Remove the Observe method from async inst
* Revert to iface for Observers
* Fix async inst docs
* Update global async delegate race test
* Restore removed observe doc
* Remove TODO
* Remove stale comment
* Update changelog
* Combine spatially aggregated precomputed vals
Fix#3439
When an attribute filter drops a distinguishing attribute during the
aggregation of a precomputed sum add that value to existing, instead of
just setting the value as an override (current behavior).
* Ignore false positive lint error and test method
* Add fix to changelog
* Handle edge case of exact set after filter
* Fix filter and measure algo for precomp
* Add tests for precomp sums
* Unify precomputedMap
* Adds example from supplimental guide
* Fixes for lint
* Update sdk/metric/meter_example_test.go
* Fix async example test
* Reduce duplicate code in TestAsynchronousExample
* Clarify naming and documentation
* Fix spelling errors
* Add a noop filter to default view
Co-authored-by: Chester Cheung <cheung.zhy.csu@gmail.com>
Co-authored-by: Aaron Clawson <3766680+MadVikingGod@users.noreply.github.com>
* Update RegisterCallback and Callback declerations
RegisterCallback accepts variadic Asynchronous instruments instead of a
slice.
Callback accepts an observation result recorder to ensure instruments
that are observed by a callback.
* Update global, noop, SDK implementations
* Fix examples
* Add changes to changelog
* Test RegisterCallback for invalid observers
* Test callbacks from foreign sources not collected
* Support registering delegating instruments
* Restructure RegisterCallback method
Instead of accepting instruments to register the callback with as a
slice, accept them as variadic arguments.
* Add changes to changelog
* Add PR number to changes