-
Notifications
You must be signed in to change notification settings - Fork 1.9k
[exporter/debug] Add output_paths configuration option #14401
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
base: main
Are you sure you want to change the base?
[exporter/debug] Add output_paths configuration option #14401
Conversation
|
@andrzej-stencel - This PR adds the "output_paths" configuration option requested in #10472. Would appreciate your review when you have time. Thanks! |
andrzej-stencel
left a comment
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 you please only include in the PR the changes needed for Debug exporter?
exporter/otlpexporter/config.go
Outdated
| // ConnectionPoolSize configures the number of gRPC connections to create and maintain. | ||
| // A larger pool size helps with high-throughput scenarios by distributing load across multiple connections. | ||
| // Default is 1 (single connection). Recommended for high-throughput: 4-8 connections. | ||
| ConnectionPoolSize int `mapstructure:"connection_pool_size"` |
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.
Looks like there are some changes in this PR that should not be a part of it?
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.
Thanks @andrzej-stencel! I've updated the PR to include only the debug exporter changes. The unrelated OTLP changes have been removed. The PR now contains only:
- Config changes for output_paths
- Factory logic updates
- Tests and documentation
- Changelog entry
Ready for re-review when you have time.
Adds output_paths config field to debug exporter, allowing users to redirect output to stderr or file paths when use_internal_logger is false. - Extends Config struct with OutputPaths []string field - Updates createCustomLogger to honor configured paths (defaults to stdout) - Adds validation to prevent use with use_internal_logger=true - Adds validation to reject empty path values - Updates README with new configuration option - Adds test coverage for output_paths scenarios Fixes open-telemetry#10472
dd08eec to
a6035e0
Compare
|
Hey, A review would be appreciated. |
|
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
|
This PR implements the same fix as #14164, let's see if that PR is merged (it was created first). |
Adds output_paths configuration option to the debug exporter to allow users to redirect output when use_internal_logger is set to false.
Fixes #10472
Testing
All existing tests pass (5/5)
Added test cases for:
Valid output paths configuration
Invalid combinations with use_internal_logger
Empty path validation
Config marshaling/unmarshaling
Backward Compatibility
Fully backward compatible—defaults to stdout when output_paths is not specified, maintaining existing behavior.