From bbfdbb39c00e0edafcbd45abc9bd7c8c1928ca7a Mon Sep 17 00:00:00 2001 From: Anuraag Agrawal Date: Wed, 19 Aug 2020 08:57:31 +0900 Subject: [PATCH] Create abstraction for library dependencies for instrumentation. (#977) * Create abstraction for library dependencies for instrumentation. Co-authored-by: Trask Stalnaker Co-authored-by: Trask Stalnaker --- .github/workflows/nightly.yaml | 2 +- gradle/instrumentation-common.gradle | 76 +++++++++++++++++++ gradle/instrumentation-library.gradle | 1 + gradle/instrumentation.gradle | 2 + .../reactor-3.1/reactor-3.1.gradle | 22 +----- .../akka-http-10.0/akka-http-10.0.gradle | 17 +---- .../apache-httpasyncclient-4.0.gradle | 13 +--- .../apache-httpclient-2.0.gradle | 13 +--- .../apache-httpclient-4.0.gradle | 13 +--- .../armeria-1.0/auto/armeria-1.0-auto.gradle | 2 +- .../library/armeria-1.0-library.gradle | 2 +- .../aws-sdk/aws-sdk-1.11/aws-sdk-1.11.gradle | 29 +++---- .../aws-sdk-2.2/auto/aws-sdk-2.2-auto.gradle | 17 +---- .../library/aws-sdk-2.2-library.gradle | 17 +---- .../cassandra-3.0/cassandra-3.0.gradle | 13 +--- .../cassandra-4.0/cassandra-4.0.gradle | 12 +-- .../cdi-testing/cdi-testing.gradle | 20 ++--- .../couchbase-2.0/couchbase-2.0.gradle | 14 +--- .../couchbase-2.6/couchbase-2.6.gradle | 21 ++--- .../dropwizard-testing.gradle | 10 +-- .../elasticsearch-transport-5.3.gradle | 20 ++--- .../elasticsearch-transport-6.0.gradle | 16 +--- .../finatra-2.9/finatra-2.9.gradle | 28 +++---- instrumentation/geode-1.4/geode-1.4.gradle | 13 +--- .../google-http-client-1.19.gradle | 13 +--- .../grizzly-2.0/grizzly-2.0.gradle | 14 +--- .../grizzly-client-1.9.gradle | 13 +--- instrumentation/grpc-1.5/grpc-1.5.gradle | 21 ++--- .../hibernate-3.3/hibernate-3.3.gradle | 21 ++--- .../hibernate-4.0/hibernate-4.0.gradle | 15 +--- .../hibernate-4.3/hibernate-4.3.gradle | 22 ++---- .../hystrix-1.4/hystrix-1.4.gradle | 17 +---- .../tomcat-testing/tomcat-testing.gradle | 15 +--- .../jaxrs-client-1.1/jaxrs-client-1.1.gradle | 13 +--- .../jaxrs-client-2.0/jaxrs-client-2.0.gradle | 21 ++--- .../jaxrs/jaxrs-2.0/jaxrs-2.0.gradle | 12 +-- instrumentation/jdbc/jdbc.gradle | 32 +++----- .../jedis/jedis-1.4/jedis-1.4.gradle | 12 +-- .../jedis/jedis-3.0/jedis-3.0.gradle | 12 +-- instrumentation/jetty-8.0/jetty-8.0.gradle | 20 ++--- instrumentation/jsp-2.3/jsp-2.3.gradle | 23 ++---- .../kafka-clients-0.11.gradle | 26 +++---- .../kafka-streams-0.11.gradle | 30 +++----- instrumentation/khttp-0.1/khttp-0.1.gradle | 12 +-- .../kubernetes-client-7.0.gradle | 14 +--- .../lettuce/lettuce-4.0/lettuce-4.0.gradle | 11 +-- .../lettuce/lettuce-5.0/lettuce-5.0.gradle | 1 - .../lettuce/lettuce-5.1/lettuce-5.1.gradle | 13 +--- .../library/log4j-2.13.2-library.gradle | 12 +-- .../mongo/mongo-3.1/mongo-3.1.gradle | 12 +-- .../mongo/mongo-3.7/mongo-3.7.gradle | 12 +-- .../mongo-async-3.3/mongo-async-3.3.gradle | 12 +-- .../netty/netty-4.0/netty-4.0.gradle | 16 +--- .../netty/netty-4.1/netty-4.1.gradle | 15 +--- .../okhttp/okhttp-2.2/okhttp-2.2.gradle | 12 +-- .../okhttp/okhttp-3.0/okhttp-3.0.gradle | 12 +-- .../play-ws/play-ws-1.0/play-ws-1.0.gradle | 13 +--- .../play-ws/play-ws-2.0/play-ws-2.0.gradle | 13 +--- .../play-ws/play-ws-2.1/play-ws-2.1.gradle | 13 +--- instrumentation/play/play-2.3/play-2.3.gradle | 25 ++---- instrumentation/play/play-2.4/play-2.4.gradle | 21 ++--- instrumentation/play/play-2.6/play-2.6.gradle | 17 ++--- .../rabbitmq-2.7/rabbitmq-2.7.gradle | 15 +--- .../ratpack-1.4/ratpack-1.4.gradle | 12 +-- .../reactor-3.1/reactor-3.1.gradle | 13 +--- .../rediscala-1.8/rediscala-1.8.gradle | 12 +-- .../glassfish-testing.gradle | 10 +-- .../servlet/servlet-2.2/servlet-2.2.gradle | 15 +--- .../servlet/servlet-3.0/servlet-3.0.gradle | 23 ++---- .../servlet-common/servlet-common.gradle | 12 +-- .../spark-web-framework-2.3.gradle | 18 +---- .../spring-data-1.8/spring-data-1.8.gradle | 13 +--- .../spring-scheduling-3.1.gradle | 13 +--- .../spring-webflux-5.0.gradle | 19 ++--- .../spymemcached-2.12.gradle | 12 +-- instrumentation/twilio-6.6/twilio-6.6.gradle | 10 +-- instrumentation/vertx-3.0/vertx-3.0.gradle | 14 +--- .../vertx-reactive-3.5.gradle | 29 +++---- 78 files changed, 336 insertions(+), 905 deletions(-) create mode 100644 gradle/instrumentation-common.gradle diff --git a/.github/workflows/nightly.yaml b/.github/workflows/nightly.yaml index ce139b78c8e1..3d204b8dfa68 100644 --- a/.github/workflows/nightly.yaml +++ b/.github/workflows/nightly.yaml @@ -74,7 +74,7 @@ jobs: S3_BUILD_CACHE_ACCESS_KEY_ID: ${{ secrets.S3_BUILD_CACHE_ACCESS_KEY_ID }} S3_BUILD_CACHE_SECRET_KEY: ${{ secrets.S3_BUILD_CACHE_SECRET_KEY }} with: - command: ./gradlew latestDepTest --stacktrace + command: ./gradlew test -PtestLatestDeps=true --stacktrace timeout_minutes: 60 max_attempts: 3 diff --git a/gradle/instrumentation-common.gradle b/gradle/instrumentation-common.gradle new file mode 100644 index 000000000000..808b3649d2b1 --- /dev/null +++ b/gradle/instrumentation-common.gradle @@ -0,0 +1,76 @@ +/** Common setup for manual instrumentation of libraries and auto instrumentation. */ + + +/** + * We define three dependency configurations to use when adding dependencies to libraries being + * instrumented. + * + * - library: A dependency on the instrumented library. Results in the dependency being added to + * compileOnly and testImplementation. If the build is run with -PtestLatestDeps=true, the + * version when added to testImplementation will be overridden by `+`, the latest version + * possible. For simple libraries without different behavior between versions, it is possible + * to have a single dependency on library only. + * + * - testLibrary: A dependency on a library for testing. This will usually be used to either + * a) use a different version of the library for compilation and testing and b) to add a helper + * that is only required for tests (e.g., library-testing artifact). The dependency will be + * added to testImplementation and will have a version of `+` when testing latest deps as + * described above. + * + * - latestDepTestLibrary: A dependency on a library for testing when testing of latest dependency + * version is enabled. This dependency will be added as-is to testImplementation, but only if + * -PtestLatestDeps=true. The version will not be modified but it will be given highest + * precedence. Use this to restrict the latest version dependency from the default `+`, for + * example to restrict to just a major version by specifying `2.+`. + */ + +ext.testLatestDeps = findProperty('testLatestDeps') +configurations { + // library is where to define dependencies on the library that is being instrumented. It will not + // be packaged in the agent but will be available at runtime for tests. + library { + canBeResolved = false + canBeConsumed = false + } + testLibrary { + canBeResolved = false + canBeConsumed = false + } + latestDepTestLibrary { + canBeResolved = false + canBeConsumed = false + } + [library, testLibrary].each {configuration -> + // We use whenObjectAdded and copy into the real configurations instead of extension to allow + // mutating the version for latest dep tests. + configuration.dependencies.whenObjectAdded { + def dep = it.copy() + if (testLatestDeps) { + dep.version { + it.require '+' + } + } + testImplementation.dependencies.add(dep) + } + } + if (testLatestDeps) { + latestDepTestLibrary.dependencies.whenObjectAdded { + def dep = it.copy() + def declaredVersion = dep.version + dep.version { + it.strictly declaredVersion + } + testImplementation.dependencies.add(dep) + } + } + compileOnly.extendsFrom(library) +} + +if (testLatestDeps) { + afterEvaluate { + def latestDepTest = tasks.findByName('latestDepTest') + if (latestDepTest) { + tasks.test.dependsOn latestDepTest + } + } +} diff --git a/gradle/instrumentation-library.gradle b/gradle/instrumentation-library.gradle index d7b1bb8886f1..2ae16e8f0fd7 100644 --- a/gradle/instrumentation-library.gradle +++ b/gradle/instrumentation-library.gradle @@ -2,6 +2,7 @@ group = 'io.opentelemetry.instrumentation' apply from: "$rootDir/gradle/java.gradle" apply from: "$rootDir/gradle/publish.gradle" +apply from: "$rootDir/gradle/instrumentation-common.gradle" archivesBaseName = projectDir.parentFile.name diff --git a/gradle/instrumentation.gradle b/gradle/instrumentation.gradle index 8e7990c7f92a..ef92eac9b489 100644 --- a/gradle/instrumentation.gradle +++ b/gradle/instrumentation.gradle @@ -21,6 +21,8 @@ if (project.ext.find("skipPublish") != true) { apply from: "$rootDir/gradle/publish.gradle" } +apply from: "$rootDir/gradle/instrumentation-common.gradle" + afterEvaluate { byteBuddy { transformation { diff --git a/instrumentation-core/reactor-3.1/reactor-3.1.gradle b/instrumentation-core/reactor-3.1/reactor-3.1.gradle index cdf82ee1884a..90e9505565b4 100644 --- a/instrumentation-core/reactor-3.1/reactor-3.1.gradle +++ b/instrumentation-core/reactor-3.1/reactor-3.1.gradle @@ -20,26 +20,12 @@ ext { group = 'io.opentelemetry.instrumentation' -apply from: "$rootDir/gradle/java.gradle" -apply from: "$rootDir/gradle/publish.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} +apply from: "$rootDir/gradle/instrumentation-library.gradle" dependencies { - compileOnly group: 'io.projectreactor', name: 'reactor-core', version: '3.1.0.RELEASE' - - implementation deps.opentelemetryApi - - testImplementation project(':testing-common') - - testImplementation group: 'io.projectreactor', name: 'reactor-core', version: '3.1.0.RELEASE' + library group: 'io.projectreactor', name: 'reactor-core', version: '3.1.0.RELEASE' - latestDepTestImplementation group: 'io.projectreactor', name: 'reactor-core', version: '3.+' + latestDepTestLibrary group: 'io.projectreactor', name: 'reactor-core', version: '3.+' // Looks like later versions on reactor need this dependency for some reason even though it is marked as optional. - latestDepTestImplementation group: 'io.micrometer', name: 'micrometer-core', version: '1.+' + latestDepTestLibrary group: 'io.micrometer', name: 'micrometer-core', version: '1.+' } diff --git a/instrumentation/akka-http-10.0/akka-http-10.0.gradle b/instrumentation/akka-http-10.0/akka-http-10.0.gradle index 751316cb0af3..4c86cb8df7ce 100644 --- a/instrumentation/akka-http-10.0/akka-http-10.0.gradle +++ b/instrumentation/akka-http-10.0/akka-http-10.0.gradle @@ -13,10 +13,6 @@ testSets { version101Test { dirName = 'test' } - - latestDepTest { - dirName = 'test' - } } compileLagomTestJava { @@ -29,7 +25,6 @@ compileLagomTestGroovy { targetCompatibility = 1.8 } - muzzle { pass { group = 'com.typesafe.akka' @@ -70,13 +65,13 @@ muzzle { } dependencies { - compileOnly group: 'com.typesafe.akka', name: 'akka-http_2.11', version: '10.0.0' + library group: 'com.typesafe.akka', name: 'akka-http_2.11', version: '10.0.0' + library group: 'com.typesafe.akka', name: 'akka-stream_2.11', version: '2.4.14' implementation project(':javaagent-tooling') implementation deps.autoservice annotationProcessor deps.autoservice - testImplementation group: 'com.typesafe.akka', name: 'akka-http_2.11', version: '10.0.0' testImplementation group: 'com.squareup.okhttp3', name: 'okhttp', version: '3.6.0' lagomTestImplementation project(':instrumentation:akka-http-10.0') @@ -86,9 +81,6 @@ dependencies { // There are some internal API changes in 10.1 that we would like to test separately for version101TestImplementation group: 'com.typesafe.akka', name: 'akka-http_2.11', version: '10.1.0' version101TestImplementation group: 'com.typesafe.akka', name: 'akka-stream_2.11', version: '2.5.11' - - latestDepTestImplementation group: 'com.typesafe.akka', name: 'akka-http_2.11', version: '+' - latestDepTestImplementation group: 'com.typesafe.akka', name: 'akka-stream_2.11', version: '+' } test.dependsOn lagomTest @@ -99,11 +91,6 @@ compileVersion101TestGroovy { dependsOn compileVersion101TestScala } -compileLatestDepTestGroovy { - classpath = classpath.plus(files(compileLatestDepTestScala.destinationDir)) - dependsOn compileLatestDepTestScala -} - // Lagom test supports running only on java 8 for now. // To run it on java 11 requires some complicated juggling of scala dependencies // At the same time, "minJavaVersionForTests"/"maxJavaVersionForTests" functionality diff --git a/instrumentation/apache-httpasyncclient-4.0/apache-httpasyncclient-4.0.gradle b/instrumentation/apache-httpasyncclient-4.0/apache-httpasyncclient-4.0.gradle index da411659eea4..b865c0157c65 100644 --- a/instrumentation/apache-httpasyncclient-4.0/apache-httpasyncclient-4.0.gradle +++ b/instrumentation/apache-httpasyncclient-4.0/apache-httpasyncclient-4.0.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -14,16 +13,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.apache.httpcomponents', name: 'httpasyncclient', version: '4.0' - - testImplementation group: 'org.apache.httpcomponents', name: 'httpasyncclient', version: '4.0' - - latestDepTestImplementation group: 'org.apache.httpcomponents', name: 'httpasyncclient', version: '+' + library group: 'org.apache.httpcomponents', name: 'httpasyncclient', version: '4.0' } diff --git a/instrumentation/apache-httpclient/apache-httpclient-2.0/apache-httpclient-2.0.gradle b/instrumentation/apache-httpclient/apache-httpclient-2.0/apache-httpclient-2.0.gradle index 8be2e4d9143d..561c11fa990f 100644 --- a/instrumentation/apache-httpclient/apache-httpclient-2.0/apache-httpclient-2.0.gradle +++ b/instrumentation/apache-httpclient/apache-httpclient-2.0/apache-httpclient-2.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -11,16 +10,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'commons-httpclient', name: 'commons-httpclient', version: '2.0' - - testImplementation group: 'commons-httpclient', name: 'commons-httpclient', version: '2.0' - - latestDepTestImplementation group: 'commons-httpclient', name: 'commons-httpclient', version: '+' + library group: 'commons-httpclient', name: 'commons-httpclient', version: '2.0' } diff --git a/instrumentation/apache-httpclient/apache-httpclient-4.0/apache-httpclient-4.0.gradle b/instrumentation/apache-httpclient/apache-httpclient-4.0/apache-httpclient-4.0.gradle index 49ba8817f6ae..fb8898ce24f1 100644 --- a/instrumentation/apache-httpclient/apache-httpclient-4.0/apache-httpclient-4.0.gradle +++ b/instrumentation/apache-httpclient/apache-httpclient-4.0/apache-httpclient-4.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { fail { @@ -23,16 +22,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.0' - - testImplementation group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.0' - - latestDepTestImplementation group: 'org.apache.httpcomponents', name: 'httpclient', version: '+' + library group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.0' } diff --git a/instrumentation/armeria-1.0/auto/armeria-1.0-auto.gradle b/instrumentation/armeria-1.0/auto/armeria-1.0-auto.gradle index ad747ad987a7..f61cbbd2d9cc 100644 --- a/instrumentation/armeria-1.0/auto/armeria-1.0-auto.gradle +++ b/instrumentation/armeria-1.0/auto/armeria-1.0-auto.gradle @@ -18,7 +18,7 @@ muzzle { dependencies { implementation project(':instrumentation:armeria-1.0:library') - compileOnly group: 'com.linecorp.armeria', name: 'armeria', version: '0.99.8' + library group: 'com.linecorp.armeria', name: 'armeria', version: '0.99.8' testImplementation project(':instrumentation:armeria-1.0:testing') } diff --git a/instrumentation/armeria-1.0/library/armeria-1.0-library.gradle b/instrumentation/armeria-1.0/library/armeria-1.0-library.gradle index abeaa0fcc620..19661c17285a 100644 --- a/instrumentation/armeria-1.0/library/armeria-1.0-library.gradle +++ b/instrumentation/armeria-1.0/library/armeria-1.0-library.gradle @@ -5,7 +5,7 @@ ext { apply from: "$rootDir/gradle/instrumentation-library.gradle" dependencies { - compileOnly group: 'com.linecorp.armeria', name: 'armeria', version: '0.99.8' + library group: 'com.linecorp.armeria', name: 'armeria', version: '0.99.8' testImplementation project(':instrumentation:armeria-1.0:testing') } diff --git a/instrumentation/aws-sdk/aws-sdk-1.11/aws-sdk-1.11.gradle b/instrumentation/aws-sdk/aws-sdk-1.11/aws-sdk-1.11.gradle index b29c3bba0315..19e3125c725a 100644 --- a/instrumentation/aws-sdk/aws-sdk-1.11/aws-sdk-1.11.gradle +++ b/instrumentation/aws-sdk/aws-sdk-1.11/aws-sdk-1.11.gradle @@ -27,10 +27,6 @@ testSets { test_before_1_11_106 { dirName = 'test_before_1_11_106' } - - latestDepTest { - dirName = 'test' - } } configurations { @@ -45,16 +41,16 @@ configurations { } dependencies { - compileOnly group: 'com.amazonaws', name: 'aws-java-sdk-core', version: '1.11.0' + library group: 'com.amazonaws', name: 'aws-java-sdk-core', version: '1.11.0' // Include httpclient instrumentation for testing because it is a dependency for aws-sdk. testImplementation project(':instrumentation:apache-httpclient:apache-httpclient-4.0') - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-s3', version: '1.11.106' - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-rds', version: '1.11.106' - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-ec2', version: '1.11.106' - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-kinesis', version: '1.11.106' - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-sqs', version: '1.11.106' - testImplementation group: 'com.amazonaws', name: 'aws-java-sdk-dynamodb', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-s3', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-rds', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-ec2', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-kinesis', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-sqs', version: '1.11.106' + testLibrary group: 'com.amazonaws', name: 'aws-java-sdk-dynamodb', version: '1.11.106' // needed for kinesis: testImplementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: versions.jackson @@ -65,13 +61,8 @@ dependencies { test_before_1_11_106Implementation(group: 'com.amazonaws', name: 'aws-java-sdk-kinesis', version: '1.11.0') test_before_1_11_106Implementation(group: 'com.amazonaws', name: 'aws-java-sdk-sqs', version: '1.11.0') test_before_1_11_106Implementation(group: 'com.amazonaws', name: 'aws-java-sdk-dynamodb', version: '1.11.0') - - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-s3', version: '+' - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-rds', version: '+' - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-ec2', version: '+' - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-kinesis', version: '+' - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-sqs', version: '+' - latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-dynamodb', version: '+' } -test.dependsOn test_before_1_11_106 +if (!testLatestDeps) { + test.dependsOn test_before_1_11_106 +} diff --git a/instrumentation/aws-sdk/aws-sdk-2.2/auto/aws-sdk-2.2-auto.gradle b/instrumentation/aws-sdk/aws-sdk-2.2/auto/aws-sdk-2.2-auto.gradle index 01d232996bf2..c03380290be5 100644 --- a/instrumentation/aws-sdk/aws-sdk-2.2/auto/aws-sdk-2.2-auto.gradle +++ b/instrumentation/aws-sdk/aws-sdk-2.2/auto/aws-sdk-2.2-auto.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' // TODO(anuraaga): Move into instrumentation.gradle archivesBaseName = projectDir.parentFile.name @@ -16,24 +15,10 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation project(':instrumentation:aws-sdk:aws-sdk-2.2:library') - compileOnly group: 'software.amazon.awssdk', name: 'aws-core', version: '2.2.0' + library group: 'software.amazon.awssdk', name: 'aws-core', version: '2.2.0' testImplementation project(':instrumentation:aws-sdk:aws-sdk-2.2:testing') - - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'apache-client', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 's3', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'rds', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'ec2', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'sqs', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'dynamodb', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'kinesis', version: '+' } diff --git a/instrumentation/aws-sdk/aws-sdk-2.2/library/aws-sdk-2.2-library.gradle b/instrumentation/aws-sdk/aws-sdk-2.2/library/aws-sdk-2.2-library.gradle index 23cfc74ad8f3..b3b76a616e00 100644 --- a/instrumentation/aws-sdk/aws-sdk-2.2/library/aws-sdk-2.2-library.gradle +++ b/instrumentation/aws-sdk/aws-sdk-2.2/library/aws-sdk-2.2-library.gradle @@ -3,24 +3,9 @@ ext { } apply from: "$rootDir/gradle/instrumentation-library.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} dependencies { - compileOnly group: 'software.amazon.awssdk', name: 'aws-core', version: '2.2.0' + library group: 'software.amazon.awssdk', name: 'aws-core', version: '2.2.0' testImplementation project(':instrumentation:aws-sdk:aws-sdk-2.2:testing') - - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'apache-client', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 's3', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'rds', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'ec2', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'sqs', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'dynamodb', version: '+' - latestDepTestImplementation group: 'software.amazon.awssdk', name: 'kinesis', version: '+' } diff --git a/instrumentation/cassandra/cassandra-3.0/cassandra-3.0.gradle b/instrumentation/cassandra/cassandra-3.0/cassandra-3.0.gradle index 70f54d7bc955..5b8306205dc0 100644 --- a/instrumentation/cassandra/cassandra-3.0/cassandra-3.0.gradle +++ b/instrumentation/cassandra/cassandra-3.0/cassandra-3.0.gradle @@ -9,7 +9,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' // TODO switch to container-based tests (away from cassandraunit) // then we can run tests using Java 7 (see above) and won't need this override section @@ -46,17 +45,11 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.0.0' + library group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.0.0' - testImplementation group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.2.0' + testLibrary group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.2.0' testImplementation group: 'org.cassandraunit', name: 'cassandra-unit', version: '3.1.3.2' - latestDepTestImplementation group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.+' + latestDepTestLibrary group: 'com.datastax.cassandra', name: 'cassandra-driver-core', version: '3.+' } diff --git a/instrumentation/cassandra/cassandra-4.0/cassandra-4.0.gradle b/instrumentation/cassandra/cassandra-4.0/cassandra-4.0.gradle index c1611053f900..2d5b7f32c62e 100644 --- a/instrumentation/cassandra/cassandra-4.0/cassandra-4.0.gradle +++ b/instrumentation/cassandra/cassandra-4.0/cassandra-4.0.gradle @@ -6,7 +6,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -17,17 +16,10 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.datastax.oss', name: 'java-driver-core', version: '4.0.0' + library group: 'com.datastax.oss', name: 'java-driver-core', version: '4.0.0' - testImplementation group: 'com.datastax.oss', name: 'java-driver-core', version: '4.0.0' testImplementation group: 'org.cassandraunit', name: 'cassandra-unit', version: '4.3.1.0' - latestDepTestImplementation group: 'com.datastax.oss', name: 'java-driver-core', version: '4.+' + latestDepTestLibrary group: 'com.datastax.oss', name: 'java-driver-core', version: '4.+' } diff --git a/instrumentation/cdi-testing/cdi-testing.gradle b/instrumentation/cdi-testing/cdi-testing.gradle index 6b69aaeb0577..cd4de365080e 100644 --- a/instrumentation/cdi-testing/cdi-testing.gradle +++ b/instrumentation/cdi-testing/cdi-testing.gradle @@ -1,20 +1,12 @@ ext.skipPublish = true apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} dependencies { - testImplementation group: 'org.jboss.weld', name: 'weld-core', version: '2.3.0.Final' - testImplementation group: 'org.jboss.weld.se', name: 'weld-se', version: '2.3.0.Final' - testImplementation group: 'org.jboss.weld.se', name: 'weld-se-core', version: '2.3.0.Final' + testLibrary group: 'org.jboss.weld', name: 'weld-core', version: '2.3.0.Final' + testLibrary group: 'org.jboss.weld.se', name: 'weld-se', version: '2.3.0.Final' + testLibrary group: 'org.jboss.weld.se', name: 'weld-se-core', version: '2.3.0.Final' - // Beyond 2.x is CDI 2+ and requires Java 8 - latestDepTestImplementation group: 'org.jboss.weld', name: 'weld-core', version: '2.+' - latestDepTestImplementation group: 'org.jboss.weld.se', name: 'weld-se', version: '2.+' - latestDepTestImplementation group: 'org.jboss.weld.se', name: 'weld-se-core', version: '2.+' + latestDepTestLibrary group: 'org.jboss.weld', name: 'weld-core', version: '2.+' + latestDepTestLibrary group: 'org.jboss.weld.se', name: 'weld-se', version: '2.+' + latestDepTestLibrary group: 'org.jboss.weld.se', name: 'weld-se-core', version: '2.+' } diff --git a/instrumentation/couchbase/couchbase-2.0/couchbase-2.0.gradle b/instrumentation/couchbase/couchbase-2.0/couchbase-2.0.gradle index 26caed62ee54..df9a631cc82e 100644 --- a/instrumentation/couchbase/couchbase-2.0/couchbase-2.0.gradle +++ b/instrumentation/couchbase/couchbase-2.0/couchbase-2.0.gradle @@ -4,13 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} muzzle { // Version 2.7.5 and 2.7.8 were not released properly and muzzle cannot test against it causing failure. @@ -40,11 +33,10 @@ muzzle { dependencies { implementation project(':instrumentation:rxjava-1.0') - compileOnly group: 'com.couchbase.client', name: 'java-client', version: '2.0.0' + library group: 'com.couchbase.client', name: 'java-client', version: '2.0.0' testImplementation project(':instrumentation:couchbase:couchbase-testing') - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.+' - latestDepTestImplementation group: 'com.couchbase.client', name: 'java-client', version: '2.+' - latestDepTestImplementation group: 'com.couchbase.client', name: 'encryption', version: '+' + latestDepTestLibrary group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.+' + latestDepTestLibrary group: 'com.couchbase.client', name: 'java-client', version: '2.+' } diff --git a/instrumentation/couchbase/couchbase-2.6/couchbase-2.6.gradle b/instrumentation/couchbase/couchbase-2.6/couchbase-2.6.gradle index 1d83d4155b18..b47f3cfd9a74 100644 --- a/instrumentation/couchbase/couchbase-2.6/couchbase-2.6.gradle +++ b/instrumentation/couchbase/couchbase-2.6/couchbase-2.6.gradle @@ -4,13 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} muzzle { // Version 2.7.5 and 2.7.8 were not released properly and muzzle cannot test against it causing failure. @@ -45,18 +38,14 @@ muzzle { dependencies { implementation project(':instrumentation:rxjava-1.0') - compileOnly group: 'com.couchbase.client', name: 'java-client', version: '2.6.0' + library group: 'com.couchbase.client', name: 'java-client', version: '2.6.0' testImplementation project(':instrumentation:couchbase:couchbase-2.0') - testImplementation group: 'com.couchbase.mock', name: 'CouchbaseMock', version: '1.5.19' - testImplementation project(':instrumentation:couchbase:couchbase-testing') - testImplementation group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.1.0.RELEASE' - testImplementation group: 'com.couchbase.client', name: 'java-client', version: '2.6.0' - testImplementation group: 'com.couchbase.client', name: 'encryption', version: '1.0.0' + testLibrary group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.1.0.RELEASE' + testLibrary group: 'com.couchbase.client', name: 'encryption', version: '1.0.0' - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.1+' - latestDepTestImplementation group: 'com.couchbase.client', name: 'java-client', version: '2.+' - latestDepTestImplementation group: 'com.couchbase.client', name: 'encryption', version: '+' + latestDepTestLibrary group: 'org.springframework.data', name: 'spring-data-couchbase', version: '3.1+' + latestDepTestLibrary group: 'com.couchbase.client', name: 'java-client', version: '2.+' } diff --git a/instrumentation/dropwizard-testing/dropwizard-testing.gradle b/instrumentation/dropwizard-testing/dropwizard-testing.gradle index d13a0deb09db..5d0892b4bfbc 100644 --- a/instrumentation/dropwizard-testing/dropwizard-testing.gradle +++ b/instrumentation/dropwizard-testing/dropwizard-testing.gradle @@ -3,14 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -//apply plugin: 'org.unbroken-dome.test-sets' -// -//testSets { -// latestDepTest { -// dirName = 'test' -// } -//} - dependencies { testImplementation project(':instrumentation:jaxrs:jaxrs-2.0') testImplementation project(':instrumentation:servlet:servlet-3.0') @@ -21,5 +13,5 @@ dependencies { testImplementation group: 'com.fasterxml.jackson.module', name: 'jackson-module-afterburner', version: '2.9.10' // Anything 1.0+ fails with a java.lang.NoClassDefFoundError: org/eclipse/jetty/server/RequestLog -// latestDepTestImplementation group: 'io.dropwizard', name: 'dropwizard-testing', version: '1.+' +// latestDepTestLibrary group: 'io.dropwizard', name: 'dropwizard-testing', version: '1.+' } diff --git a/instrumentation/elasticsearch/elasticsearch-transport-5.3/elasticsearch-transport-5.3.gradle b/instrumentation/elasticsearch/elasticsearch-transport-5.3/elasticsearch-transport-5.3.gradle index 9ce81b627413..647fe50557a4 100644 --- a/instrumentation/elasticsearch/elasticsearch-transport-5.3/elasticsearch-transport-5.3.gradle +++ b/instrumentation/elasticsearch/elasticsearch-transport-5.3/elasticsearch-transport-5.3.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -21,14 +20,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.elasticsearch.client', name: 'transport', version: '5.3.0' + library group: 'org.elasticsearch.client', name: 'transport', version: '5.3.0' implementation project(':instrumentation:elasticsearch:elasticsearch-transport-common') @@ -39,13 +32,12 @@ dependencies { testImplementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.11.0' testImplementation group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.11.0' - testImplementation group: 'org.elasticsearch.plugin', name: 'transport-netty3-client', version: '5.3.0' - testImplementation group: 'org.elasticsearch.client', name: 'transport', version: '5.3.0' + testLibrary group: 'org.elasticsearch.plugin', name: 'transport-netty3-client', version: '5.3.0' // Unfortunately this will bump the transport version up to 5.5.0. - testImplementation group: 'org.springframework.data', name: 'spring-data-elasticsearch', version: '3.0.0.RELEASE' + testLibrary group: 'org.springframework.data', name: 'spring-data-elasticsearch', version: '3.0.0.RELEASE' - latestDepTestImplementation group: 'org.elasticsearch.plugin', name: 'transport-netty3-client', version: '5.+' - latestDepTestImplementation group: 'org.elasticsearch.client', name: 'transport', version: '5.+' - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-elasticsearch', version: '3.0.+' + latestDepTestLibrary group: 'org.elasticsearch.plugin', name: 'transport-netty3-client', version: '5.+' + latestDepTestLibrary group: 'org.elasticsearch.client', name: 'transport', version: '5.+' + latestDepTestLibrary group: 'org.springframework.data', name: 'spring-data-elasticsearch', version: '3.0.+' } diff --git a/instrumentation/elasticsearch/elasticsearch-transport-6.0/elasticsearch-transport-6.0.gradle b/instrumentation/elasticsearch/elasticsearch-transport-6.0/elasticsearch-transport-6.0.gradle index 2158f4f5606d..7e019d1b5966 100644 --- a/instrumentation/elasticsearch/elasticsearch-transport-6.0/elasticsearch-transport-6.0.gradle +++ b/instrumentation/elasticsearch/elasticsearch-transport-6.0/elasticsearch-transport-6.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -21,14 +20,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.elasticsearch.client', name: 'transport', version: '6.0.0' + library group: 'org.elasticsearch.client', name: 'transport', version: '6.0.0' implementation project(':instrumentation:elasticsearch:elasticsearch-transport-common') @@ -37,13 +30,12 @@ dependencies { testImplementation project(':instrumentation:apache-httpasyncclient-4.0') testImplementation project(':instrumentation:netty:netty-4.1') - testImplementation group: 'org.elasticsearch.plugin', name: 'transport-netty4-client', version: '6.0.0' - testImplementation group: 'org.elasticsearch.client', name: 'transport', version: '6.0.0' + testLibrary group: 'org.elasticsearch.plugin', name: 'transport-netty4-client', version: '6.0.0' testImplementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.11.0' testImplementation group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.11.0' // Limit tests to <6.5 as the latest versions have a breaking change for the tests. - latestDepTestImplementation group: 'org.elasticsearch.plugin', name: 'transport-netty4-client', version: '(6.1,6.5)' - latestDepTestImplementation group: 'org.elasticsearch.client', name: 'transport', version: '(6.1,6.5)' + latestDepTestLibrary group: 'org.elasticsearch.plugin', name: 'transport-netty4-client', version: '(6.1,6.5)' + latestDepTestLibrary group: 'org.elasticsearch.client', name: 'transport', version: '(6.1,6.5)' } diff --git a/instrumentation/finatra-2.9/finatra-2.9.gradle b/instrumentation/finatra-2.9/finatra-2.9.gradle index aa60c65fe8a8..1d60904ec8cb 100644 --- a/instrumentation/finatra-2.9/finatra-2.9.gradle +++ b/instrumentation/finatra-2.9/finatra-2.9.gradle @@ -5,14 +5,6 @@ ext { apply from: "$rootDir/gradle/instrumentation.gradle" apply from: "$rootDir/gradle/test-with-scala.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - - latestDepTest { - dirName = 'test' - } -} muzzle { // There are some weird library issues below 2.9 so can't assert inverse @@ -30,21 +22,19 @@ muzzle { } dependencies { + // TODO(anuraaga): Something about library configuration doesn't work well with scala compilation + // here. compileOnly group: 'com.twitter', name: 'finatra-http_2.11', version: '2.9.0' testImplementation project(':instrumentation:netty:netty-4.1') - - testImplementation group: 'com.twitter', name: 'finatra-http_2.11', version: '19.12.0' - testImplementation(group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.9.10') + // TODO(anuraaga): Something about finatra test compilation doesn't work well when this is + // present with testLatestDeps. + if (!testLatestDeps) { + testLibrary group: 'com.twitter', name: 'finatra-http_2.11', version: '19.12.0' + } + testLibrary(group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.9.10') // Required for older versions of finatra on JDKs >= 11 testImplementation group: 'com.sun.activation', name: 'javax.activation', version: '1.2.0' - latestDepTestImplementation project(':instrumentation:netty:netty-4.1') - latestDepTestImplementation group: 'com.twitter', name: 'finatra-http_2.11', version: '20.6.+' - latestDepTestImplementation(group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.11.0') -} - -compileLatestDepTestGroovy { - classpath = classpath.plus(files(compileLatestDepTestScala.destinationDir)) - dependsOn compileLatestDepTestScala + latestDepTestLibrary group: 'com.twitter', name: 'finatra-http_2.11', version: '20.6.+' } diff --git a/instrumentation/geode-1.4/geode-1.4.gradle b/instrumentation/geode-1.4/geode-1.4.gradle index 29b105979124..984f8667b256 100644 --- a/instrumentation/geode-1.4/geode-1.4.gradle +++ b/instrumentation/geode-1.4/geode-1.4.gradle @@ -5,8 +5,6 @@ ext { apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - muzzle { pass { group = "org.apache.geode" @@ -15,15 +13,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.apache.geode', name: 'geode-core', version: '1.4.0' - - testImplementation group: 'org.apache.geode', name: 'geode-core', version: '1.4.0' - latestDepTestImplementation group: 'org.apache.geode', name: 'geode-core', version: '+' + library group: 'org.apache.geode', name: 'geode-core', version: '1.4.0' } diff --git a/instrumentation/google-http-client-1.19/google-http-client-1.19.gradle b/instrumentation/google-http-client-1.19/google-http-client-1.19.gradle index 4707c47d7c46..fe91fd200cfa 100644 --- a/instrumentation/google-http-client-1.19/google-http-client-1.19.gradle +++ b/instrumentation/google-http-client-1.19/google-http-client-1.19.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -11,16 +10,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.google.http-client', name: 'google-http-client', version: '1.19.0' - - testImplementation group: 'com.google.http-client', name: 'google-http-client', version: '1.19.0' - - latestDepTestImplementation group: 'com.google.http-client', name: 'google-http-client', version: '+' + library group: 'com.google.http-client', name: 'google-http-client', version: '1.19.0' } diff --git a/instrumentation/grizzly-2.0/grizzly-2.0.gradle b/instrumentation/grizzly-2.0/grizzly-2.0.gradle index b1d68b053907..959a491f7750 100644 --- a/instrumentation/grizzly-2.0/grizzly-2.0.gradle +++ b/instrumentation/grizzly-2.0/grizzly-2.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,20 +9,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.glassfish.grizzly', name: 'grizzly-http', version: '2.0' testImplementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.2.3' testImplementation group: 'javax.ws.rs', name: 'javax.ws.rs-api', version: '2.0' - testImplementation group: 'org.glassfish.jersey.containers', name: 'jersey-container-grizzly2-http', version: '2.0' + testLibrary group: 'org.glassfish.jersey.containers', name: 'jersey-container-grizzly2-http', version: '2.0' - latestDepTestImplementation group: 'org.glassfish.jersey.containers', name: 'jersey-container-grizzly2-http', version: '2.+' - latestDepTestImplementation group: 'org.glassfish.jersey.inject', name: 'jersey-hk2', version: '2.+' + latestDepTestLibrary group: 'org.glassfish.jersey.containers', name: 'jersey-container-grizzly2-http', version: '2.+' + latestDepTestLibrary group: 'org.glassfish.jersey.inject', name: 'jersey-hk2', version: '2.+' } diff --git a/instrumentation/grizzly-client-1.9/grizzly-client-1.9.gradle b/instrumentation/grizzly-client-1.9/grizzly-client-1.9.gradle index 90640292c654..8f9bb394b326 100644 --- a/instrumentation/grizzly-client-1.9/grizzly-client-1.9.gradle +++ b/instrumentation/grizzly-client-1.9/grizzly-client-1.9.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -20,16 +19,10 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.9' + library group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.9' // for some reason, the tests don't *load* until 1.12, but muzzles works as far back as 1.9 - testImplementation group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.12' + testLibrary group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.12' - latestDepTestImplementation group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.16' + latestDepTestLibrary group: 'org.glassfish.grizzly', name: 'grizzly-http-client', version: '1.16' } diff --git a/instrumentation/grpc-1.5/grpc-1.5.gradle b/instrumentation/grpc-1.5/grpc-1.5.gradle index 553bcb7b5233..2efff6398c04 100644 --- a/instrumentation/grpc-1.5/grpc-1.5.gradle +++ b/instrumentation/grpc-1.5/grpc-1.5.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' apply plugin: 'com.google.protobuf' apply plugin: 'idea' @@ -37,24 +36,14 @@ protobuf { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'io.grpc', name: 'grpc-core', version: grpcVersion + library group: 'io.grpc', name: 'grpc-core', version: grpcVersion - testImplementation group: 'io.grpc', name: 'grpc-netty', version: grpcVersion - testImplementation group: 'io.grpc', name: 'grpc-protobuf', version: grpcVersion - testImplementation group: 'io.grpc', name: 'grpc-stub', version: grpcVersion - testImplementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.3.2' + testLibrary group: 'io.grpc', name: 'grpc-netty', version: grpcVersion + testLibrary group: 'io.grpc', name: 'grpc-protobuf', version: grpcVersion + testLibrary group: 'io.grpc', name: 'grpc-stub', version: grpcVersion - latestDepTestImplementation sourceSets.test.output // include the protobuf generated classes - latestDepTestImplementation group: 'io.grpc', name: 'grpc-netty', version: '+' - latestDepTestImplementation group: 'io.grpc', name: 'grpc-protobuf', version: '+' - latestDepTestImplementation group: 'io.grpc', name: 'grpc-stub', version: '+' + testImplementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.3.2' // this instrumentation needs to be able to be able to reference the OpenTelemetry API's gRPC Context // that is shaded in the bootstrap class loader (for sending telemetry to the agent), diff --git a/instrumentation/hibernate/hibernate-3.3/hibernate-3.3.gradle b/instrumentation/hibernate/hibernate-3.3/hibernate-3.3.gradle index 8b2eeca05b7b..8ba90094aa47 100644 --- a/instrumentation/hibernate/hibernate-3.3/hibernate-3.3.gradle +++ b/instrumentation/hibernate/hibernate-3.3/hibernate-3.3.gradle @@ -6,7 +6,6 @@ */ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -17,14 +16,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.hibernate', name: 'hibernate-core', version: '3.3.0.GA' + library group: 'org.hibernate', name: 'hibernate-core', version: '3.3.0.GA' implementation project(':instrumentation:hibernate:hibernate-common') @@ -33,7 +26,7 @@ dependencies { testImplementation project(':instrumentation:hibernate:hibernate-4.0') testImplementation project(':instrumentation:hibernate:hibernate-4.3') - testImplementation group: 'org.hibernate', name: 'hibernate-core', version: '3.3.0.SP1' + testLibrary group: 'org.hibernate', name: 'hibernate-core', version: '3.3.0.SP1' testImplementation group: 'org.hibernate', name: 'hibernate-annotations', version: '3.4.0.GA' testImplementation group: 'javassist', name: 'javassist', version: '+' testImplementation group: 'com.h2database', name: 'h2', version: '1.4.197' @@ -42,10 +35,12 @@ dependencies { testImplementation "com.sun.xml.bind:jaxb-impl:2.2.11" testImplementation "javax.activation:activation:1.1.1" - latestDepTestImplementation group: 'org.hibernate', name: 'hibernate-core', version: '3.+' + latestDepTestLibrary group: 'org.hibernate', name: 'hibernate-core', version: '3.+' } -configurations { - // Needed for test, but for latestDepTest this would otherwise bundle a second incompatible version of hibernate-core. - latestDepTestImplementation.exclude group: 'org.hibernate', module: 'hibernate-annotations' +if (findProperty('testLatestDeps')) { + configurations { + // Needed for test, but for latestDepTest this would otherwise bundle a second incompatible version of hibernate-core. + testImplementation.exclude group: 'org.hibernate', module: 'hibernate-annotations' + } } diff --git a/instrumentation/hibernate/hibernate-4.0/hibernate-4.0.gradle b/instrumentation/hibernate/hibernate-4.0/hibernate-4.0.gradle index 991ba656353a..1a02c5101bd9 100644 --- a/instrumentation/hibernate/hibernate-4.0/hibernate-4.0.gradle +++ b/instrumentation/hibernate/hibernate-4.0/hibernate-4.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,14 +9,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.hibernate', name: 'hibernate-core', version: '4.0.0.Final' + library group: 'org.hibernate', name: 'hibernate-core', version: '4.0.0.Final' implementation project(':instrumentation:hibernate:hibernate-common') @@ -26,15 +19,11 @@ dependencies { testImplementation project(':instrumentation:hibernate:hibernate-3.3') testImplementation project(':instrumentation:hibernate:hibernate-4.3') - testImplementation group: 'org.hibernate', name: 'hibernate-core', version: '4.0.0.Final' testImplementation group: 'com.h2database', name: 'h2', version: '1.4.197' testImplementation "javax.xml.bind:jaxb-api:2.2.11" testImplementation "com.sun.xml.bind:jaxb-core:2.2.11" testImplementation "com.sun.xml.bind:jaxb-impl:2.2.11" testImplementation "javax.activation:activation:1.1.1" - latestDepTestImplementation group: 'org.hibernate', name: 'hibernate-core', version: '4.2.+' - latestDepTestImplementation group: 'com.h2database', name: 'h2', version: '1.4.197' - // Test that the incremental instrumentation for hibernate 4.3 doesn't cause issues. - latestDepTestImplementation project(':instrumentation:hibernate:hibernate-4.3') + latestDepTestLibrary group: 'org.hibernate', name: 'hibernate-core', version: '4.2.+' } diff --git a/instrumentation/hibernate/hibernate-4.3/hibernate-4.3.gradle b/instrumentation/hibernate/hibernate-4.3/hibernate-4.3.gradle index 17feddbaf253..bb79bf281ecf 100644 --- a/instrumentation/hibernate/hibernate-4.3/hibernate-4.3.gradle +++ b/instrumentation/hibernate/hibernate-4.3/hibernate-4.3.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,14 +9,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.hibernate', name: 'hibernate-core', version: '4.3.0.Final' + library group: 'org.hibernate', name: 'hibernate-core', version: '4.3.0.Final' implementation project(':instrumentation:hibernate:hibernate-common') @@ -26,13 +19,12 @@ dependencies { testImplementation project(':instrumentation:hibernate:hibernate-3.3') testImplementation project(':instrumentation:hibernate:hibernate-4.0') - testImplementation group: 'org.hibernate', name: 'hibernate-core', version: '4.3.0.Final' - testImplementation group: 'org.hibernate', name: 'hibernate-entitymanager', version: '4.3.0.Final' + testLibrary group: 'org.hibernate', name: 'hibernate-entitymanager', version: '4.3.0.Final' testImplementation group: 'org.hsqldb', name: 'hsqldb', version: '2.0.0' - testImplementation group: 'org.springframework.data', name: 'spring-data-jpa', version: '1.5.1.RELEASE' + testLibrary group: 'org.springframework.data', name: 'spring-data-jpa', version: '1.5.1.RELEASE' - latestDepTestImplementation group: 'org.hibernate', name: 'hibernate-core', version: '(,6.0.0.Final)' - latestDepTestImplementation group: 'org.hibernate', name: 'hibernate-entitymanager', version: '(,6.0.0.Final)' - latestDepTestImplementation group: 'org.hsqldb', name: 'hsqldb', version: '2.0.0' - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-jpa', version: '+' + // TODO(anuraaga): Investigate why these tests don't pass on 5 or 6 + // https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/1042 + latestDepTestLibrary group: 'org.hibernate', name: 'hibernate-core', version: '4.+' + latestDepTestLibrary group: 'org.hibernate', name: 'hibernate-entitymanager', version: '4.+' } diff --git a/instrumentation/hystrix-1.4/hystrix-1.4.gradle b/instrumentation/hystrix-1.4/hystrix-1.4.gradle index fef142d921f1..deb531232675 100644 --- a/instrumentation/hystrix-1.4/hystrix-1.4.gradle +++ b/instrumentation/hystrix-1.4/hystrix-1.4.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -9,21 +8,9 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation project(':instrumentation:rxjava-1.0') - compileOnly group: 'com.netflix.hystrix', name: 'hystrix-core', version: '1.4.0' - compileOnly group: 'io.reactivex', name: 'rxjava', version: '1.0.7' - - testImplementation group: 'io.reactivex', name: 'rxjava', version: '1.0.7' - testImplementation group: 'com.netflix.hystrix', name: 'hystrix-core', version: '1.4.0' - - latestDepTestImplementation group: 'io.reactivex', name: 'rxjava', version: '+' - latestDepTestImplementation group: 'com.netflix.hystrix', name: 'hystrix-core', version: '+' + library group: 'com.netflix.hystrix', name: 'hystrix-core', version: '1.4.0' + library group: 'io.reactivex', name: 'rxjava', version: '1.0.7' } diff --git a/instrumentation/java-classloader/tomcat-testing/tomcat-testing.gradle b/instrumentation/java-classloader/tomcat-testing/tomcat-testing.gradle index 17f3c0cbc865..c3a00e94c6e5 100644 --- a/instrumentation/java-classloader/tomcat-testing/tomcat-testing.gradle +++ b/instrumentation/java-classloader/tomcat-testing/tomcat-testing.gradle @@ -1,7 +1,6 @@ ext.skipPublish = true apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -12,18 +11,10 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { testImplementation project(':instrumentation:java-classloader') - //This seems to be the earliest version that has org.apache.catalina.loader.WebappClassLoaderBase - //Older versions would require slightly different instrumentation. - testImplementation group: 'org.apache.tomcat', name: 'tomcat-catalina', version: '8.0.14' - - latestDepTestImplementation group: 'org.apache.tomcat', name: 'tomcat-catalina', version: '+' + // This is the earliest version that has org.apache.catalina.loader.ParallelWebappClassLoader + // which is used in the test + testLibrary group: 'org.apache.tomcat', name: 'tomcat-catalina', version: '8.0.14' } diff --git a/instrumentation/jaxrs-client/jaxrs-client-1.1/jaxrs-client-1.1.gradle b/instrumentation/jaxrs-client/jaxrs-client-1.1/jaxrs-client-1.1.gradle index 2a25468bb6cd..58142ff156dd 100644 --- a/instrumentation/jaxrs-client/jaxrs-client-1.1/jaxrs-client-1.1.gradle +++ b/instrumentation/jaxrs-client/jaxrs-client-1.1/jaxrs-client-1.1.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -11,16 +10,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.sun.jersey', name: 'jersey-client', version: '1.1.4' - - testImplementation group: 'com.sun.jersey', name: 'jersey-client', version: '1.1.4' - - latestDepTestImplementation group: 'com.sun.jersey', name: 'jersey-client', version: '+' + library group: 'com.sun.jersey', name: 'jersey-client', version: '1.1.4' } diff --git a/instrumentation/jaxrs-client/jaxrs-client-2.0/jaxrs-client-2.0.gradle b/instrumentation/jaxrs-client/jaxrs-client-2.0/jaxrs-client-2.0.gradle index d6973ec40222..eae601186aec 100644 --- a/instrumentation/jaxrs-client/jaxrs-client-2.0/jaxrs-client-2.0.gradle +++ b/instrumentation/jaxrs-client/jaxrs-client-2.0/jaxrs-client-2.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -16,12 +15,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { compileOnly group: 'javax.ws.rs', name: 'javax.ws.rs-api', version: '2.0.1' compileOnly group: 'javax.annotation', name: 'javax.annotation-api', version: '1.2' @@ -31,17 +24,17 @@ dependencies { testImplementation group: 'javax.ws.rs', name: 'javax.ws.rs-api', version: '2.0.1' - testImplementation group: 'org.glassfish.jersey.core', name: 'jersey-client', version: '2.0' - testImplementation group: 'org.jboss.resteasy', name: 'resteasy-client', version: '3.0.5.Final' + testLibrary group: 'org.glassfish.jersey.core', name: 'jersey-client', version: '2.0' + testLibrary group: 'org.jboss.resteasy', name: 'resteasy-client', version: '3.0.5.Final' // ^ This version has timeouts https://issues.redhat.com/browse/RESTEASY-975 - testImplementation group: 'org.apache.cxf', name: 'cxf-rt-rs-client', version: '3.1.0' + testLibrary group: 'org.apache.cxf', name: 'cxf-rt-rs-client', version: '3.1.0' // Doesn't work with CXF 3.0.x because their context is wrong: // https://github.com/apache/cxf/commit/335c7bad2436f08d6d54180212df5a52157c9f21 testImplementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.2.3' - latestDepTestImplementation group: 'org.glassfish.jersey.inject', name: 'jersey-hk2', version: '2.27' - latestDepTestImplementation group: 'org.glassfish.jersey.core', name: 'jersey-client', version: '2.27' - latestDepTestImplementation group: 'org.apache.cxf', name: 'cxf-rt-rs-client', version: '3.2.6' - latestDepTestImplementation group: 'org.jboss.resteasy', name: 'resteasy-client', version: '3.0.26.Final' + latestDepTestLibrary group: 'org.glassfish.jersey.inject', name: 'jersey-hk2', version: '2.27' + latestDepTestLibrary group: 'org.glassfish.jersey.core', name: 'jersey-client', version: '2.27' + latestDepTestLibrary group: 'org.apache.cxf', name: 'cxf-rt-rs-client', version: '3.2.6' + latestDepTestLibrary group: 'org.jboss.resteasy', name: 'resteasy-client', version: '3.0.26.Final' } diff --git a/instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle b/instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle index 9228d2f46455..645a24f5b996 100644 --- a/instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle +++ b/instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle @@ -15,10 +15,6 @@ muzzle { } testSets { - latestDepTest { - dirName = 'test' - } - resteasy31Test { dirName = 'test' } @@ -34,18 +30,16 @@ dependencies { // Jersey // First version with DropwizardTestSupport: - testImplementation group: 'io.dropwizard', name: 'dropwizard-testing', version: '0.8.0' + testLibrary group: 'io.dropwizard', name: 'dropwizard-testing', version: '0.8.0' testImplementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.2.3' testImplementation group: 'com.fasterxml.jackson.module', name: 'jackson-module-afterburner', version: '2.9.10' - latestDepTestImplementation group: 'io.dropwizard', name: 'dropwizard-testing', version: '1.+' + latestDepTestLibrary group: 'io.dropwizard', name: 'dropwizard-testing', version: '1.+' // Resteasy - testImplementation group: 'org.jboss.resteasy', name: 'resteasy-jaxrs', version: '3.0.0.Final' + testLibrary group: 'org.jboss.resteasy', name: 'resteasy-jaxrs', version: '3.0.0.Final' resteasy31TestImplementation(group: 'org.jboss.resteasy', name: 'resteasy-jaxrs', version: '3.1.0.Final') - - latestDepTestImplementation group: 'org.jboss.resteasy', name: 'resteasy-jaxrs', version: '+' } test.dependsOn resteasy31Test diff --git a/instrumentation/jdbc/jdbc.gradle b/instrumentation/jdbc/jdbc.gradle index fc845f2267ad..d1628318dc8a 100644 --- a/instrumentation/jdbc/jdbc.gradle +++ b/instrumentation/jdbc/jdbc.gradle @@ -3,7 +3,6 @@ plugins { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { @@ -25,32 +24,19 @@ tasks.withType(Checkstyle).configureEach { exclude '**/jdbc/normalizer/*.java' } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { // jdbc unit testing - testImplementation group: 'com.h2database', name: 'h2', version: '1.3.169' + testLibrary group: 'com.h2database', name: 'h2', version: '1.3.169' // first version jdk 1.6 compatible - testImplementation group: 'org.apache.derby', name: 'derby', version: '10.6.1.0' - testImplementation group: 'org.hsqldb', name: 'hsqldb', version: '2.0.0' + testLibrary group: 'org.apache.derby', name: 'derby', version: '10.6.1.0' + testLibrary group: 'org.hsqldb', name: 'hsqldb', version: '2.0.0' - testImplementation group: 'org.apache.tomcat', name: 'tomcat-jdbc', version: '7.0.19' + testLibrary group: 'org.apache.tomcat', name: 'tomcat-jdbc', version: '7.0.19' // tomcat needs this to run - testImplementation group: 'org.apache.tomcat', name: 'tomcat-juli', version: '7.0.19' - testImplementation group: 'com.zaxxer', name: 'HikariCP', version: '2.4.0' - testImplementation group: 'com.mchange', name: 'c3p0', version: '0.9.5' - - latestDepTestImplementation group: 'com.h2database', name: 'h2', version: '+' - latestDepTestImplementation group: 'org.apache.derby', name: 'derby', version: '10.14.+' - latestDepTestImplementation group: 'org.hsqldb', name: 'hsqldb', version: '+' - - latestDepTestImplementation group: 'org.apache.tomcat', name: 'tomcat-jdbc', version: '+' - latestDepTestImplementation group: 'org.apache.tomcat', name: 'tomcat-juli', version: '+' - latestDepTestImplementation group: 'com.zaxxer', name: 'HikariCP', version: '+' - latestDepTestImplementation group: 'com.mchange', name: 'c3p0', version: '+' + testLibrary group: 'org.apache.tomcat', name: 'tomcat-juli', version: '7.0.19' + testLibrary group: 'com.zaxxer', name: 'HikariCP', version: '2.4.0' + testLibrary group: 'com.mchange', name: 'c3p0', version: '0.9.5' + + latestDepTestLibrary group: 'org.apache.derby', name: 'derby', version: '10.14.+' } diff --git a/instrumentation/jedis/jedis-1.4/jedis-1.4.gradle b/instrumentation/jedis/jedis-1.4/jedis-1.4.gradle index 7124dd998f1e..be5f3f8245c4 100644 --- a/instrumentation/jedis/jedis-1.4/jedis-1.4.gradle +++ b/instrumentation/jedis/jedis-1.4/jedis-1.4.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,18 +9,11 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'redis.clients', name: 'jedis', version: '1.4.0' + library group: 'redis.clients', name: 'jedis', version: '1.4.0' testImplementation group: 'com.github.kstyrc', name: 'embedded-redis', version: '0.6' - testImplementation group: 'redis.clients', name: 'jedis', version: '1.4.0' // Jedis 3.0 has API changes that prevent instrumentation from applying - latestDepTestImplementation group: 'redis.clients', name: 'jedis', version: '2.+' + latestDepTestLibrary group: 'redis.clients', name: 'jedis', version: '2.+' } diff --git a/instrumentation/jedis/jedis-3.0/jedis-3.0.gradle b/instrumentation/jedis/jedis-3.0/jedis-3.0.gradle index e0ffa2e104b5..faa20ec18d77 100644 --- a/instrumentation/jedis/jedis-3.0/jedis-3.0.gradle +++ b/instrumentation/jedis/jedis-3.0/jedis-3.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { fail { @@ -15,20 +14,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'redis.clients', name: 'jedis', version: '3.0.0' + library group: 'redis.clients', name: 'jedis', version: '3.0.0' testImplementation group: 'com.github.kstyrc', name: 'embedded-redis', version: '0.6' - testImplementation group: 'redis.clients', name: 'jedis', version: '3.0.0' // ensures jedis-1.4 instrumentation does not load with jedis 3.0+ by failing // the tests in the event it does. The tests will end up with double spans testImplementation project(':instrumentation:jedis:jedis-1.4') - latestDepTestImplementation group: 'redis.clients', name: 'jedis', version: '3.+' + testLibrary group: 'redis.clients', name: 'jedis', version: '3.+' } diff --git a/instrumentation/jetty-8.0/jetty-8.0.gradle b/instrumentation/jetty-8.0/jetty-8.0.gradle index 1b55283bb3e2..2f49b6e1d59d 100644 --- a/instrumentation/jetty-8.0/jetty-8.0.gradle +++ b/instrumentation/jetty-8.0/jetty-8.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,14 +9,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.eclipse.jetty', name: 'jetty-server', version: '8.0.0.v20110901' + library group: 'org.eclipse.jetty', name: 'jetty-server', version: '8.0.0.v20110901' implementation project(':instrumentation:servlet:servlet-3.0') // Don't want to conflict with jetty from the test server. @@ -25,13 +18,12 @@ dependencies { exclude group: 'org.eclipse.jetty', module: 'jetty-server' } - testImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '8.0.0.v20110901' - testImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '8.0.0.v20110901' - testImplementation group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '8.0.0.v20110901' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '8.0.0.v20110901' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '8.0.0.v20110901' // Jetty 10 seems to refuse to run on java8. // TODO: we need to setup separate test for Jetty 10 when that is released. - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.+' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.+' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '9.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '9.+' } diff --git a/instrumentation/jsp-2.3/jsp-2.3.gradle b/instrumentation/jsp-2.3/jsp-2.3.gradle index 2749742b2123..83ce3f5ef66b 100644 --- a/instrumentation/jsp-2.3/jsp-2.3.gradle +++ b/instrumentation/jsp-2.3/jsp-2.3.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,12 +9,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { // compiling against tomcat 7.0.20 because there seems to be some issues with Tomcat's dependency < 7.0.20 compileOnly group: 'org.apache.tomcat', name: 'tomcat-jasper', version: '7.0.20' @@ -25,13 +18,13 @@ dependencies { testImplementation project(':instrumentation:servlet:servlet-3.0') // using tomcat 7.0.37 because there seems to be some issues with Tomcat's jar scanning in versions < 7.0.37 // https://stackoverflow.com/questions/23484098/org-apache-tomcat-util-bcel-classfile-classformatexception-invalid-byte-tag-in - testImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '7.0.37' - testImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-logging-juli', version: '7.0.37' - testImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '7.0.37' + testLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '7.0.37' + testLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-logging-juli', version: '7.0.37' + testLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '7.0.37' - latestDepTestImplementation group: 'javax.servlet.jsp', name: 'javax.servlet.jsp-api', version: '+' - latestDepTestImplementation group: 'javax.servlet', name: 'javax.servlet-api', version: '+' - latestDepTestImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '9.+' - latestDepTestImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '9.+' - latestDepTestImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-logging-juli', version: '9.+' + latestDepTestLibrary group: 'javax.servlet.jsp', name: 'javax.servlet.jsp-api', version: '+' + latestDepTestLibrary group: 'javax.servlet', name: 'javax.servlet-api', version: '+' + latestDepTestLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '9.+' + latestDepTestLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '9.+' + latestDepTestLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-logging-juli', version: '9.+' } diff --git a/instrumentation/kafka-clients-0.11/kafka-clients-0.11.gradle b/instrumentation/kafka-clients-0.11/kafka-clients-0.11.gradle index f71c50acd9c9..87a2391f72ae 100644 --- a/instrumentation/kafka-clients-0.11/kafka-clients-0.11.gradle +++ b/instrumentation/kafka-clients-0.11/kafka-clients-0.11.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,29 +9,22 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.apache.kafka', name: 'kafka-clients', version: '0.11.0.0' + library group: 'org.apache.kafka', name: 'kafka-clients', version: '0.11.0.0' - testImplementation group: 'org.apache.kafka', name: 'kafka-clients', version: '0.11.0.0' - testImplementation group: 'org.springframework.kafka', name: 'spring-kafka', version: '1.3.3.RELEASE' - testImplementation group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '1.3.3.RELEASE' + testLibrary group: 'org.springframework.kafka', name: 'spring-kafka', version: '1.3.3.RELEASE' + testLibrary group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '1.3.3.RELEASE' testImplementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.2.3' - testImplementation group: 'org.assertj', name: 'assertj-core', version: '2.9.+' + testLibrary group: 'org.assertj', name: 'assertj-core', version: '2.9.+' testImplementation group: 'org.mockito', name: 'mockito-core', version: '2.19.0' // Include latest version of kafka itself along with latest version of client libs. // This seems to help with jar compatibility hell. - latestDepTestImplementation group: 'org.apache.kafka', name: 'kafka_2.11', version: '2.3.+' + latestDepTestLibrary group: 'org.apache.kafka', name: 'kafka_2.11', version: '2.3.+' // (Pinning to 2.3.x: 2.4.0 introduces an error when executing compileLatestDepTestGroovy) // Caused by: java.lang.NoClassDefFoundError: org.I0Itec.zkclient.ZkClient - latestDepTestImplementation group: 'org.apache.kafka', name: 'kafka-clients', version: '2.3.+' - latestDepTestImplementation group: 'org.springframework.kafka', name: 'spring-kafka', version: '2.2.+' - latestDepTestImplementation group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '2.2.+' - latestDepTestImplementation group: 'org.assertj', name: 'assertj-core', version: '3.+' + latestDepTestLibrary group: 'org.apache.kafka', name: 'kafka-clients', version: '2.3.+' + latestDepTestLibrary group: 'org.springframework.kafka', name: 'spring-kafka', version: '2.2.+' + latestDepTestLibrary group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '2.2.+' + latestDepTestLibrary group: 'org.assertj', name: 'assertj-core', version: '3.+' } diff --git a/instrumentation/kafka-streams-0.11/kafka-streams-0.11.gradle b/instrumentation/kafka-streams-0.11/kafka-streams-0.11.gradle index b343c8aaac72..71d68e8a5c3f 100644 --- a/instrumentation/kafka-streams-0.11/kafka-streams-0.11.gradle +++ b/instrumentation/kafka-streams-0.11/kafka-streams-0.11.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -9,35 +8,28 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'org.apache.kafka', name: 'kafka-streams', version: '0.11.0.0' + library group: 'org.apache.kafka', name: 'kafka-streams', version: '0.11.0.0' // Include kafka-clients instrumentation for tests. testImplementation project(':instrumentation:kafka-clients-0.11') - testImplementation group: 'org.apache.kafka', name: 'kafka-clients', version: '0.11.0.0' - testImplementation group: 'org.apache.kafka', name: 'kafka-streams', version: '0.11.0.0' - testImplementation group: 'org.springframework.kafka', name: 'spring-kafka', version: '1.3.3.RELEASE' - testImplementation group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '1.3.3.RELEASE' + testLibrary group: 'org.apache.kafka', name: 'kafka-clients', version: '0.11.0.0' + testLibrary group: 'org.springframework.kafka', name: 'spring-kafka', version: '1.3.3.RELEASE' + testLibrary group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '1.3.3.RELEASE' testImplementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.2.3' - testImplementation group: 'org.assertj', name: 'assertj-core', version: '2.9.+' + testLibrary group: 'org.assertj', name: 'assertj-core', version: '2.9.+' testImplementation group: 'org.mockito', name: 'mockito-core', version: '2.19.0' // Include latest version of kafka itself along with latest version of client libs. // This seems to help with jar compatibility hell. - latestDepTestImplementation group: 'org.apache.kafka', name: 'kafka_2.11', version: '2.3.+' + latestDepTestLibrary group: 'org.apache.kafka', name: 'kafka_2.11', version: '2.3.+' // (Pinning to 2.3.x: 2.4.0 introduces an error when executing compileLatestDepTestGroovy) // Caused by: java.lang.NoClassDefFoundError: org.I0Itec.zkclient.ZkClient - latestDepTestImplementation group: 'org.apache.kafka', name: 'kafka-clients', version: '2.3.+' - latestDepTestImplementation group: 'org.apache.kafka', name: 'kafka-streams', version: '2.3.+' - latestDepTestImplementation group: 'org.springframework.kafka', name: 'spring-kafka', version: '2.2.+' - latestDepTestImplementation group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '2.2.+' - latestDepTestImplementation group: 'org.assertj', name: 'assertj-core', version: '3.+' + latestDepTestLibrary group: 'org.apache.kafka', name: 'kafka-clients', version: '2.3.+' + latestDepTestLibrary group: 'org.apache.kafka', name: 'kafka-streams', version: '2.3.+' + latestDepTestLibrary group: 'org.springframework.kafka', name: 'spring-kafka', version: '2.2.+' + latestDepTestLibrary group: 'org.springframework.kafka', name: 'spring-kafka-test', version: '2.2.+' + latestDepTestLibrary group: 'org.assertj', name: 'assertj-core', version: '3.+' } diff --git a/instrumentation/khttp-0.1/khttp-0.1.gradle b/instrumentation/khttp-0.1/khttp-0.1.gradle index a5fda0354201..856e2fa107d5 100644 --- a/instrumentation/khttp-0.1/khttp-0.1.gradle +++ b/instrumentation/khttp-0.1/khttp-0.1.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -14,15 +13,6 @@ muzzle { } } - -testSets { - latestDepTest -} - dependencies { - compileOnly group: 'khttp', name: 'khttp', version: '0.1.0' - - testImplementation group: 'khttp', name: 'khttp', version: '0.1.0' - - latestDepTestImplementation group: 'khttp', name: 'khttp', version: '+' + library group: 'khttp', name: 'khttp', version: '0.1.0' } \ No newline at end of file diff --git a/instrumentation/kubernetes-client-7.0/kubernetes-client-7.0.gradle b/instrumentation/kubernetes-client-7.0/kubernetes-client-7.0.gradle index 91cfa80c26aa..98da503a8f6d 100644 --- a/instrumentation/kubernetes-client-7.0/kubernetes-client-7.0.gradle +++ b/instrumentation/kubernetes-client-7.0/kubernetes-client-7.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' ext { minJavaVersionForTests = JavaVersion.VERSION_1_8 @@ -14,20 +13,9 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - - compileOnly(group: 'io.kubernetes', name: 'client-java-api', version: '7.0.0') + library(group: 'io.kubernetes', name: 'client-java-api', version: '7.0.0') implementation project(':javaagent-tooling') - - testImplementation group: 'io.kubernetes', name: 'client-java-api', version: '7.0.0' - - latestDepTestImplementation group: 'io.kubernetes', name: 'client-java-api', version: '+' } diff --git a/instrumentation/lettuce/lettuce-4.0/lettuce-4.0.gradle b/instrumentation/lettuce/lettuce-4.0/lettuce-4.0.gradle index 9dab7c38813b..d38ede08c355 100644 --- a/instrumentation/lettuce/lettuce-4.0/lettuce-4.0.gradle +++ b/instrumentation/lettuce/lettuce-4.0/lettuce-4.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -15,17 +14,11 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} dependencies { - compileOnly group: 'biz.paluch.redis', name: 'lettuce', version: '4.0.Final' + library group: 'biz.paluch.redis', name: 'lettuce', version: '4.0.Final' testImplementation group: 'com.github.kstyrc', name: 'embedded-redis', version: '0.6' - testImplementation group: 'biz.paluch.redis', name: 'lettuce', version: '4.0.Final' - latestDepTestImplementation group: 'biz.paluch.redis', name: 'lettuce', version: '4.+' + latestDepTestLibrary group: 'biz.paluch.redis', name: 'lettuce', version: '4.+' } diff --git a/instrumentation/lettuce/lettuce-5.0/lettuce-5.0.gradle b/instrumentation/lettuce/lettuce-5.0/lettuce-5.0.gradle index cdedefbe10a5..1063ce0f0dd3 100644 --- a/instrumentation/lettuce/lettuce-5.0/lettuce-5.0.gradle +++ b/instrumentation/lettuce/lettuce-5.0/lettuce-5.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { diff --git a/instrumentation/lettuce/lettuce-5.1/lettuce-5.1.gradle b/instrumentation/lettuce/lettuce-5.1/lettuce-5.1.gradle index eb4ae779943a..2b89ecdb8e81 100644 --- a/instrumentation/lettuce/lettuce-5.1/lettuce-5.1.gradle +++ b/instrumentation/lettuce/lettuce-5.1/lettuce-5.1.gradle @@ -4,7 +4,6 @@ ext { } apply from: "${rootDir}/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -15,19 +14,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'io.lettuce', name: 'lettuce-core', version: '5.1.0.RELEASE' + library group: 'io.lettuce', name: 'lettuce-core', version: '5.1.0.RELEASE' testImplementation group: 'com.github.kstyrc', name: 'embedded-redis', version: '0.6' // Only 5.2+ will have command arguments in the db.statement tag. - testImplementation group: 'io.lettuce', name: 'lettuce-core', version: '5.2.0.RELEASE' + testLibrary group: 'io.lettuce', name: 'lettuce-core', version: '5.2.0.RELEASE' testImplementation project(':instrumentation:reactor-3.1') - latestDepTestImplementation group: 'io.lettuce', name: 'lettuce-core', version: '5.+' + latestDepTestLibrary group: 'io.lettuce', name: 'lettuce-core', version: '5.+' } diff --git a/instrumentation/log4j/log4j-2.13.2/library/log4j-2.13.2-library.gradle b/instrumentation/log4j/log4j-2.13.2/library/log4j-2.13.2-library.gradle index d6f2b54d601a..3469e09f6135 100644 --- a/instrumentation/log4j/log4j-2.13.2/library/log4j-2.13.2-library.gradle +++ b/instrumentation/log4j/log4j-2.13.2/library/log4j-2.13.2-library.gradle @@ -3,22 +3,12 @@ ext { } apply from: "$rootDir/gradle/instrumentation-library.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} dependencies { - compileOnly group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.13.2' + library group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.13.2' annotationProcessor deps.autoservice compileOnly deps.autoservice - testImplementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.13.2' testAnnotationProcessor group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.13.2' - - latestDepTestImplementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '+' } diff --git a/instrumentation/mongo/mongo-3.1/mongo-3.1.gradle b/instrumentation/mongo/mongo-3.1/mongo-3.1.gradle index 2ec15e32ecbb..9f8d431a9f4e 100644 --- a/instrumentation/mongo/mongo-3.1/mongo-3.1.gradle +++ b/instrumentation/mongo/mongo-3.1/mongo-3.1.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,20 +9,11 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation(project(':instrumentation:mongo:mongo-common')) - compileOnly group: 'org.mongodb', name: 'mongo-java-driver', version: '3.1.0' + library group: 'org.mongodb', name: 'mongo-java-driver', version: '3.1.0' testImplementation project(':instrumentation:mongo:mongo-testing') testImplementation group: 'de.flapdoodle.embed', name: 'de.flapdoodle.embed.mongo', version: '1.50.5' - - testImplementation group: 'org.mongodb', name: 'mongo-java-driver', version: '3.1.0' - latestDepTestImplementation group: 'org.mongodb', name: 'mongo-java-driver', version: '+' } diff --git a/instrumentation/mongo/mongo-3.7/mongo-3.7.gradle b/instrumentation/mongo/mongo-3.7/mongo-3.7.gradle index 20dd7e5e987b..770b1f1b5d88 100644 --- a/instrumentation/mongo/mongo-3.7/mongo-3.7.gradle +++ b/instrumentation/mongo/mongo-3.7/mongo-3.7.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,21 +9,12 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation(project(':instrumentation:mongo:mongo-common')) // a couple of test attribute verifications don't pass until 3.8.0 - compileOnly group: 'org.mongodb', name: 'mongo-java-driver', version: '3.8.0' + library group: 'org.mongodb', name: 'mongo-java-driver', version: '3.8.0' testImplementation project(':instrumentation:mongo:mongo-testing') testImplementation group: 'de.flapdoodle.embed', name: 'de.flapdoodle.embed.mongo', version: '1.50.5' - - testImplementation group: 'org.mongodb', name: 'mongo-java-driver', version: '3.8.0' - latestDepTestImplementation group: 'org.mongodb', name: 'mongo-java-driver', version: '+' } diff --git a/instrumentation/mongo/mongo-async-3.3/mongo-async-3.3.gradle b/instrumentation/mongo/mongo-async-3.3/mongo-async-3.3.gradle index 629b4d9b103a..49c37fa21c85 100644 --- a/instrumentation/mongo/mongo-async-3.3/mongo-async-3.3.gradle +++ b/instrumentation/mongo/mongo-async-3.3/mongo-async-3.3.gradle @@ -5,7 +5,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -17,22 +16,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation(project(':instrumentation:mongo:mongo-common')) - compileOnly group: 'org.mongodb', name: 'mongodb-driver-async', version: '3.3.0' + library group: 'org.mongodb', name: 'mongodb-driver-async', version: '3.3.0' testImplementation project(':instrumentation:mongo:mongo-testing') testImplementation group: 'de.flapdoodle.embed', name: 'de.flapdoodle.embed.mongo', version: '1.50.5' - testImplementation group: 'org.mongodb', name: 'mongodb-driver-async', version: '3.3.0' - latestDepTestImplementation group: 'org.mongodb', name: 'mongodb-driver-async', version: '+' - testImplementation project(':instrumentation:mongo:mongo-3.7') } diff --git a/instrumentation/netty/netty-4.0/netty-4.0.gradle b/instrumentation/netty/netty-4.0/netty-4.0.gradle index d5ed5c0ef428..b77b67d78140 100644 --- a/instrumentation/netty/netty-4.0/netty-4.0.gradle +++ b/instrumentation/netty/netty-4.0/netty-4.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -32,20 +31,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'io.netty', name: 'netty-codec-http', version: '4.0.0.Final' + library group: 'io.netty', name: 'netty-codec-http', version: '4.0.0.Final' - testImplementation group: 'io.netty', name: 'netty-codec-http', version: '4.0.0.Final' - testImplementation group: 'org.asynchttpclient', name: 'async-http-client', version: '2.0.9' + testLibrary group: 'org.asynchttpclient', name: 'async-http-client', version: '2.0.9' - latestDepTestImplementation group: 'io.netty', name: 'netty-codec-http', version: '4.0.56.Final' - latestDepTestImplementation group: 'org.asynchttpclient', name: 'async-http-client', version: '2.0.+' + latestDepTestLibrary group: 'io.netty', name: 'netty-codec-http', version: '4.0.56.Final' + latestDepTestLibrary group: 'org.asynchttpclient', name: 'async-http-client', version: '2.0.+' } // We need to force the dependency to the earliest supported version because other libraries declare newer versions. diff --git a/instrumentation/netty/netty-4.1/netty-4.1.gradle b/instrumentation/netty/netty-4.1/netty-4.1.gradle index 292cd4c74272..7530003aa60f 100644 --- a/instrumentation/netty/netty-4.1/netty-4.1.gradle +++ b/instrumentation/netty/netty-4.1/netty-4.1.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -32,21 +31,13 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'io.netty', name: 'netty-codec-http', version: '4.1.0.Final' + library group: 'io.netty', name: 'netty-codec-http', version: '4.1.0.Final' - testImplementation group: 'io.netty', name: 'netty-codec-http', version: '4.1.0.Final' - testImplementation group: 'org.asynchttpclient', name: 'async-http-client', version: '2.1.0' + testLibrary group: 'org.asynchttpclient', name: 'async-http-client', version: '2.1.0' - latestDepTestImplementation group: 'io.netty', name: 'netty-codec-http', version: '(,5.0)' + latestDepTestLibrary group: 'io.netty', name: 'netty-codec-http', version: '(,5.0)' // latest async-http-client incompatable with 5.0+ netty - latestDepTestImplementation group: 'org.asynchttpclient', name: 'async-http-client', version: '+' } // We need to force the dependency to the earliest supported version because other libraries declare newer versions. diff --git a/instrumentation/okhttp/okhttp-2.2/okhttp-2.2.gradle b/instrumentation/okhttp/okhttp-2.2/okhttp-2.2.gradle index ffead9541a31..0ecbaf55cc4d 100644 --- a/instrumentation/okhttp/okhttp-2.2/okhttp-2.2.gradle +++ b/instrumentation/okhttp/okhttp-2.2/okhttp-2.2.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' /* Note: The Interceptor class for OkHttp was not introduced until 2.2+, so we need to make sure the @@ -14,21 +13,14 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly(group: 'com.squareup.okhttp', name: 'okhttp', version: '2.2.0') + library(group: 'com.squareup.okhttp', name: 'okhttp', version: '2.2.0') implementation project(':javaagent-tooling') testImplementation project(':instrumentation:java-concurrent') - testImplementation group: 'com.squareup.okhttp', name: 'okhttp', version: '2.2.0' - latestDepTestImplementation group: 'com.squareup.okhttp', name: 'okhttp', version: '[2.6,3)' + latestDepTestLibrary group: 'com.squareup.okhttp', name: 'okhttp', version: '[2.6,3)' } diff --git a/instrumentation/okhttp/okhttp-3.0/okhttp-3.0.gradle b/instrumentation/okhttp/okhttp-3.0/okhttp-3.0.gradle index f95aebadee2b..c6a35be66991 100644 --- a/instrumentation/okhttp/okhttp-3.0/okhttp-3.0.gradle +++ b/instrumentation/okhttp/okhttp-3.0/okhttp-3.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,12 +9,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - /* Note: there is a bit of dependency exclusion magic goin on. We have to exclude all transitive dependencies on 'okhttp' because we would like to force @@ -26,15 +19,14 @@ because it looks like exclusions using configurations excludes dependency even i not transitive. */ dependencies { - compileOnly(group: 'com.squareup.okhttp3', name: 'okhttp', version: '3.0.0') + library(group: 'com.squareup.okhttp3', name: 'okhttp', version: '3.0.0') implementation project(':javaagent-tooling') testImplementation(project(':testing-common')) { exclude module: 'okhttp' } - testImplementation group: 'com.squareup.okhttp3', name: 'okhttp', version: '3.0.0' // 4.x.x-alpha has been released and it looks like there are lots of incompatible changes - latestDepTestImplementation group: 'com.squareup.okhttp3', name: 'okhttp', version: '[3.11.0, 4.0.0*)' + latestDepTestLibrary group: 'com.squareup.okhttp3', name: 'okhttp', version: '[3.11.0, 4.0.0*)' } diff --git a/instrumentation/play-ws/play-ws-1.0/play-ws-1.0.gradle b/instrumentation/play-ws/play-ws-1.0/play-ws-1.0.gradle index ff566b6ec93a..23503134b1bf 100644 --- a/instrumentation/play-ws/play-ws-1.0/play-ws-1.0.gradle +++ b/instrumentation/play-ws/play-ws-1.0/play-ws-1.0.gradle @@ -4,13 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} muzzle { pass { @@ -35,7 +28,7 @@ muzzle { def scalaVersion = '2.12' dependencies { - compileOnly group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '1.0.2' + library group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '1.0.2' implementation project(':instrumentation:play-ws:play-ws-common') @@ -46,7 +39,5 @@ dependencies { testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:akka-http-10.0') - testImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '1.0.2' - - latestDepTestImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '1.+' + latestDepTestLibrary group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '1.+' } diff --git a/instrumentation/play-ws/play-ws-2.0/play-ws-2.0.gradle b/instrumentation/play-ws/play-ws-2.0/play-ws-2.0.gradle index ee29b8e2f503..7ad6d2401064 100644 --- a/instrumentation/play-ws/play-ws-2.0/play-ws-2.0.gradle +++ b/instrumentation/play-ws/play-ws-2.0/play-ws-2.0.gradle @@ -4,13 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} muzzle { @@ -40,7 +33,7 @@ muzzle { def scalaVersion = '2.12' dependencies { - compileOnly group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.0.0' + library group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.0.0' implementation project(':instrumentation:play-ws:play-ws-common') @@ -51,7 +44,5 @@ dependencies { testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:akka-http-10.0') - testImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.0.0' - - latestDepTestImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.0.+' + latestDepTestLibrary group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.0.+' } diff --git a/instrumentation/play-ws/play-ws-2.1/play-ws-2.1.gradle b/instrumentation/play-ws/play-ws-2.1/play-ws-2.1.gradle index 3ad74ae68196..a29a68bd458d 100644 --- a/instrumentation/play-ws/play-ws-2.1/play-ws-2.1.gradle +++ b/instrumentation/play-ws/play-ws-2.1/play-ws-2.1.gradle @@ -4,13 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' - -testSets { - latestDepTest { - dirName = 'test' - } -} muzzle { @@ -40,7 +33,7 @@ muzzle { def scalaVersion = '2.12' dependencies { - compileOnly group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.1.0' + library group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.1.0' implementation project(':instrumentation:play-ws:play-ws-common') @@ -50,8 +43,4 @@ dependencies { testImplementation project(':instrumentation:netty:netty-4.0') testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:akka-http-10.0') - - testImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '2.1.0' - - latestDepTestImplementation group: 'com.typesafe.play', name: "play-ahc-ws-standalone_$scalaVersion", version: '+' } diff --git a/instrumentation/play/play-2.3/play-2.3.gradle b/instrumentation/play/play-2.3/play-2.3.gradle index 381c988bffe5..d43a48d98a18 100644 --- a/instrumentation/play/play-2.3/play-2.3.gradle +++ b/instrumentation/play/play-2.3/play-2.3.gradle @@ -6,7 +6,6 @@ ext { apply from: "$rootDir/gradle/instrumentation.gradle" apply from: "$rootDir/gradle/test-with-scala.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -27,31 +26,21 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { + // TODO(anuraaga): Something about library configuration doesn't work well with scala compilation + // here. compileOnly group: 'com.typesafe.play', name: 'play_2.11', version: '2.3.0' testImplementation project(':instrumentation:netty:netty-3.8') - testImplementation group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.3.0' - testImplementation group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.3.0' - testImplementation(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.3.0') { + testLibrary group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.3.0' + testLibrary(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.3.0') { exclude group: 'org.eclipse.jetty', module: 'jetty-websocket' } - latestDepTestImplementation group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.3.+' - latestDepTestImplementation group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.3.+' - latestDepTestImplementation(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.3.+') { + latestDepTestLibrary group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.3.+' + latestDepTestLibrary group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.3.+' + latestDepTestLibrary(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.3.+') { exclude group: 'org.eclipse.jetty', module: 'jetty-websocket' } } - -compileLatestDepTestGroovy { - classpath = classpath.plus(files(compileLatestDepTestScala.destinationDir)) - dependsOn compileLatestDepTestScala -} diff --git a/instrumentation/play/play-2.4/play-2.4.gradle b/instrumentation/play/play-2.4/play-2.4.gradle index 6adc14c8794e..7dc678db38b9 100644 --- a/instrumentation/play/play-2.4/play-2.4.gradle +++ b/instrumentation/play/play-2.4/play-2.4.gradle @@ -5,7 +5,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -26,13 +25,9 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { + // TODO(anuraaga): Something about library configuration doesn't work well with scala compilation + // here. compileOnly group: 'com.typesafe.play', name: 'play_2.11', version: '2.4.0' testImplementation project(':instrumentation:netty:netty-4.0') @@ -40,15 +35,15 @@ dependencies { testImplementation project(':instrumentation:akka-http-10.0') // Before 2.5, play used netty 3.x which isn't supported, so for better test consistency, we test with just 2.5 - testImplementation group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.5.0' - testImplementation group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.5.0' - testImplementation(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.5.0') { + testLibrary group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.5.0' + testLibrary group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.5.0' + testLibrary(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.5.0') { exclude group: 'org.eclipse.jetty.websocket', module: 'websocket-client' } - latestDepTestImplementation group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.5.+' - latestDepTestImplementation group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.5.+' - latestDepTestImplementation(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.5.+') { + latestDepTestLibrary group: 'com.typesafe.play', name: 'play-java_2.11', version: '2.5.+' + latestDepTestLibrary group: 'com.typesafe.play', name: 'play-java-ws_2.11', version: '2.5.+' + latestDepTestLibrary(group: 'com.typesafe.play', name: 'play-test_2.11', version: '2.5.+') { exclude group: 'org.eclipse.jetty.websocket', module: 'websocket-client' } } diff --git a/instrumentation/play/play-2.6/play-2.6.gradle b/instrumentation/play/play-2.6/play-2.6.gradle index 9cb38f4468f9..620c233ac474 100644 --- a/instrumentation/play/play-2.6/play-2.6.gradle +++ b/instrumentation/play/play-2.6/play-2.6.gradle @@ -5,7 +5,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' def scalaVersion = '2.11' def playVersion = '2.6.0' @@ -31,28 +30,24 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { + // TODO(anuraaga): Something about library configuration doesn't work well with scala compilation + // here. compileOnly group: 'com.typesafe.play', name: "play_$scalaVersion", version: playVersion testImplementation project(':instrumentation:netty:netty-4.0') testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:akka-http-10.0') - testImplementation group: 'com.typesafe.play', name: "play-java_$scalaVersion", version: playVersion + testLibrary group: 'com.typesafe.play', name: "play-java_$scalaVersion", version: playVersion // TODO: Play WS is a separately versioned library starting with 2.6 and needs separate instrumentation. - testImplementation(group: 'com.typesafe.play', name: "play-test_$scalaVersion", version: playVersion) { + testLibrary(group: 'com.typesafe.play', name: "play-test_$scalaVersion", version: playVersion) { exclude group: 'org.eclipse.jetty.websocket', module: 'websocket-client' } // TODO: This should be changed to the latest in scala 2.13 instead of 2.11 since its ahead - latestDepTestImplementation group: 'com.typesafe.play', name: "play-java_$scalaVersion", version: '2.+' - latestDepTestImplementation(group: 'com.typesafe.play', name: "play-test_$scalaVersion", version: '2.+') { + latestDepTestLibrary group: 'com.typesafe.play', name: "play-java_$scalaVersion", version: '2.+' + latestDepTestLibrary(group: 'com.typesafe.play', name: "play-test_$scalaVersion", version: '2.+') { exclude group: 'org.eclipse.jetty.websocket', module: 'websocket-client' } } diff --git a/instrumentation/rabbitmq-2.7/rabbitmq-2.7.gradle b/instrumentation/rabbitmq-2.7/rabbitmq-2.7.gradle index 63ffd93ce799..b1a6708e30e5 100644 --- a/instrumentation/rabbitmq-2.7/rabbitmq-2.7.gradle +++ b/instrumentation/rabbitmq-2.7/rabbitmq-2.7.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,22 +9,12 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.rabbitmq', name: 'amqp-client', version: '2.7.0' + library group: 'com.rabbitmq', name: 'amqp-client', version: '2.7.0' - testImplementation group: 'com.rabbitmq', name: 'amqp-client', version: '2.7.0' - testImplementation group: 'org.springframework.amqp', name: 'spring-rabbit', version: '1.1.0.RELEASE' + testLibrary group: 'org.springframework.amqp', name: 'spring-rabbit', version: '1.1.0.RELEASE' testImplementation deps.testcontainers - - latestDepTestImplementation group: 'com.rabbitmq', name: 'amqp-client', version: '+' - latestDepTestImplementation group: 'org.springframework.amqp', name: 'spring-rabbit', version: '+' } configurations.testRuntime { diff --git a/instrumentation/ratpack-1.4/ratpack-1.4.gradle b/instrumentation/ratpack-1.4/ratpack-1.4.gradle index b1eca1845773..7b3da3214b68 100644 --- a/instrumentation/ratpack-1.4/ratpack-1.4.gradle +++ b/instrumentation/ratpack-1.4/ratpack-1.4.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -15,18 +14,11 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'io.ratpack', name: 'ratpack-core', version: '1.4.0' + library group: 'io.ratpack', name: 'ratpack-core', version: '1.4.0' + testLibrary group: 'io.ratpack', name: 'ratpack-groovy-test', version: '1.4.0' testImplementation project(':instrumentation:netty:netty-4.1') - testImplementation group: 'io.ratpack', name: 'ratpack-groovy-test', version: '1.4.0' - latestDepTestImplementation group: 'io.ratpack', name: 'ratpack-groovy-test', version: '+' if (JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_11)) { testImplementation group: 'com.sun.activation', name: 'jakarta.activation', version: '1.2.2' } diff --git a/instrumentation/reactor-3.1/reactor-3.1.gradle b/instrumentation/reactor-3.1/reactor-3.1.gradle index 03181351842e..47b66ffd3dfc 100644 --- a/instrumentation/reactor-3.1/reactor-3.1.gradle +++ b/instrumentation/reactor-3.1/reactor-3.1.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -15,18 +14,12 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation project(':instrumentation-core:reactor-3.1') - testImplementation group: 'io.projectreactor', name: 'reactor-core', version: '3.1.0.RELEASE' + testLibrary group: 'io.projectreactor', name: 'reactor-core', version: '3.1.0.RELEASE' - latestDepTestImplementation group: 'io.projectreactor', name: 'reactor-core', version: '3.+' + latestDepTestLibrary group: 'io.projectreactor', name: 'reactor-core', version: '3.+' // Looks like later versions on reactor need this dependency for some reason even though it is marked as optional. - latestDepTestImplementation group: 'io.micrometer', name: 'micrometer-core', version: '1.+' + latestDepTestLibrary group: 'io.micrometer', name: 'micrometer-core', version: '1.+' } diff --git a/instrumentation/rediscala-1.8/rediscala-1.8.gradle b/instrumentation/rediscala-1.8/rediscala-1.8.gradle index 65f17a4d1bb7..c68f92a54ec5 100644 --- a/instrumentation/rediscala-1.8/rediscala-1.8.gradle +++ b/instrumentation/rediscala-1.8/rediscala-1.8.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -49,17 +48,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'com.github.etaty', name: 'rediscala_2.11', version: '1.8.0' + library group: 'com.github.etaty', name: 'rediscala_2.11', version: '1.8.0' - testImplementation group: 'com.github.etaty', name: 'rediscala_2.11', version: '1.8.0' testImplementation group: 'com.github.kstyrc', name: 'embedded-redis', version: '0.6' - - latestDepTestImplementation group: 'com.github.etaty', name: 'rediscala_2.11', version: '+' } diff --git a/instrumentation/servlet/glassfish-testing/glassfish-testing.gradle b/instrumentation/servlet/glassfish-testing/glassfish-testing.gradle index ce0fb8afedcc..9112260f554f 100644 --- a/instrumentation/servlet/glassfish-testing/glassfish-testing.gradle +++ b/instrumentation/servlet/glassfish-testing/glassfish-testing.gradle @@ -4,19 +4,11 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { testImplementation project(':instrumentation:servlet:servlet-3.0') testImplementation project(':instrumentation:grizzly-2.0') - testImplementation group: 'org.glassfish.main.extras', name: 'glassfish-embedded-all', version: '4.0' - latestDepTestImplementation group: 'org.glassfish.main.extras', name: 'glassfish-embedded-all', version: '+' + testLibrary group: 'org.glassfish.main.extras', name: 'glassfish-embedded-all', version: '4.0' } diff --git a/instrumentation/servlet/servlet-2.2/servlet-2.2.gradle b/instrumentation/servlet/servlet-2.2/servlet-2.2.gradle index 919a7fc7ef55..9cdb8c0cceea 100644 --- a/instrumentation/servlet/servlet-2.2/servlet-2.2.gradle +++ b/instrumentation/servlet/servlet-2.2/servlet-2.2.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -16,12 +15,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { compileOnly group: 'javax.servlet', name: 'servlet-api', version: '2.2' api(project(':instrumentation-core:servlet')) @@ -29,9 +22,9 @@ dependencies { testImplementation(project(':testing-common')) { exclude group: 'org.eclipse.jetty', module: 'jetty-server' } - testImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.0.0.v20091005' - testImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.0.0.v20091005' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.0.0.v20091005' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.0.0.v20091005' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.+' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.+' } diff --git a/instrumentation/servlet/servlet-3.0/servlet-3.0.gradle b/instrumentation/servlet/servlet-3.0/servlet-3.0.gradle index 0d00599d9347..0efbf209d707 100644 --- a/instrumentation/servlet/servlet-3.0/servlet-3.0.gradle +++ b/instrumentation/servlet/servlet-3.0/servlet-3.0.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -15,12 +14,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { compileOnly group: 'javax.servlet', name: 'javax.servlet-api', version: '3.0.1' api(project(':instrumentation-core:servlet')) @@ -28,17 +21,17 @@ dependencies { testImplementation(project(':testing-common')) { exclude group: 'org.eclipse.jetty', module: 'jetty-server' } - testImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '8.0.0.v20110901' - testImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '8.0.0.v20110901' - testImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '8.0.41' - testImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '8.0.41' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '8.0.0.v20110901' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '8.0.0.v20110901' + testLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '8.0.41' + testLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '8.0.41' // Jetty 10 seems to refuse to run on java8. // TODO: we need to setup separate test for Jetty 10 when that is released. - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.+' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.+' + latestDepTestLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.+' // FIXME: 9.0.24 seems to have changed something... - latestDepTestImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '9.0.22' - latestDepTestImplementation group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '9.0.22' + latestDepTestLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-core', version: '9.0.22' + latestDepTestLibrary group: 'org.apache.tomcat.embed', name: 'tomcat-embed-jasper', version: '9.0.22' } diff --git a/instrumentation/servlet/servlet-common/servlet-common.gradle b/instrumentation/servlet/servlet-common/servlet-common.gradle index e0aee8c47bef..4185079c1cfc 100644 --- a/instrumentation/servlet/servlet-common/servlet-common.gradle +++ b/instrumentation/servlet/servlet-common/servlet-common.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,19 +9,12 @@ muzzle { } } -testSets { - latestDepTest -} - dependencies { compileOnly group: 'javax.servlet', name: 'servlet-api', version: '2.3' testImplementation(project(':testing-common')) { exclude group: 'org.eclipse.jetty', module: 'jetty-server' } - testImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.0.0.v20091005' - testImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.0.0.v20091005' - - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '+' - latestDepTestImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '+' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-server', version: '7.0.0.v20091005' + testLibrary group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '7.0.0.v20091005' } diff --git a/instrumentation/spark-web-framework-2.3/spark-web-framework-2.3.gradle b/instrumentation/spark-web-framework-2.3/spark-web-framework-2.3.gradle index 66a0d9153ddb..30dad608aac4 100644 --- a/instrumentation/spark-web-framework-2.3/spark-web-framework-2.3.gradle +++ b/instrumentation/spark-web-framework-2.3/spark-web-framework-2.3.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' // building against 2.3 and testing against 2.4 because JettyHandler is available since 2.4 only muzzle { @@ -16,17 +15,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - -latestDepTest { - sourceCompatibility = "1.8" - targetCompatibility = "1.8" -} - compileTestJava { sourceCompatibility = "1.8" targetCompatibility = "1.8" @@ -38,11 +26,9 @@ compileJava { } dependencies { - compileOnly group: 'com.sparkjava', name: 'spark-core', version: '2.3' + library group: 'com.sparkjava', name: 'spark-core', version: '2.3' testImplementation project(':instrumentation:jetty-8.0') - testImplementation group: 'com.sparkjava', name: 'spark-core', version: '2.4' - - latestDepTestImplementation group: 'com.sparkjava', name: 'spark-core', version: '+' + testLibrary group: 'com.sparkjava', name: 'spark-core', version: '2.4' } diff --git a/instrumentation/spring-data-1.8/spring-data-1.8.gradle b/instrumentation/spring-data-1.8/spring-data-1.8.gradle index e2a325d14293..4fb16a52a1d6 100644 --- a/instrumentation/spring-data-1.8/spring-data-1.8.gradle +++ b/instrumentation/spring-data-1.8/spring-data-1.8.gradle @@ -1,7 +1,6 @@ // This file includes software developed at SignalFx apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { // We have two independent covariants, so we have to test them independently. @@ -31,23 +30,19 @@ testSets { // For now, that limits support to spring-data-commons 1.9.0 (maybe 1.8.0). // For testing, chose a couple spring-data modules that are old enough to work with 1.9.0. dependencies { - compileOnly(group: 'org.springframework.data', name: 'spring-data-commons', version: '1.8.0.RELEASE') + library group: 'org.springframework.data', name: 'spring-data-commons', version: '1.8.0.RELEASE' compileOnly(group: 'org.springframework', name: 'spring-aop', version: '1.2') testImplementation group: 'org.spockframework', name: 'spock-spring', version: "$versions.spock" - testImplementation group: 'org.springframework', name: 'spring-test', version: '3.0.0.RELEASE' + testLibrary group: 'org.springframework', name: 'spring-test', version: '3.0.0.RELEASE' // JPA dependencies testImplementation project(':instrumentation:jdbc') - testImplementation group: 'org.springframework.data', name: 'spring-data-jpa', version: '1.8.0.RELEASE' + testLibrary group: 'org.springframework.data', name: 'spring-data-jpa', version: '+' testImplementation group: 'com.mysema.querydsl', name: 'querydsl-jpa', version: '3.7.4' testImplementation group: 'org.hsqldb', name: 'hsqldb', version: '2.0.0' testImplementation group: 'org.hibernate', name: 'hibernate-entitymanager', version: '4.3.0.Final' - latestDepTestImplementation group: 'org.springframework', name: 'spring-test', version: '+' - latestDepTestImplementation group: 'org.springframework', name: 'spring-context', version: '+' - - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-commons', version: '+' - latestDepTestImplementation group: 'org.springframework.data', name: 'spring-data-jpa', version: '+' + latestDepTestLibrary group: 'org.springframework', name: 'spring-context', version: '+' } diff --git a/instrumentation/spring-scheduling-3.1/spring-scheduling-3.1.gradle b/instrumentation/spring-scheduling-3.1/spring-scheduling-3.1.gradle index cd5eb3bc9b2f..df7f5611b613 100644 --- a/instrumentation/spring-scheduling-3.1/spring-scheduling-3.1.gradle +++ b/instrumentation/spring-scheduling-3.1/spring-scheduling-3.1.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,18 +9,12 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { // 3.2.3 is the first version with which the tests will run. Lower versions require other // classes and packages to be imported. Versions 3.1.0+ work with the instrumentation. - compileOnly group: 'org.springframework', name: 'spring-context', version: '3.1.0.RELEASE' - testImplementation group: 'org.springframework', name: 'spring-context', version: '3.2.3.RELEASE' + library group: 'org.springframework', name: 'spring-context', version: '3.1.0.RELEASE' + testLibrary group: 'org.springframework', name: 'spring-context', version: '3.2.3.RELEASE' // this is the latest version that supports Java 7 - latestDepTestImplementation group: 'org.springframework', name: 'spring-context', version: '4.+' + latestDepTestLibrary group: 'org.springframework', name: 'spring-context', version: '4.+' } diff --git a/instrumentation/spring-webflux-5.0/spring-webflux-5.0.gradle b/instrumentation/spring-webflux-5.0/spring-webflux-5.0.gradle index 01358b8eb0b8..527a21ee465e 100644 --- a/instrumentation/spring-webflux-5.0/spring-webflux-5.0.gradle +++ b/instrumentation/spring-webflux-5.0/spring-webflux-5.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -23,12 +22,6 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { implementation project(':instrumentation-core:spring:spring-webflux-5.0') compileOnly group: 'org.springframework', name: 'spring-webflux', version: '5.0.0.RELEASE' @@ -37,13 +30,13 @@ dependencies { testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:reactor-3.1') - testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-webflux', version: '2.0.0.RELEASE' - testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: '2.0.0.RELEASE' - testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-reactor-netty', version: '2.0.0.RELEASE' + testLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-webflux', version: '2.0.0.RELEASE' + testLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: '2.0.0.RELEASE' + testLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-reactor-netty', version: '2.0.0.RELEASE' testImplementation group: 'org.spockframework', name: 'spock-spring', version: '1.1-groovy-2.4' // FIXME: reactor-netty packages have changed so test imports are failing - latestDepTestImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-webflux', version: '2.0.+' - latestDepTestImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: '2.0.+' - latestDepTestImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-reactor-netty', version: '2.0.+' + latestDepTestLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-webflux', version: '2.0.+' + latestDepTestLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: '2.0.+' + latestDepTestLibrary group: 'org.springframework.boot', name: 'spring-boot-starter-reactor-netty', version: '2.0.+' } diff --git a/instrumentation/spymemcached-2.12/spymemcached-2.12.gradle b/instrumentation/spymemcached-2.12/spymemcached-2.12.gradle index bbc54869cc52..7a358eb19955 100644 --- a/instrumentation/spymemcached-2.12/spymemcached-2.12.gradle +++ b/instrumentation/spymemcached-2.12/spymemcached-2.12.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -10,17 +9,8 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - dependencies { - compileOnly group: 'net.spy', name: 'spymemcached', version: '2.12.0' + library group: 'net.spy', name: 'spymemcached', version: '2.12.0' - testImplementation group: 'net.spy', name: 'spymemcached', version: '2.12.0' testImplementation deps.testcontainers - - latestDepTestImplementation group: 'net.spy', name: 'spymemcached', version: '+' } diff --git a/instrumentation/twilio-6.6/twilio-6.6.gradle b/instrumentation/twilio-6.6/twilio-6.6.gradle index fc01a4dda295..93366c61fb6e 100644 --- a/instrumentation/twilio-6.6/twilio-6.6.gradle +++ b/instrumentation/twilio-6.6/twilio-6.6.gradle @@ -1,5 +1,4 @@ apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -9,16 +8,9 @@ muzzle { } } -testSets { - latestDepTest -} - dependencies { - compileOnly group: 'com.twilio.sdk', name: 'twilio', version: '6.6.9' + library group: 'com.twilio.sdk', name: 'twilio', version: '6.6.9' - testImplementation group: 'com.twilio.sdk', name: 'twilio', version: '6.6.9' testImplementation project(':instrumentation:apache-httpclient:apache-httpclient-4.0') testImplementation group: 'nl.jqno.equalsverifier', name: 'equalsverifier', version: '2.5.2' // Last version to support Java7 - - latestDepTestImplementation group: 'com.twilio.sdk', name: 'twilio', version: '+' } diff --git a/instrumentation/vertx-3.0/vertx-3.0.gradle b/instrumentation/vertx-3.0/vertx-3.0.gradle index b20dfc1bdcd4..71debd5de324 100644 --- a/instrumentation/vertx-3.0/vertx-3.0.gradle +++ b/instrumentation/vertx-3.0/vertx-3.0.gradle @@ -4,7 +4,6 @@ ext { } apply from: "${rootDir}/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -14,26 +13,19 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - ext.vertxVersion = '3.0.0' dependencies { - compileOnly group: 'io.vertx', name: 'vertx-web', version: vertxVersion + library group: 'io.vertx', name: 'vertx-web', version: vertxVersion //We need both version as different versions of Vert.x use different versions of Netty testImplementation project(':instrumentation:netty:netty-4.0') testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:jdbc') - testImplementation group: 'io.vertx', name: 'vertx-web', version: vertxVersion testImplementation group: 'io.vertx', name: 'vertx-jdbc-client', version: vertxVersion // Vert.x 4.0 is incompatible with our tests. - latestDepTestImplementation group: 'io.vertx', name: 'vertx-web', version: '3.+' - latestDepTestImplementation group: 'io.vertx', name: 'vertx-web-client', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-web', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-web-client', version: '3.+' } diff --git a/instrumentation/vertx-reactive-3.5/vertx-reactive-3.5.gradle b/instrumentation/vertx-reactive-3.5/vertx-reactive-3.5.gradle index f95f1a48c1bd..4c2a5e3578b7 100644 --- a/instrumentation/vertx-reactive-3.5/vertx-reactive-3.5.gradle +++ b/instrumentation/vertx-reactive-3.5/vertx-reactive-3.5.gradle @@ -3,7 +3,6 @@ ext { } apply from: "$rootDir/gradle/instrumentation.gradle" -apply plugin: 'org.unbroken-dome.test-sets' muzzle { pass { @@ -13,34 +12,26 @@ muzzle { } } -testSets { - latestDepTest { - dirName = 'test' - } -} - //The first Vert.x version that uses rx-java 2 ext.vertxVersion = '3.5.0' dependencies { - compileOnly group: 'io.vertx', name: 'vertx-web', version: vertxVersion - compileOnly group: 'io.vertx', name: 'vertx-rx-java2', version: vertxVersion + library group: 'io.vertx', name: 'vertx-web', version: vertxVersion + library group: 'io.vertx', name: 'vertx-rx-java2', version: vertxVersion testImplementation project(':instrumentation:jdbc') testImplementation project(':instrumentation:netty:netty-4.1') testImplementation project(':instrumentation:vertx-3.0') - testImplementation group: 'io.vertx', name: 'vertx-web', version: vertxVersion - testImplementation group: 'io.vertx', name: 'vertx-web-client', version: vertxVersion - testImplementation group: 'io.vertx', name: 'vertx-jdbc-client', version: vertxVersion - testImplementation group: 'io.vertx', name: 'vertx-circuit-breaker', version: vertxVersion - testImplementation group: 'io.vertx', name: 'vertx-rx-java2', version: vertxVersion + testLibrary group: 'io.vertx', name: 'vertx-web-client', version: vertxVersion + testLibrary group: 'io.vertx', name: 'vertx-jdbc-client', version: vertxVersion + testLibrary group: 'io.vertx', name: 'vertx-circuit-breaker', version: vertxVersion testImplementation 'org.hsqldb:hsqldb:2.3.4' // Vert.x 4.0 is incompatible with our tests. - latestDepTestImplementation group: 'io.vertx', name: 'vertx-web', version: '3.+' - latestDepTestImplementation group: 'io.vertx', name: 'vertx-web-client', version: '3.+' - latestDepTestImplementation group: 'io.vertx', name: 'vertx-jdbc-client', version: '3.+' - latestDepTestImplementation group: 'io.vertx', name: 'vertx-circuit-breaker', version: '3.+' - latestDepTestImplementation group: 'io.vertx', name: 'vertx-rx-java2', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-web', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-web-client', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-jdbc-client', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-circuit-breaker', version: '3.+' + latestDepTestLibrary group: 'io.vertx', name: 'vertx-rx-java2', version: '3.+' }