Skip to content

[receiver/kafka][exporter/kafka] Do not expose programmatic API via NewFactory #38874

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 24, 2025

Conversation

atoulme
Copy link
Contributor

@atoulme atoulme commented Mar 21, 2025

Description

It seems suspect to offer a FactoryFunc func on both kafka receivers and exporters, when they don't offer any changes to the factory struct, given that it has no fields and no exposed functions that can be overridden.

This PR removes the vararg used by NewFactory for both components, bringing the API in line with what is expected of components. The change is considered a breaking change, however the API signature is the same if the vararg is not used.

Copy link
Contributor

@axw axw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@MovieStoreGuy MovieStoreGuy merged commit 5b28ee0 into open-telemetry:main Mar 24, 2025
180 checks passed
@github-actions github-actions bot added this to the next release milestone Mar 24, 2025
Fiery-Fenix pushed a commit to Fiery-Fenix/opentelemetry-collector-contrib that referenced this pull request Apr 24, 2025
…ewFactory (open-telemetry#38874)

#### Description
It seems suspect to offer a FactoryFunc func on both kafka receivers and
exporters, when they don't offer any changes to the factory struct,
given that it has no fields and no exposed functions that can be
overridden.

This PR removes the vararg used by NewFactory for both components,
bringing the API in line with what is expected of components. The change
is considered a breaking change, however the API signature is the same
if the vararg is not used.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants