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

[pkg/ottl] Add schema_url field to contexts #31444

Merged
merged 47 commits into from
Jun 21, 2024

Conversation

kernelpanic77
Copy link
Contributor

This PR attempts to make schemaURL for TransformContexts.

Description:
Added a breaking change to creation of TransformContext function for logs. Also made changes to all references of the function.

Link to tracking Issue:
#30229

Copy link
Contributor

@evan-bradley evan-bradley left a comment

Choose a reason for hiding this comment

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

Thanks for your patience. We're headed in the right direction, I left a few comments to help illustrate how I think this should work.

pkg/ottl/contexts/internal/scope.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/internal/scope.go Show resolved Hide resolved
pkg/ottl/contexts/ottllog/log.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottllog/log.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottllog/log.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottllog/log.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottllog/log.go Outdated Show resolved Hide resolved
@kernelpanic77
Copy link
Contributor Author

kernelpanic77 commented Mar 19, 2024

@evan-bradley I think this implementation should now work for ottllog. I have addressed your comments in the latest commits. Requesting your review on this.

However, I still have one question.

how would we change the NewTransformContext function for ottlscope, ottlresource and ottldatapoint, since all these modules use either internal.ResourceContext or internal.InstrumentationScopeContext interface ?
(We cannot use scope/resourceLogs, scope/resourceMetrics, scope/resourceSpans here)

@kernelpanic77
Copy link
Contributor Author

@evan-bradley Lets get this PR merged this week. I think we are very close to what we need. Please give your review for the latest commit. Thanks

@kernelpanic77
Copy link
Contributor Author

@evan-bradley @TylerHelmuth can we merge this PR now ?
let me know if any other changes are needed.

pkg/ottl/contexts/ottlcommon/package_test.go Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottlcommon/README.md Outdated Show resolved Hide resolved
pkg/ottl/contexts/ottlcommon/schema.go Outdated Show resolved Hide resolved
@kernelpanic77
Copy link
Contributor Author

Can we merge @evan-bradley @TylerHelmuth ?

@evan-bradley
Copy link
Contributor

@kernelpanic77 We should be able to merge this soon. Can you take a look at the failing tests?

@kernelpanic77
Copy link
Contributor Author

@evan-bradley I have fixed most of the integration-tests and unit-tests which seemed to be failing due to my changes. For the listing tests I think we can ignore. Can we please proceed with the merge now ?

@evan-bradley
Copy link
Contributor

@TylerHelmuth please take a look.

@TylerHelmuth TylerHelmuth merged commit 889cc4c into open-telemetry:main Jun 21, 2024
154 checks passed
@github-actions github-actions bot added this to the next release milestone Jun 21, 2024
martin-majlis-s1 pushed a commit to scalyr/opentelemetry-collector-contrib that referenced this pull request Jun 24, 2024
This PR attempts to make schemaURL for TransformContexts. 

**Description:** <Describe what has changed.>
Added a breaking change to creation of TransformContext function for
logs. Also made changes to all references of the function.

**Link to tracking Issue:** <Issue number if applicable>
open-telemetry#30229

---------

Co-authored-by: Evan Bradley <[email protected]>
Co-authored-by: Tyler Helmuth <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants