-
Notifications
You must be signed in to change notification settings - Fork 2.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
Print OpenTelemetry Configuration #2475
Conversation
Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
…aeger receiver Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
@pavolloffay I think this PR is in a good spot. Added a basic test to make sure that config factory returned an error if the dump otel flag was passed. Let me know what you think. |
crossdoc-otel job restarted. |
Codecov Report
@@ Coverage Diff @@
## master #2475 +/- ##
==========================================
+ Coverage 95.51% 95.53% +0.01%
==========================================
Files 208 208
Lines 10750 10750
==========================================
+ Hits 10268 10270 +2
+ Misses 406 405 -1
+ Partials 76 75 -1
Continue to review full report at Codecov.
|
The upstream collector does not have a default config in terms of enabled components, however each component creates a component config with default settings that are unknown to the user. So I think this feature might be also useful in the upstream OTel collector. There might be more ways how to approach this either add a flag that prints the full config or print the component config when a component is being started. I have filed an issue in OTEL open-telemetry/opentelemetry-collector#1791 |
Sounds good, we can leave this for a bit and then close it if otel collector is ok with adding this functionality. Oh, what did you think about moving the |
Signed-off-by: Joe Elliott <[email protected]>
Going to close this PR in favor of doing this upstream as linked by @pavolloffay. The refactoring in this PR was taken care of in #2495 |
Which problem is this PR solving?
Short description of the changes
config.dump-otel
flagCreateDefaultConfig()
. This mimics the way the jaegerreceiver works and removes the ZipkinHostPort field from ComponentSettings.Notes
fmt.Println
is crude but was chosen b/c it would be unaffected by config like a logger and cleanly dumps the config to stdout.Todo
@pavolloffay If you have a chance to review this and make sure I'm headed the right direction please do. I intend to add tests and drop draft status if this change is what is desired.