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

Change CustomUnmarshaler implementations to use config.Parser, prove the interface #2810

Merged
merged 1 commit into from
Mar 26, 2021

Conversation

bogdandrutu
Copy link
Member

@bogdandrutu bogdandrutu commented Mar 25, 2021

Fixes #2735

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

@bogdandrutu bogdandrutu requested a review from a team March 25, 2021 23:15
@bogdandrutu bogdandrutu force-pushed the unmarshaler branch 2 times, most recently from ecc42d9 to ea50cdd Compare March 25, 2021 23:18
@codecov
Copy link

codecov bot commented Mar 25, 2021

Codecov Report

Merging #2810 (241e46c) into main (09f29af) will increase coverage by 0.00%.
The diff coverage is 96.29%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2810   +/-   ##
=======================================
  Coverage   91.66%   91.67%           
=======================================
  Files         293      293           
  Lines       15629    15633    +4     
=======================================
+ Hits        14327    14331    +4     
+ Misses        891      890    -1     
- Partials      411      412    +1     
Impacted Files Coverage Δ
receiver/prometheusreceiver/factory.go 82.35% <80.00%> (+0.53%) ⬆️
config/configparser/config.go 100.00% <100.00%> (ø)
config/parser.go 86.95% <100.00%> (+1.24%) ⬆️
receiver/hostmetricsreceiver/factory.go 87.01% <100.00%> (ø)
receiver/jaegerreceiver/factory.go 94.30% <100.00%> (ø)
receiver/otlpreceiver/factory.go 86.84% <100.00%> (+0.17%) ⬆️
testutil/testutil.go 81.60% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 09f29af...241e46c. Read the comment docs.

internal/testcomponents/example_exporter.go Outdated Show resolved Hide resolved
config/configparser/config.go Outdated Show resolved Hide resolved
config/parser.go Outdated Show resolved Hide resolved
receiver/hostmetricsreceiver/factory.go Show resolved Hide resolved
@bogdandrutu bogdandrutu changed the title Change CustomUnmarshaler to use config.Parser Change CustomUnmarshaler implementations to use config.Parser, prove the interface Mar 26, 2021
…the interface

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
@bogdandrutu
Copy link
Member Author

@mx-psi change the PR to not modify the CustomUnmarshaler interface yet. Reason is that I think better to just deprecate this completely.

Copy link
Member

@mx-psi mx-psi left a comment

Choose a reason for hiding this comment

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

Looks good, the PR title should be changed if we are not changing the implementations.

@mx-psi
Copy link
Member

mx-psi commented Mar 26, 2021

Reason is that I think better to just deprecate this completely.

What do you want to do instead?

@bogdandrutu
Copy link
Member Author

What do you want to do instead?

Start adding this #2597 and just mark the component unmarshaler as deprecated/remove it. If I change the component unmarshaler users will first have to update to that, then remove and update to the config one so there will be 2 changes

@bogdandrutu
Copy link
Member Author

Looks good, the PR title should be changed if we are not changing the implementations.

We are, because all implementation are first convert to Parser and work only on the parser interface. So now I am confident that Parser has all the functionality I need

@mx-psi
Copy link
Member

mx-psi commented Mar 26, 2021

Looks good, the PR title should be changed if we are not changing the implementations.

We are, because all implementation are first convert to Parser and work only on the parser interface. So now I am confident that Parser has all the functionality I need

Right, makes sense, let's keep it as it is then.

Start adding this #2597 and just mark the component unmarshaler as deprecated/remove it. If I change the component unmarshaler users will first have to update to that, then remove and update to the config one so there will be 2 changes

Can you have a look at the last comments on #2597 and to PR #2802 then? If you want I can work on #2597 on Monday if we agree on the interface we want (which I am guessing will be similar to the one for validation)

@bogdandrutu bogdandrutu merged commit acb3ae1 into open-telemetry:main Mar 26, 2021
@bogdandrutu bogdandrutu deleted the unmarshaler branch March 26, 2021 17:48
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.

Remove config.ToCustomUnmarshaler
3 participants