* fix type in metric example test
Signed-off-by: Pulak Kanti Bhowmick <pkbhowmick007@gmail.com>
* handle error in metric example test
Signed-off-by: Pulak Kanti Bhowmick <pkbhowmick007@gmail.com>
* update counter example
Signed-off-by: Pulak Kanti Bhowmick <pkbhowmick007@gmail.com>
* handle the err only
Signed-off-by: Pulak Kanti Bhowmick <pkbhowmick007@gmail.com>
---------
Signed-off-by: Pulak Kanti Bhowmick <pkbhowmick007@gmail.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* Bump versions.yaml
* Prepare stable-v1 for version v1.17.0
* Prepare experimental-metrics for version v0.40.0
* Prepare experimental-schema for version v0.0.5
* Update changelog
* Update changelog release header
* Add allow/deny attr filters
* Revert "Replace `Stream.AttributeFilter` with `AllowAttributeKeys` (#4288)"
This reverts commit 1633c74aea.
* Rename new attr filter funcs
Do not include the term "Attribute" in a creation function of the
"attribute" pkg.
* Update the AttributeFilter field documentation
* Add tests for filter creation funcs
* Add change to changelog
* Apply feedback
* Use NewDenyKeysFilter for allow-all and deny-list filters
* Remove links from field docs
These links do not render.
---------
Co-authored-by: Chester Cheung <cheung.zhy.csu@gmail.com>
A guard was added in #4446 to prevent non-normal float64 from being
recorded. This was added in the low-level `record` method meaning that
the higher-level `measure` method will still keep a record of the
invalid value measurement, just with a zero-value.
This fixes that issue by moving the guard to the `measure` method.
Both functions receive parameters from an expoHistogramDataPoint and are
only ever used by other methods of an expoHistogramDataPoint. Make the
functions methods of expoHistogramDataPoint so the parameter arguments
can be dropped and the functions are scoped to the type they are used
for.
Co-authored-by: Aaron Clawson <3766680+MadVikingGod@users.noreply.github.com>
* Deprecate the aggregation pkg
* Decouple the internal/aggregate from aggregation pkg
* Add Aggregation to the metric pkg
* Do not use sdk/metric/aggregation in stdoutmetric exporter
* Update all generated templates
* Update prom exporter
* Fix view example
* Add changes to changelog
* Update CHANGELOG.md
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Rename Sum to AggregationSum
* Fix comments
* Centralize validation of aggregation in pipeline
* Remove validation of agg in manual_reader selector opt
* Fix merge
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
Bump github.com/golangci/golangci-lint from 1.53.3 to 1.54.1 in /internal/tools
Bump go.opentelemetry.io/build-tools/gotmpl from 0.10.0 to 0.11.0 in /internal/tools
Bump golang.org/x/tools from 0.11.1 to 0.12.0 in /internal/tools
Bump github.com/openzipkin/zipkin-go from 0.4.1 to 0.4.2 in /exporters/zipkin
* Stop generating otlptrace/internal and deprecate
* Remove the tracetransform templates
They are no longer used.
* Add change stub to changelog
* Add PR number to changelog
* Add internaltest templates
* Generate internaltest using gotmpl
* Generate the sdk/internal/internaltest pkg
* Use sdk/internal/internaltest in sdk module
* Generate exporters/jaeger/internal/internaltest pkg
* Use exporters/jaeger/internal/internaltest in jaeger exporter
* Generate the exporters/zipkin/internal/internaltest pkg
* Use local internaltest in zipkin exporter
* Fix import path name in trace test
* Deprecate the otlpmetric/internal package and sub-packages
* Add stub to changelog
* Add PR number to changelog stubs
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Deprecate the otlp/internal package and all sub-packages
* Add deprecation to changelog
* No lint deprecated pkg use in otlpmetric
* Remove the unused header*.go files from otlptrace
* Use template wrappederror in otlptrace
* Add back removed header.go
* Replace use of WrapTracesError with fmt.Errorf
* Revert otlptrace/internal to main
* Deprecate retry module
* handle no content responses for otlpmetric exporter
* handle no content responses for otlptraces http exporter
* add changelog entry
* add a ResponseStatus attribute rather than using error
* accept any status code between 200 and 299
* rename i to code
* switch require to assert
* shutdown the client in defer
---------
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* Fix ASAN bug with emptyAttributes.
If mutliple instantiations of a Resources struct are happening
in parallel, they can end up modifying the same underlying resource.
* Capture literal
* add test
* remove unwanted change
* Update sdk/resource/resource_test.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update sdk/resource/resource_test.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update sdk/resource/resource_test.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update sdk/resource/resource_test.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Add changelog.
* Update CHANGELOG.md
Co-authored-by: Robert Pająk <pellared@hotmail.com>
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
* Upgrade all use of semconv to v1.21.0
* Add change to changelog
* Add AIX and ZOS OS support
* Upgrade semconv for merged changes
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Generate otlpmetrichttp/internal with gotmpl
* Use local internal pkg for otlpmetrichttp
* Add changes to changelog
* Fix rendered envconfig_test.go file name
Bump golang.org/x/sys from 0.10.0 to 0.11.0 in /sdk
Bump golang.org/x/tools from 0.11.0 to 0.11.1 in /internal/tools
Bump go.opentelemetry.io/build-tools/crosslink from 0.10.0 to 0.11.0 in /internal/tools
Bump go.opentelemetry.io/build-tools/semconvgen from 0.10.0 to 0.11.0 in /internal/tools
Bump go.opentelemetry.io/build-tools/dbotconf from 0.10.0 to 0.11.0 in /internal/tools
Bump go.opentelemetry.io/build-tools/multimod from 0.10.0 to 0.11.0 in /internal/tools
* Adds Exponential Histograms aggregator
* Added aggregation to the pipeline.
Adjust to new bucket
* Add no allocation if cap is available.
* Expand tests
* Fix lint
* Fix 64 bit math on 386 platform.
* Fix tests to work in go 1.19.
Fix spelling error
* fix codespell
* Add example
* Update sdk/metric/aggregation/aggregation.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update sdk/metric/aggregation/aggregation.go
* Update sdk/metric/aggregation/aggregation.go
* Changelog
* Fix move
* Address feedback from the PR.
* Update expo histo to new aggregator format.
* Fix lint
* Remove Zero Threshold from config of expo histograms
* Remove DefaultExponentialHistogram()
* Refactor GetBin, and address PR Feedback
* Address PR feedback
* Fix comment in wrong location
* Fix misapplied PR feedback
* Fix codespell
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
Co-authored-by: Chester Cheung <cheung.zhy.csu@gmail.com>
* Add shared otlpmetric templates
* Generate otlpmetricgrpc/internal with gotmpl
* Use local internal in otlpmetricgrpc
* Add decoupling change to changelog
* Use template retry pkg in otlpconfig
* Template out all otlptrace internal
* Add envconfig pkg to otlptrace/internal
* Generate otlptrace/internal/otlpconfig
* Revert templatizing otlptracegrpc
* Add changes to changelog
* Add partialsuccess to internal shared
* Use gotmpl to generate otlptracegrpc/internal
* Add changes to changelog