-
Notifications
You must be signed in to change notification settings - Fork 872
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
Create abstraction for library dependencies for instrumentation. #977
Create abstraction for library dependencies for instrumentation. #977
Conversation
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.
I like it.
Gradle files look really nice.
library
type makes a lot of sense too, as it represents the library under instrumentation / test.
Have you tried it with some module where latestDeps differ significantly from If it works, it is a very good simplification :) |
…-instr-java into latestdeptest-abstraction
I'm continuing to play with this PR and think I have the concepts mostly ready. I've ended up defining three configurations
A couple of takeaways
Let me know if you have any thoughts on approach, naming, etc. |
…-instr-java into latestdeptest-abstraction
…-instr-java into latestdeptest-abstraction
…-instr-java into latestdeptest-abstraction
Hopefully this is ready. We can see the difference in dependencies in build scans like these |
One point is there are just a few tests left that have actually separate sources for |
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.
Very nice ❤️
// TODO(anuraaga): Investigate why these tests don't pass on 5 or 6 | ||
// https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/1042 |
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.
Also see more general version of this issue #749
instrumentation/java-classloader/tomcat-testing/tomcat-testing.gradle
Outdated
Show resolved
Hide resolved
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Adds three configurations
library
,testLibrary
,latestDepTest
library as described hereWhen Gradle is run with
-PtestLatestDeps=true
, the standardtestImplementation
configuration is overridden with the latest dep test wildcards. Without the property, it's as if the wildcards don't exist. This means IntelliJ won't read the wildcard versions anymore. The bottom-left corner of IDE with all the external libraries is still huge, but far smaller than before, presuambly speeding up some IntelliJ indexing / refactoring operations. Most importantly, now IntelliJ won't ever freeze to refresh dynamic versions in the middle of development.