-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
[extension/receiver/exporter/processor/connector] Should we remove component.Type
from Settings.ID
?
#12221
Comments
I took a look at this. I think one important datapoint here is that there are: The searches are approximations (it's very hard to get an exact match) but I think it clearly shows that there are a lot more usages of the In summary: I think we should not do this because:
|
@open-telemetry/collector-approvers I intend to close this as wontfix on Friday unless somebody objects. |
There is a simple script to replace that: |
I am not saying it can't be done, I am just saying that that would mean users having to figure out how to build an |
Not saying to not give the ID, or a function like |
@bogdandrutu My point is that it's okay if we have this duplication since it leads to a better user experience. I understand the concern of mismatch because of multiple packages setting the type, one possible solution is to explicitly check for it. I filed #12305 to do that for extension; if that makes sense we can extend it to other component types and close this issue. |
…#12305) <!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Explicitly error out if the passed `component.ID` does not have a matching `component.Type` <!-- Issue number if applicable --> #### Link to tracking issue Updates #12221
Moved this to the receiver milestone since this is done for extension now |
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description <!-- Issue number if applicable --> Deprecate `Create*` methods. This is a small part of #12305, but applied to all other component kinds #### Link to tracking issue Updates #12221
#12357 is the next step to do this on all component kinds |
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description <!-- Issue number if applicable --> Creates `NewNopSettingsWithType` function on test modules and deprecates the `NewNopSettings` functions on those modules. Replace all usages of `NewNopSettings` with `NewNopSettingsWithType`. Part of #12305 but applied to all component kinds. #### Link to tracking issue Updates #12221
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description <!-- Issue number if applicable --> Creates `NewNopSettingsWithType` function on test modules and deprecates the `NewNopSettings` functions on those modules. Replace all usages of `NewNopSettings` with `NewNopSettingsWithType`. Part of open-telemetry#12305 but applied to all component kinds. #### Link to tracking issue Updates open-telemetry#12221
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Tries to fix some of the contrib tests for open-telemetry/opentelemetry-collector/pull/12381 <!-- Issue number (e.g. #1234) or full URL to issue, if applicable. --> #### Link to tracking issue Updates open-telemetry/opentelemetry-collector/issues/12221
The
component.Type
bit fromSettings.ID
is redundant for components: a component knows its owncomponent.Type
.Should we remove
component.Type
fromSettings.ID
?I think not, but I want to do a prototype, and see how it looks.
From the 2025-01-27 stability working group meeting.
The text was updated successfully, but these errors were encountered: