Skip to content
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

Add receiver.Builder to help with creating components form a set of configs and factories #6803

Merged
merged 1 commit into from
Dec 15, 2022

Conversation

bogdandrutu
Copy link
Member

@bogdandrutu bogdandrutu commented Dec 14, 2022

The main idea is that we pass a receiver.Builder (a combo of configs and factories that can create Receivers to the Service) instead of configs and factories separately. This way we help other distributions to re-implement service/host.

@bogdandrutu bogdandrutu force-pushed the draftbuilder branch 3 times, most recently from 9e90c0b to 413390d Compare December 15, 2022 02:20
@codecov
Copy link

codecov bot commented Dec 15, 2022

Codecov Report

Base: 90.08% // Head: 89.90% // Decreases project coverage by -0.18% ⚠️

Coverage data is based on head (f15d540) compared to base (cfa49fc).
Patch coverage: 81.51% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6803      +/-   ##
==========================================
- Coverage   90.08%   89.90%   -0.19%     
==========================================
  Files         246      248       +2     
  Lines       14246    14342      +96     
==========================================
+ Hits        12834    12894      +60     
- Misses       1163     1187      +24     
- Partials      249      261      +12     
Impacted Files Coverage Δ
exporter/exporter.go 88.23% <72.09%> (-11.77%) ⬇️
receiver/receiver.go 88.23% <72.09%> (-11.77%) ⬇️
service/service.go 67.22% <75.00%> (-1.07%) ⬇️
processor/processor.go 79.06% <79.06%> (ø)
service/pipelines.go 94.23% <81.25%> (-0.94%) ⬇️
exporter/exportertest/nop_exporter.go 100.00% <100.00%> (ø)
extension/extension.go 100.00% <100.00%> (ø)
extension/extensiontest/nop_extension.go 100.00% <100.00%> (ø)
otelcol/collector.go 77.27% <100.00%> (-0.67%) ⬇️
processor/processortest/nop_processor.go 100.00% <100.00%> (ø)
... and 6 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@bogdandrutu
Copy link
Member Author

/cc @dmitryax @djaglowski @mx-psi

@bogdandrutu bogdandrutu changed the title Draft: receiver.Builder Add receiver.Builder to help with creating components form a set of configs and factories Dec 15, 2022
@bogdandrutu bogdandrutu marked this pull request as ready for review December 15, 2022 02:29
@bogdandrutu bogdandrutu requested review from a team and dmitryax December 15, 2022 02:29
Copy link
Member

@djaglowski djaglowski left a comment

Choose a reason for hiding this comment

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

Looks like a nice improvement

service/service_test.go Outdated Show resolved Hide resolved
Copy link
Member

@dmitryax dmitryax left a comment

Choose a reason for hiding this comment

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

I like the idea.

@dmitryax
Copy link
Member

And we will do that for other component types, right?

@bogdandrutu bogdandrutu force-pushed the draftbuilder branch 2 times, most recently from 8d9532a to ff525cd Compare December 15, 2022 19:59
@bogdandrutu
Copy link
Member Author

bogdandrutu commented Dec 15, 2022

@dmitryax @djaglowski I am not convinced about the name of the type (Builder), here are some ideas:

  • Receivers
  • Builder
  • ConfiguredReceivers
  • please add more ideas...

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
@bogdandrutu bogdandrutu merged commit e63aed8 into open-telemetry:main Dec 15, 2022
@bogdandrutu bogdandrutu deleted the draftbuilder branch December 15, 2022 20:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants