Skip to content

Commit

Permalink
[chore][internal/core] Make idutils package publicly available
Browse files Browse the repository at this point in the history
Signed-off-by: odubajDT <[email protected]>
  • Loading branch information
odubajDT committed Jan 10, 2025
1 parent 2956bb9 commit c0df706
Show file tree
Hide file tree
Showing 48 changed files with 210 additions and 33 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ internal/tools/ @open-telemetry/collector-cont

pkg/batchperresourceattr/ @open-telemetry/collector-contrib-approvers @atoulme @dmitryax
pkg/batchpersignal/ @open-telemetry/collector-contrib-approvers @jpkrohling
pkg/core/idutils/ @open-telemetry/collector-contrib-approvers @odubajDT
pkg/datadog/ @open-telemetry/collector-contrib-approvers @mx-psi @dineshg13 @liustanley @songy23 @mackjmr @ankitpatel96 @jade-guiton-dd
pkg/experimentalmetricmetadata/ @open-telemetry/collector-contrib-approvers @dmitryax
pkg/golden/ @open-telemetry/collector-contrib-approvers @djaglowski @atoulme
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ body:
- internal/tools
- pkg/batchperresourceattr
- pkg/batchpersignal
- pkg/core/idutils
- pkg/datadog
- pkg/experimentalmetricmetadata
- pkg/golden
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ body:
- internal/tools
- pkg/batchperresourceattr
- pkg/batchpersignal
- pkg/core/idutils
- pkg/datadog
- pkg/experimentalmetricmetadata
- pkg/golden
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/other.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ body:
- internal/tools
- pkg/batchperresourceattr
- pkg/batchpersignal
- pkg/core/idutils
- pkg/datadog
- pkg/experimentalmetricmetadata
- pkg/golden
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/unmaintained.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ body:
- internal/tools
- pkg/batchperresourceattr
- pkg/batchpersignal
- pkg/core/idutils
- pkg/datadog
- pkg/experimentalmetricmetadata
- pkg/golden
Expand Down
1 change: 1 addition & 0 deletions cmd/otelcontribcol/builder-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ replaces:
- github.com/open-telemetry/opentelemetry-collector-contrib/receiver/journaldreceiver => ../../receiver/journaldreceiver
- github.com/open-telemetry/opentelemetry-collector-contrib/exporter/logzioexporter => ../../exporter/logzioexporter
- github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal
- github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils
- github.com/open-telemetry/opentelemetry-collector-contrib/receiver/k8seventsreceiver => ../../receiver/k8seventsreceiver
- github.com/open-telemetry/opentelemetry-collector-contrib/receiver/k8sclusterreceiver => ../../receiver/k8sclusterreceiver
- github.com/open-telemetry/opentelemetry-collector-contrib/processor/transformprocessor => ../../processor/transformprocessor
Expand Down
2 changes: 2 additions & 0 deletions connector/datadogconnector/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -384,3 +384,5 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/pdata
replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/experimentalmetricmetadata => ../../pkg/experimentalmetricmetadata

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/datadog => ../../pkg/datadog

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils
3 changes: 3 additions & 0 deletions exporter/awskinesisexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/openzipkin/zipkin-go v0.4.3 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
go.opentelemetry.io/collector/config/configtelemetry v0.117.0 // indirect
Expand Down Expand Up @@ -91,6 +92,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

retract (
v0.76.2
v0.76.1
Expand Down
2 changes: 2 additions & 0 deletions exporter/datadogexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/aws/e

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/common => ../../internal/common

replace github.com/open-telemetry/opentelemetry-collector-contrib/processor/k8sattributesprocessor => ../../processor/k8sattributesprocessor
Expand Down
2 changes: 2 additions & 0 deletions exporter/datadogexporter/integrationtest/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -461,3 +461,5 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/pdata
replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/experimentalmetricmetadata => ../../../pkg/experimentalmetricmetadata

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/datadog => ../../../pkg/datadog/

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../../pkg/core/idutils
3 changes: 3 additions & 0 deletions exporter/elasticsearchexporter/integrationtest/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ require (
github.com/open-telemetry/opentelemetry-collector-contrib/exporter/zipkinexporter v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/pdatautil v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/golden v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil v0.117.0 // indirect
Expand Down Expand Up @@ -236,6 +237,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/commo

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/sharedcomponent => ../../../internal/sharedcomponent

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/golden => ../../../pkg/golden
Expand Down
3 changes: 3 additions & 0 deletions exporter/kafkaexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ require (
github.com/mitchellh/reflectwalk v1.0.2 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.116.1-0.20241220212031-7c2639723f67 // indirect
github.com/pierrec/lz4/v4 v4.1.22 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect
Expand Down Expand Up @@ -115,6 +116,8 @@ require (

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka => ../../internal/kafka

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/batchpersignal => ../../pkg/batchpersignal
Expand Down
3 changes: 3 additions & 0 deletions exporter/logzioexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/pierrec/lz4/v4 v4.1.22 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/rs/cors v1.11.1 // indirect
Expand Down Expand Up @@ -90,6 +91,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

retract (
v0.76.2
v0.76.1
Expand Down
3 changes: 3 additions & 0 deletions exporter/pulsarexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ require (
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/mtibben/percent v0.2.1 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.116.0 // indirect
github.com/pierrec/lz4 v2.6.1+incompatible // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
Expand Down Expand Up @@ -105,6 +106,8 @@ require (

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/jaeger => ../../pkg/translator/jaeger

retract (
Expand Down
3 changes: 3 additions & 0 deletions exporter/sapmexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
go.opentelemetry.io/collector/config/configtelemetry v0.117.0 // indirect
go.opentelemetry.io/collector/consumer/consumertest v0.117.0 // indirect
Expand Down Expand Up @@ -84,6 +85,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

retract (
v0.76.2
v0.76.1
Expand Down
3 changes: 3 additions & 0 deletions exporter/zipkinexporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/pierrec/lz4/v4 v4.1.22 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/rs/cors v1.11.1 // indirect
Expand Down Expand Up @@ -89,6 +90,8 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/commo

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/zipkin => ../../pkg/translator/zipkin

replace github.com/open-telemetry/opentelemetry-collector-contrib/receiver/zipkinreceiver => ../../receiver/zipkinreceiver
Expand Down
3 changes: 3 additions & 0 deletions extension/encoding/jaegerencodingextension/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
go.opentelemetry.io/collector/config/configtelemetry v0.117.0 // indirect
go.opentelemetry.io/collector/pdata/pprofile v0.117.0 // indirect
Expand All @@ -55,6 +56,8 @@ require (

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil => ../../../pkg/pdatautil

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatatest => ../../../pkg/pdatatest
Expand Down
3 changes: 3 additions & 0 deletions extension/encoding/zipkinencodingextension/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.117.0 // indirect
github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils v0.117.0 // indirect
github.com/openzipkin/zipkin-go v0.4.3 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
go.opentelemetry.io/collector/config/configtelemetry v0.117.0 // indirect
Expand All @@ -56,6 +57,8 @@ require (

replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../../internal/coreinternal

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils => ../../../pkg/core/idutils

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/zipkin => ../../../pkg/translator/zipkin

replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil => ../../../pkg/pdatautil
Expand Down
1 change: 1 addition & 0 deletions pkg/core/idutils/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
include ../../../Makefile.Common
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

package idutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal/idutils"
package idutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils"

import (
"encoding/binary"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
//
// Functions in big_endian_converter.go help converting uint64 ids to TraceID
// and SpanID using big endian, and vice versa.
package idutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal/idutils"
package idutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils"
30 changes: 30 additions & 0 deletions pkg/core/idutils/go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
module github.com/open-telemetry/opentelemetry-collector-contrib/pkg/core/idutils

go 1.22.0

require (
github.com/stretchr/testify v1.10.0
go.opentelemetry.io/collector/pdata v1.22.1-0.20241220212031-7c2639723f67
go.uber.org/goleak v1.3.0
)

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/text v0.21.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241015192408-796eee8c2d53 // indirect
google.golang.org/grpc v1.69.0 // indirect
google.golang.org/protobuf v1.36.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

retract (
v0.76.2
v0.76.1
v0.65.0
)
Loading

0 comments on commit c0df706

Please sign in to comment.