You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Return merged Resource on schema conflict
* Add changes to changelog
* Doc returned resource to have no schema URL
* Refactor Merge based on feedback
* Add the schema URLs to the returned error
* Ensure no schema URL when merge conflict on detect
* Replaced isErr with wantErr in TestNew
* Update sdk/resource/auto_test.go
Co-authored-by: Robert Pająk <pellared@hotmail.com>
* Update TestDetect based on feedback
---------
Co-authored-by: Robert Pająk <pellared@hotmail.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,6 +13,15 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
13
13
- Add `WithEndpointURL` option to the `exporters/otlp/otlpmetric/otlpmetricgrpc`, `exporters/otlp/otlpmetric/otlpmetrichttp`, `exporters/otlp/otlptrace/otlptracegrpc` and `exporters/otlp/otlptrace/otlptracehttp` packages. (#4808)
14
14
- Experimental exemplar exporting is added to the metric SDK.
15
15
See [metric documentation](./sdk/metric/EXPERIMENTAL.md#exemplars) for more information about this feature and how to enable it. (#4871)
16
+
-`ErrSchemaURLConflict` is added to `go.opentelemetry.io/otel/sdk/resource`.
17
+
This error is returned when a merge of two `Resource`s with different (non-empty) schema URL is attepted. (#4876)
18
+
19
+
### Changed
20
+
21
+
- The `Merge` and `New` functions in `go.opentelemetry.io/otel/sdk/resource` now returns a partial result if there is a schema URL merge conflict.
22
+
Instead of returning `nil` when two `Resource`s with different (non-empty) schema URLs are merged the merged `Resource`, along with the new `ErrSchemaURLConflict` error, is returned.
23
+
It is up to the user to decide if they want to use the returned `Resource` or not.
24
+
It may have desired attributes overwritten or include stale semantic conventions. (#4876)
0 commit comments