-
Notifications
You must be signed in to change notification settings - Fork 316
Using ddprof nightly snapshot for nightly test #9919
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: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,12 +6,22 @@ plugins { | |
|
|
||
| apply from: "$rootDir/gradle/java.gradle" | ||
|
|
||
| configurations { | ||
| def nightly = register('nightlyTestImplementation') { | ||
| visible = false | ||
| canBeConsumed = false | ||
| canBeResolved = true | ||
| extendsFrom(testImplementation) | ||
| } | ||
| } | ||
|
|
||
| dependencies { | ||
| // This module provides the ddprof library as an api dependency | ||
| // so that other modules can easily depend on it. | ||
| implementation project.hasProperty('ddprof.jar') ? files(project.findProperty('ddprof.jar')) : libs.ddprof | ||
| api project(':internal-api') | ||
| api project(':dd-trace-api') | ||
| nightlyTestImplementation group: 'com.datadoghq', name: 'ddprof', version: 'latest.integration' | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. not 100% sure that this should be
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. So if I get it right, @zhengyu123, you need to run test on both the included ddprof, and a nightly. If so I think using the same approach as what is done in various instrumentation tests might be the better approach. I.e. drop the manually registered configuration, and tweak the build file along those lines. +addTestSuiteForDir('nightlyTest', 'test')
dependencies {
+ nightlyTestImplementation group: 'com.datadoghq', name: 'ddprof', version: 'latest.integration'
}This should create a One thing I'm not sure, is where the nightly gets published ?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @bric3 Actually, we only want to use latest snapshot for nightly test and keep regular test as it is, so that if there are breakages in profiler won't impact your regular works. Bruce pointed me here: https://github.com/DataDog/dd-trace-java/blob/b42a4cb14913d661a7b1b67b41532aad1b847924/.gitlab-ci.yml#L252C12-L252C13
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the context ! That said, the current lines won't work. Gradle configuration domain object, represents a collection of artifacts and their dependencies and how they can be consumed or resolved.
However, I don't think anything consumes this I'd like to discuss this with other folk in JLP. Maybe this needs specific CI pipeline or job, or maybe something simpler can be achieved by overriding the cc @sarahchen6 @PerfectSlayer for awareness
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When I run following command: I see diff --git a/dd-java-agent/ddprof-lib/gradle.lockfile b/dd-java-agent/ddprof-lib/gradle.lockfile
index 55304edcf1..59289527ee 100644
--- a/dd-java-agent/ddprof-lib/gradle.lockfile
+++ b/dd-java-agent/ddprof-lib/gradle.lockfile
@@ -1,35 +1,36 @@
# This is a Gradle generated file for dependency locking.
# Manual edits can break the build and are not advised.
# This file is expected to be part of source control.
-ch.qos.logback:logback-classic:1.2.13=testCompileClasspath,testRuntimeClasspath
-ch.qos.logback:logback-core:1.2.13=testCompileClasspath,testRuntimeClasspath
-com.beust:jcommander:1.78=testRuntimeClasspath
-com.datadoghq:dd-javac-plugin-client:0.2.2=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
+ch.qos.logback:logback-classic:1.2.13=nightlyTestImplementation,testCompileClasspath,testRuntimeClasspath
+ch.qos.logback:logback-core:1.2.13=nightlyTestImplementation,testCompileClasspath,testRuntimeClasspath
+com.beust:jcommander:1.78=nightlyTestImplementation,testRuntimeClasspath
+com.datadoghq:dd-javac-plugin-client:0.2.2=compileClasspath,nightlyTestImplementation,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
com.datadoghq:ddprof:1.34.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
-com.github.javaparser:javaparser-core:3.25.6=codenarc,testCompileClasspath,testRuntimeClasspath
-com.github.spotbugs:spotbugs-annotations:4.2.0=compileClasspath,testCompileClasspath,testRuntimeClasspath
+com.datadoghq:ddprof:1.35.0-SNAPSHOT=nightlyTestImplementation
+com.github.javaparser:javaparser-core:3.25.6=codenarc,nightlyTestImplementation,testCompileClasspath,testRuntimeClasspath
+com.github.spotbugs:spotbugs-annotations:4.2.0=compileClasspath,nightlyTestImplementation,testCompileClasspath,testRuntimeClasspath
com.github.spotbugs:spotbugs-annotations:4.7.3=spotbugs
com.github.spotbugs:spotbugs:4.7.3=spotbugs
....
It means nothing?
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Nope it doesn't, this lock file only allow to lock the dependency resolution, but doesn't make the "nightly configuration" used. If you look closely you can see that
|
||
| } | ||
|
|
||
| tasks.named("shadowJar", ShadowJar) { | ||
|
|
||
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.
The variable here is not necessary.
Note however, that if this build file was written with the Kotlin dsl then the variable could have been reused.