-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
[builder] Remove builder default confmap providers #11126
Conversation
eb2aa45
to
4dec027
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #11126 +/- ##
==========================================
- Coverage 91.92% 91.91% -0.01%
==========================================
Files 430 430
Lines 20311 20292 -19
==========================================
- Hits 18671 18652 -19
Misses 1267 1267
Partials 373 373 ☔ View full report in Codecov by Sentry. |
return err | ||
} | ||
c.Providers = &providers | ||
} else { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it a problem if no providers are defined, should the builder error out in that case?
return err | ||
} | ||
c.Providers = &providers | ||
c.Providers, err = parseModules(c.Providers) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fear this will break most ocb users. If we go this route, is there a gentler approach we could take with feature gates or timelines?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The main problem with this, is that the providers will start to have a different version than the builder and they will be independently mark as stable which will make it very hard to track all combination of builder versions with the "associated default" providers for that version.
This also fixes an issue, that for builder 0.109.0 the default providers will not work since the env and file are no longer using 0.109.0 version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would have suggested to actually wait for all providers to be marked stabled in one version, that would have simplified a lot. Otherwise, I am not sure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fear this will break most ocb users. If we go this route, is there a gentler approach we could take with feature gates or timelines?
Also, right now they are broke anyway. Because if they don't specify any provider, it will try to use env/file at 109 and will fail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think there's much that prevents us from marking the other providers as 1.0, I will open the PR for those
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am 100% to add support in the future for featureflags.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this particular change, I am fine with any of
- an error message that tells you what do very explicitly
- a feature gate
- a dedicated config flag
The "at least one provider is required" may not be super clear to people (they may not be aware of what providers they used to put in there).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
an error message that tells you what do very explicitly
Already there, tell me how you want the error to be, happy to change to a more clear. I think you only care about the message correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, just something that tells you "see example on https://opentelemetry.io/docs/collector/custom-collector/" or "previous default was [snippet of code that you can almost copy-paste]" would work for me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. Since this breaking change will affect end users of OCB who were not already setting providers, they'll be the most confused about what a provider is and what they need to set. We need to make it obvious what to do from the error message and the changelog entry (and I believe the OCB readme as well), so that they can learn how to fix their manifest.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should do this in one step, and definitely not without updating all our examples and our own manifests in -releases.
@mx-psi please propose a solution when blocking. We have a bug right now and we need a solution, this is my proposal to that, do you have an alternative? |
For the immediate term, I can think of three options:
I think doing (1) is harmless, fixes the issue for everybody and gives us more time |
I like 1 the most. I don't think 3 is feasible, I don't really like 2 because will grow a lot.
|
I agree that seems like the solution that will impact end users the least, i don't know if there are any side effects of publishing the same package under two different tags... i can't think of one, but unexpected go dependencies issues have crept up in the past |
Linking user report of this bug here #11129 |
@codeboten I created https://github.com/mx-psi/go-double-tagging to allow tests with this. With a program like this ( package main
import (
"fmt"
"github.com/mx-psi/go-double-tagging"
)
func main() {
fmt.Println(godoubletagging.SomeSymbol)
} and a
I can Not a definitive proof but everything seems to be working fine. |
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
After #11193 and #11194 all provider modules we include in core are now stable, so we can revisit this. To be honest, this has been broken for a few releases and we haven't gotten a lot of complaints, so maybe it's fine to just go with this change if we give clear migration instructions. I am going to remove my 'request changes'. |
The bug hasn't been a big complaint from users, so it may be fine to just go with this
4dec027
to
9090546
Compare
@mx-psi @codeboten @dmitryax I would propose to move forward with this and remove the problems in the future. |
I agree. It seems better to be explicit here. Providers should not be something strange to the OCB users. This PR LGTM |
component: 'builder' | ||
|
||
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). | ||
note: Remove default config providers. This will require users to always specify the providers. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add subtext with what users have to specify to keep the previous behavior?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. This is going to break a lot of OCB users, I'd really like to make it as easy as possible to fix which means supplying as much help as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. This is going to break a lot of OCB users, I'd really like to make it as easy as possible to fix which means supplying as much help as possible.
I don't believe it, recent data show that is not as big of a deal.
Let's give @TylerHelmuth one week to reply since he raised concerns about this |
@mx-psi no one else complained bc we released both stable and beta tags right? So the current default providers worked. |
They were broken for a long time. |
My understanding is that we did not fix it for v0.110.0, e.g. see https://github.com/open-telemetry/opentelemetry-collector/releases/tag/confmap%2Fprovider%2Fenvprovider%2Fv0.110.0 (not found). |
Signed-off-by: Bogdan Drutu <[email protected]>
9090546
to
98b2dc1
Compare
Closing this in favor of #11566 |
Description
The main problem with this, is that the providers will start to have a different version than the builder and they will be independently mark as stable which will make it very hard to track all combination of builder versions with the "associated default" providers for that version.
This also fixes an issue, that for builder 0.109.0 the default providers will not work since the env and file are no longer using 0.109.0 version.