Update docs about needing java 11 to build
MODIFY
CONTRIBUTING.md
CONTRIBUTING.md
Pull requests for bug fixes are welcome, but before submitting new features or changes to current functionality [open an issue](https://github.com/open-telemetry/opentelemetry-auto-instr-java/issues/new)
and discuss your ideas or propose the changes you wish to make. After a resolution is reached a PR can be submitted for review.
-In order to fully build and test this whole repository you need the following:
-* Installed both JDK 8 and 9.
-* Java 8 should be set as default: `java -version` should give you version 8.
-* Defined environment variables `JAVA_8_HOME` and `JAVA_9_HOME` which point to the corresponding java homes.
+In order to build and test this whole repository you need JDK 11+.
+Some instrumentations and tests may put constraints on which java versions they support.
+See [Executing tests with specific java version](#Executing tests with specific java version) below.
### Plugin structure
OpenTelemetry Auto Instrumentation java agent's jar can logically be divided into 3 parts.

MODIFY
instrumentation/akka-http-10.0/akka-http-10.0.gradle
instrumentation/akka-http-10.0/akka-http-10.0.gradle
@@ -112,6 +112,7 @@ compileLatestDepTestGroovy {
// They all use the same constraints as the main test source set.
lagomTest {
onlyIf {
- executable == toExecutable(findJavaHome(JavaVersion.VERSION_1_8))
+ String java8Home = findJavaHome(JavaVersion.VERSION_1_8)
+ java8Home != null && executable == toExecutable(java8Home)
}
}

MODIFY
instrumentation/java-concurrent/java-concurrent.gradle
instrumentation/java-concurrent/java-concurrent.gradle
@@ -40,6 +40,7 @@ test.dependsOn slickTest
// force this one test to run on java8 only
slickTest {
onlyIf {
- executable == toExecutable(findJavaHome(JavaVersion.VERSION_1_8))
+ String java8Home = findJavaHome(JavaVersion.VERSION_1_8)
+ java8Home != null && executable == toExecutable(java8Home)
}
}

MODIFY
instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle
instrumentation/jaxrs/jaxrs-2.0/jaxrs-2.0.gradle
@@ -56,6 +56,7 @@ test.dependsOn resteasy31Test
// force this one test to run on java8 only
resteasy31Test {
onlyIf {
- executable == toExecutable(findJavaHome(JavaVersion.VERSION_1_8))
+ String java8Home = findJavaHome(JavaVersion.VERSION_1_8)
+ java8Home != null && executable == toExecutable(java8Home)
}
}

Update docs about needing java 11 to build (#412)