1
0
mirror of https://github.com/open-telemetry/opentelemetry-go.git synced 2025-07-15 01:04:25 +02:00

Replace use of old term label with attribute (#2790)

* Replace use of old term label with attribute

The specification has unified on the term attribute to describe
key-value pairs. There exist still many hold-overs of the use of the
term label. This updates those uses or deprecates exported types and
functions in favor of renamed forms.

* fix infinite recursion

* Remove backticks from attribute set docs

* Remove LabelFilterSelector entirely

* Remove Metadata.Labels instead of deprecate

* Update changelog with public changes

* Revert OC err msg
This commit is contained in:
Tyler Yahn
2022-04-18 07:31:31 -07:00
committed by GitHub
parent 1884de2b4b
commit a8ea3dbb46
42 changed files with 555 additions and 550 deletions

View File

@ -159,8 +159,8 @@ func TestUniqueness(t *testing.T) {
for _, tc := range cases {
cpy := make([]attribute.KeyValue, len(tc.kvs))
copy(cpy, tc.kvs)
distinct, uniq := attribute.NewSetWithFiltered(cpy, func(label attribute.KeyValue) bool {
return tc.keyRe.MatchString(string(label.Key))
distinct, uniq := attribute.NewSetWithFiltered(cpy, func(attr attribute.KeyValue) bool {
return tc.keyRe.MatchString(string(attr.Key))
})
full := attribute.NewSet(uniq...)