From ac30ac086732bd86d8ecb90a2b9dc3bae1f9ec5a Mon Sep 17 00:00:00 2001 From: Trece Wicklander-Bryant Date: Tue, 21 May 2024 16:35:37 -0700 Subject: [PATCH] chore: Moves internal/kafka To pkg/kafka --- .chloggen/move_internal_kafka_to_pkg.yaml | 27 +++++++++++++++++++ .github/CODEOWNERS | 2 +- .github/ISSUE_TEMPLATE/bug_report.yaml | 2 +- .github/ISSUE_TEMPLATE/feature_request.yaml | 2 +- .github/ISSUE_TEMPLATE/other.yaml | 2 +- .github/ISSUE_TEMPLATE/unmaintained.yaml | 2 +- cmd/otelcontribcol/builder-config.yaml | 2 +- exporter/kafkaexporter/config.go | 2 +- exporter/kafkaexporter/config_test.go | 2 +- exporter/kafkaexporter/go.mod | 4 +-- exporter/kafkaexporter/kafka_exporter.go | 2 +- exporter/kafkaexporter/kafka_exporter_test.go | 2 +- {internal => pkg}/kafka/Makefile | 0 {internal => pkg}/kafka/authentication.go | 4 +-- .../kafka/authentication_test.go | 0 {internal => pkg}/kafka/awsmsk/doc.go | 2 +- .../kafka/awsmsk/iam_scram_client.go | 2 +- .../kafka/awsmsk/iam_scram_client_test.go | 0 .../kafka/awsmsk/package_test.go | 0 {internal => pkg}/kafka/go.mod | 2 +- {internal => pkg}/kafka/go.sum | 0 {internal => pkg}/kafka/metadata.yaml | 0 {internal => pkg}/kafka/package_test.go | 0 {internal => pkg}/kafka/scram_client.go | 2 +- receiver/kafkametricsreceiver/config.go | 2 +- receiver/kafkametricsreceiver/config_test.go | 2 +- receiver/kafkametricsreceiver/go.mod | 4 +-- receiver/kafkametricsreceiver/receiver.go | 2 +- .../kafkametricsreceiver/receiver_test.go | 2 +- receiver/kafkareceiver/config.go | 2 +- receiver/kafkareceiver/config_test.go | 2 +- receiver/kafkareceiver/go.mod | 4 +-- receiver/kafkareceiver/kafka_receiver.go | 2 +- receiver/kafkareceiver/kafka_receiver_test.go | 2 +- versions.yaml | 2 +- 35 files changed, 58 insertions(+), 31 deletions(-) create mode 100644 .chloggen/move_internal_kafka_to_pkg.yaml rename {internal => pkg}/kafka/Makefile (100%) rename {internal => pkg}/kafka/authentication.go (98%) rename {internal => pkg}/kafka/authentication_test.go (100%) rename {internal => pkg}/kafka/awsmsk/doc.go (90%) rename {internal => pkg}/kafka/awsmsk/iam_scram_client.go (99%) rename {internal => pkg}/kafka/awsmsk/iam_scram_client_test.go (100%) rename {internal => pkg}/kafka/awsmsk/package_test.go (100%) rename {internal => pkg}/kafka/go.mod (99%) rename {internal => pkg}/kafka/go.sum (100%) rename {internal => pkg}/kafka/metadata.yaml (100%) rename {internal => pkg}/kafka/package_test.go (100%) rename {internal => pkg}/kafka/scram_client.go (97%) diff --git a/.chloggen/move_internal_kafka_to_pkg.yaml b/.chloggen/move_internal_kafka_to_pkg.yaml new file mode 100644 index 000000000000..8053604a1689 --- /dev/null +++ b/.chloggen/move_internal_kafka_to_pkg.yaml @@ -0,0 +1,27 @@ +# Use this changelog template to create an entry for release notes. + +# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix' +change_type: enhancement + +# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver) +component: kafkainternal + +# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). +note: moves internal/kafka to pkg/kafka to allow config to be visible for downstream projects + +# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists. +issues: [33180] + +# (Optional) One or more lines of additional information to render under the primary note. +# These lines will be padded with 2 spaces and then inserted directly into the document. +# Use pipe (|) for multiline entries. +subtext: + +# If your change doesn't affect end users or the exported elements of any package, +# you should instead start your pull request title with [chore] or use the "Skip Changelog" label. +# Optional: The change log or logs in which this entry should be included. +# e.g. '[user]' or '[user, api]' +# Include 'user' if the change is relevant to end users. +# Include 'api' if there is a change to a library API. +# Default: '[user]' +change_logs: [user, api] \ No newline at end of file diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 5e17e88ddbe5..ac6c1e7b2a24 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -132,7 +132,6 @@ internal/filter/ @open-telemetry/collector-cont internal/grpcutil/ @open-telemetry/collector-contrib-approvers @jmacd @moh-osman3 @lquerel internal/k8sconfig/ @open-telemetry/collector-contrib-approvers @dmitryax internal/k8stest/ @open-telemetry/collector-contrib-approvers @crobert-1 -internal/kafka/ @open-telemetry/collector-contrib-approvers @pavolloffay @MovieStoreGuy internal/kubelet/ @open-telemetry/collector-contrib-approvers @dmitryax internal/metadataproviders/ @open-telemetry/collector-contrib-approvers @Aneurysm9 @dashpole internal/otelarrow/ @open-telemetry/collector-contrib-approvers @jmacd @moh-osman3 @@ -148,6 +147,7 @@ pkg/batchpersignal/ @open-telemetry/collector-cont 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 +pkg/kafka/ @open-telemetry/collector-contrib-approvers @pavolloffay @MovieStoreGuy pkg/kafka/topic/ @open-telemetry/collector-contrib-approvers @pavolloffay @MovieStoreGuy pkg/ottl/ @open-telemetry/collector-contrib-approvers @TylerHelmuth @kentquirk @bogdandrutu @evan-bradley pkg/pdatatest/ @open-telemetry/collector-contrib-approvers @djaglowski @fatsheep9146 diff --git a/.github/ISSUE_TEMPLATE/bug_report.yaml b/.github/ISSUE_TEMPLATE/bug_report.yaml index ea469c572bcb..d89101fe7e02 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yaml +++ b/.github/ISSUE_TEMPLATE/bug_report.yaml @@ -132,7 +132,6 @@ body: - internal/grpcutil - internal/k8sconfig - internal/k8stest - - internal/kafka - internal/kubelet - internal/metadataproviders - internal/otelarrow @@ -148,6 +147,7 @@ body: - pkg/experimentalmetricmetadata - pkg/golden - pkg/kafka/topic + - pkg/kafka - pkg/ottl - pkg/pdatatest - pkg/pdatautil diff --git a/.github/ISSUE_TEMPLATE/feature_request.yaml b/.github/ISSUE_TEMPLATE/feature_request.yaml index 99f72f1c13b1..fe8d48fe99a4 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yaml +++ b/.github/ISSUE_TEMPLATE/feature_request.yaml @@ -126,7 +126,6 @@ body: - internal/grpcutil - internal/k8sconfig - internal/k8stest - - internal/kafka - internal/kubelet - internal/metadataproviders - internal/otelarrow @@ -142,6 +141,7 @@ body: - pkg/experimentalmetricmetadata - pkg/golden - pkg/kafka/topic + - pkg/kafka - pkg/ottl - pkg/pdatatest - pkg/pdatautil diff --git a/.github/ISSUE_TEMPLATE/other.yaml b/.github/ISSUE_TEMPLATE/other.yaml index c65b1b3fa089..d2c8968e3280 100644 --- a/.github/ISSUE_TEMPLATE/other.yaml +++ b/.github/ISSUE_TEMPLATE/other.yaml @@ -126,7 +126,6 @@ body: - internal/grpcutil - internal/k8sconfig - internal/k8stest - - internal/kafka - internal/kubelet - internal/metadataproviders - internal/otelarrow @@ -142,6 +141,7 @@ body: - pkg/experimentalmetricmetadata - pkg/golden - pkg/kafka/topic + - pkg/kafka - pkg/ottl - pkg/pdatatest - pkg/pdatautil diff --git a/.github/ISSUE_TEMPLATE/unmaintained.yaml b/.github/ISSUE_TEMPLATE/unmaintained.yaml index a6402ed0e246..c96a8688e469 100644 --- a/.github/ISSUE_TEMPLATE/unmaintained.yaml +++ b/.github/ISSUE_TEMPLATE/unmaintained.yaml @@ -131,7 +131,6 @@ body: - internal/grpcutil - internal/k8sconfig - internal/k8stest - - internal/kafka - internal/kubelet - internal/metadataproviders - internal/otelarrow @@ -147,6 +146,7 @@ body: - pkg/experimentalmetricmetadata - pkg/golden - pkg/kafka/topic + - pkg/kafka - pkg/ottl - pkg/pdatatest - pkg/pdatautil diff --git a/cmd/otelcontribcol/builder-config.yaml b/cmd/otelcontribcol/builder-config.yaml index 1aaf44a38c55..6aa5e0370097 100644 --- a/cmd/otelcontribcol/builder-config.yaml +++ b/cmd/otelcontribcol/builder-config.yaml @@ -361,8 +361,8 @@ replaces: - github.com/open-telemetry/opentelemetry-collector-contrib/exporter/azuredataexplorerexporter => ../../exporter/azuredataexplorerexporter - github.com/open-telemetry/opentelemetry-collector-contrib/internal/k8sconfig => ../../internal/k8sconfig - github.com/open-telemetry/opentelemetry-collector-contrib/internal/k8stest => ../../internal/k8stest - - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka => ../../internal/kafka - github.com/open-telemetry/opentelemetry-collector-contrib/internal/rabbitmq => ../../internal/rabbitmq + - github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka => ../../pkg/kafka - github.com/open-telemetry/opentelemetry-collector-contrib/receiver/carbonreceiver => ../../receiver/carbonreceiver - github.com/open-telemetry/opentelemetry-collector-contrib/exporter/splunkhecexporter => ../../exporter/splunkhecexporter - github.com/open-telemetry/opentelemetry-collector-contrib/exporter/prometheusexporter => ../../exporter/prometheusexporter diff --git a/exporter/kafkaexporter/config.go b/exporter/kafkaexporter/config.go index aac2cf77c097..6351f54b97b7 100644 --- a/exporter/kafkaexporter/config.go +++ b/exporter/kafkaexporter/config.go @@ -12,7 +12,7 @@ import ( "go.opentelemetry.io/collector/config/configretry" "go.opentelemetry.io/collector/exporter/exporterhelper" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" ) // Config defines configuration for Kafka exporter. diff --git a/exporter/kafkaexporter/config_test.go b/exporter/kafkaexporter/config_test.go index 3264e996cbe5..714f02eeaece 100644 --- a/exporter/kafkaexporter/config_test.go +++ b/exporter/kafkaexporter/config_test.go @@ -19,7 +19,7 @@ import ( "go.opentelemetry.io/collector/exporter/exporterhelper" "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafkaexporter/internal/metadata" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" ) func TestLoadConfig(t *testing.T) { diff --git a/exporter/kafkaexporter/go.mod b/exporter/kafkaexporter/go.mod index bb7f5c60fb52..d3d13a4a1d61 100644 --- a/exporter/kafkaexporter/go.mod +++ b/exporter/kafkaexporter/go.mod @@ -8,8 +8,8 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/jaegertracing/jaeger v1.62.0 github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.115.0 - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/batchpersignal v0.115.0 + github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/topic v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/pdatautil v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/jaeger v0.115.0 @@ -115,7 +115,7 @@ require ( replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal -replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka => ../../internal/kafka +replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka => ../../pkg/kafka replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/batchpersignal => ../../pkg/batchpersignal diff --git a/exporter/kafkaexporter/kafka_exporter.go b/exporter/kafkaexporter/kafka_exporter.go index 6720237fabe2..39cf15cb6d59 100644 --- a/exporter/kafkaexporter/kafka_exporter.go +++ b/exporter/kafkaexporter/kafka_exporter.go @@ -18,7 +18,7 @@ import ( "go.opentelemetry.io/collector/pdata/ptrace" "go.uber.org/zap" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/topic" ) diff --git a/exporter/kafkaexporter/kafka_exporter_test.go b/exporter/kafkaexporter/kafka_exporter_test.go index 80b56d05dbc8..243dffc201ee 100644 --- a/exporter/kafkaexporter/kafka_exporter_test.go +++ b/exporter/kafkaexporter/kafka_exporter_test.go @@ -22,7 +22,7 @@ import ( "go.opentelemetry.io/collector/pdata/testdata" "go.uber.org/zap" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/topic" ) diff --git a/internal/kafka/Makefile b/pkg/kafka/Makefile similarity index 100% rename from internal/kafka/Makefile rename to pkg/kafka/Makefile diff --git a/internal/kafka/authentication.go b/pkg/kafka/authentication.go similarity index 98% rename from internal/kafka/authentication.go rename to pkg/kafka/authentication.go index ca6ce4c3519e..b769a042a687 100644 --- a/internal/kafka/authentication.go +++ b/pkg/kafka/authentication.go @@ -1,7 +1,7 @@ // Copyright The OpenTelemetry Authors // SPDX-License-Identifier: Apache-2.0 -package kafka // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" +package kafka // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" import ( "context" @@ -14,7 +14,7 @@ import ( "github.com/aws/aws-msk-iam-sasl-signer-go/signer" "go.opentelemetry.io/collector/config/configtls" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka/awsmsk" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/awsmsk" ) // Authentication defines authentication. diff --git a/internal/kafka/authentication_test.go b/pkg/kafka/authentication_test.go similarity index 100% rename from internal/kafka/authentication_test.go rename to pkg/kafka/authentication_test.go diff --git a/internal/kafka/awsmsk/doc.go b/pkg/kafka/awsmsk/doc.go similarity index 90% rename from internal/kafka/awsmsk/doc.go rename to pkg/kafka/awsmsk/doc.go index 94ac3cee7d7a..a0afa5b54832 100644 --- a/internal/kafka/awsmsk/doc.go +++ b/pkg/kafka/awsmsk/doc.go @@ -7,4 +7,4 @@ // Further details on how the SASL connector works can be viewed here: // // https://github.com/aws/aws-msk-iam-auth#details -package awsmsk // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka/awsmsk" +package awsmsk // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/awsmsk" diff --git a/internal/kafka/awsmsk/iam_scram_client.go b/pkg/kafka/awsmsk/iam_scram_client.go similarity index 99% rename from internal/kafka/awsmsk/iam_scram_client.go rename to pkg/kafka/awsmsk/iam_scram_client.go index b7098a322c9f..ba82cfff4d64 100644 --- a/internal/kafka/awsmsk/iam_scram_client.go +++ b/pkg/kafka/awsmsk/iam_scram_client.go @@ -1,7 +1,7 @@ // Copyright The OpenTelemetry Authors // SPDX-License-Identifier: Apache-2.0 -package awsmsk // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka/awsmsk" +package awsmsk // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka/awsmsk" import ( "encoding/json" diff --git a/internal/kafka/awsmsk/iam_scram_client_test.go b/pkg/kafka/awsmsk/iam_scram_client_test.go similarity index 100% rename from internal/kafka/awsmsk/iam_scram_client_test.go rename to pkg/kafka/awsmsk/iam_scram_client_test.go diff --git a/internal/kafka/awsmsk/package_test.go b/pkg/kafka/awsmsk/package_test.go similarity index 100% rename from internal/kafka/awsmsk/package_test.go rename to pkg/kafka/awsmsk/package_test.go diff --git a/internal/kafka/go.mod b/pkg/kafka/go.mod similarity index 99% rename from internal/kafka/go.mod rename to pkg/kafka/go.mod index f2662dbbc95a..f8d1d027e1ef 100644 --- a/internal/kafka/go.mod +++ b/pkg/kafka/go.mod @@ -1,4 +1,4 @@ -module github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka +module github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka go 1.22.0 diff --git a/internal/kafka/go.sum b/pkg/kafka/go.sum similarity index 100% rename from internal/kafka/go.sum rename to pkg/kafka/go.sum diff --git a/internal/kafka/metadata.yaml b/pkg/kafka/metadata.yaml similarity index 100% rename from internal/kafka/metadata.yaml rename to pkg/kafka/metadata.yaml diff --git a/internal/kafka/package_test.go b/pkg/kafka/package_test.go similarity index 100% rename from internal/kafka/package_test.go rename to pkg/kafka/package_test.go diff --git a/internal/kafka/scram_client.go b/pkg/kafka/scram_client.go similarity index 97% rename from internal/kafka/scram_client.go rename to pkg/kafka/scram_client.go index 269dcfbd7713..22055d1c4008 100644 --- a/internal/kafka/scram_client.go +++ b/pkg/kafka/scram_client.go @@ -1,7 +1,7 @@ // Copyright The OpenTelemetry Authors // SPDX-License-Identifier: Apache-2.0 -package kafka // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" +package kafka // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" import ( "github.com/IBM/sarama" diff --git a/receiver/kafkametricsreceiver/config.go b/receiver/kafkametricsreceiver/config.go index 8b45224ea486..175092531763 100644 --- a/receiver/kafkametricsreceiver/config.go +++ b/receiver/kafkametricsreceiver/config.go @@ -6,7 +6,7 @@ package kafkametricsreceiver // import "github.com/open-telemetry/opentelemetry- import ( "go.opentelemetry.io/collector/receiver/scraperhelper" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkametricsreceiver/internal/metadata" ) diff --git a/receiver/kafkametricsreceiver/config_test.go b/receiver/kafkametricsreceiver/config_test.go index 63506b66c2ab..3b4d0ac040d9 100644 --- a/receiver/kafkametricsreceiver/config_test.go +++ b/receiver/kafkametricsreceiver/config_test.go @@ -14,7 +14,7 @@ import ( "go.opentelemetry.io/collector/confmap/confmaptest" "go.opentelemetry.io/collector/receiver/scraperhelper" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkametricsreceiver/internal/metadata" ) diff --git a/receiver/kafkametricsreceiver/go.mod b/receiver/kafkametricsreceiver/go.mod index 59d6de7f9414..58e005d8d1e7 100644 --- a/receiver/kafkametricsreceiver/go.mod +++ b/receiver/kafkametricsreceiver/go.mod @@ -5,7 +5,7 @@ go 1.22.0 require ( github.com/IBM/sarama v1.43.3 github.com/google/go-cmp v0.6.0 - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka v0.115.0 + github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka v0.115.0 github.com/stretchr/testify v1.10.0 go.opentelemetry.io/collector/component v0.115.1-0.20241206185113-3f3e208e71b8 go.opentelemetry.io/collector/component/componenttest v0.115.1-0.20241206185113-3f3e208e71b8 @@ -98,7 +98,7 @@ require ( gopkg.in/yaml.v3 v3.0.1 // indirect ) -replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka => ../../internal/kafka +replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka => ../../pkg/kafka // see https://github.com/distribution/distribution/issues/3590 exclude github.com/docker/distribution v2.8.0+incompatible diff --git a/receiver/kafkametricsreceiver/receiver.go b/receiver/kafkametricsreceiver/receiver.go index 0032c762591a..f11e76a17b1e 100644 --- a/receiver/kafkametricsreceiver/receiver.go +++ b/receiver/kafkametricsreceiver/receiver.go @@ -14,7 +14,7 @@ import ( "go.opentelemetry.io/collector/receiver/scraperhelper" "go.opentelemetry.io/collector/scraper" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkametricsreceiver/internal/metadata" ) diff --git a/receiver/kafkametricsreceiver/receiver_test.go b/receiver/kafkametricsreceiver/receiver_test.go index 6af7b7df836e..f1c0f70193b2 100644 --- a/receiver/kafkametricsreceiver/receiver_test.go +++ b/receiver/kafkametricsreceiver/receiver_test.go @@ -17,7 +17,7 @@ import ( "go.opentelemetry.io/collector/receiver/receivertest" "go.opentelemetry.io/collector/scraper" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" ) func TestNewReceiver_invalid_version_err(t *testing.T) { diff --git a/receiver/kafkareceiver/config.go b/receiver/kafkareceiver/config.go index 5b25c7c7c5f3..7370b7d239dc 100644 --- a/receiver/kafkareceiver/config.go +++ b/receiver/kafkareceiver/config.go @@ -9,7 +9,7 @@ import ( "go.opentelemetry.io/collector/component" "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafkaexporter" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" ) type AutoCommit struct { diff --git a/receiver/kafkareceiver/config_test.go b/receiver/kafkareceiver/config_test.go index b5e7faa1dc93..600149b01e62 100644 --- a/receiver/kafkareceiver/config_test.go +++ b/receiver/kafkareceiver/config_test.go @@ -15,7 +15,7 @@ import ( "go.opentelemetry.io/collector/confmap/confmaptest" "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafkaexporter" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkareceiver/internal/metadata" ) diff --git a/receiver/kafkareceiver/go.mod b/receiver/kafkareceiver/go.mod index 06602124773c..fe0774d571eb 100644 --- a/receiver/kafkareceiver/go.mod +++ b/receiver/kafkareceiver/go.mod @@ -10,7 +10,7 @@ require ( github.com/json-iterator/go v1.1.12 github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafkaexporter v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal v0.115.0 - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka v0.115.0 + github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/azure v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/jaeger v0.115.0 github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/zipkin v0.115.0 @@ -121,7 +121,7 @@ replace github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafka replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal => ../../internal/coreinternal -replace github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka => ../../internal/kafka +replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka => ../../pkg/kafka replace github.com/open-telemetry/opentelemetry-collector-contrib/pkg/translator/jaeger => ../../pkg/translator/jaeger diff --git a/receiver/kafkareceiver/kafka_receiver.go b/receiver/kafkareceiver/kafka_receiver.go index 1ec2d5aca6e9..b4047ec3a4f1 100644 --- a/receiver/kafkareceiver/kafka_receiver.go +++ b/receiver/kafkareceiver/kafka_receiver.go @@ -22,7 +22,7 @@ import ( "go.opentelemetry.io/otel/metric" "go.uber.org/zap" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkareceiver/internal/metadata" ) diff --git a/receiver/kafkareceiver/kafka_receiver_test.go b/receiver/kafkareceiver/kafka_receiver_test.go index e353974acd91..11e76fb1e51b 100644 --- a/receiver/kafkareceiver/kafka_receiver_test.go +++ b/receiver/kafkareceiver/kafka_receiver_test.go @@ -31,7 +31,7 @@ import ( "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/kafkaexporter" "github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal/textutils" - "github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka" "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkareceiver/internal/metadata" ) diff --git a/versions.yaml b/versions.yaml index 2603a69b8fdd..837332e7afbb 100644 --- a/versions.yaml +++ b/versions.yaml @@ -131,7 +131,7 @@ module-sets: - github.com/open-telemetry/opentelemetry-collector-contrib/internal/grpcutil - github.com/open-telemetry/opentelemetry-collector-contrib/internal/k8sconfig - github.com/open-telemetry/opentelemetry-collector-contrib/internal/k8stest - - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kafka + - github.com/open-telemetry/opentelemetry-collector-contrib/pkg/kafka - github.com/open-telemetry/opentelemetry-collector-contrib/internal/kubelet - github.com/open-telemetry/opentelemetry-collector-contrib/internal/metadataproviders - github.com/open-telemetry/opentelemetry-collector-contrib/internal/pdatautil