Skip to content

Commit fa27700

Browse files
committed
JAVA-2560 : Update Evergreen configuration
* Specify that Java 9 should be used for compilation in all scripts * Specify that the store type is JKS when running keytool, so that the generated trust store can be read by Java 6
1 parent be95177 commit fa27700

File tree

7 files changed

+16
-16
lines changed

7 files changed

+16
-16
lines changed

.evergreen/compile.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ set -o errexit # Exit the script with error if any of the commands fail
77
# Main Program #
88
############################################
99

10-
echo "Compiling java driver with jdk8"
10+
echo "Compiling java driver with jdk9"
1111

1212
# We always compile with the latest version of java
13-
export JAVA_HOME="/opt/java/jdk8"
13+
export JAVA_HOME="/opt/java/jdk9"
1414
./gradlew -version
1515
./gradlew -PxmlReports.enabled=true --info -x test clean check jar testClasses docs

.evergreen/publish.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ echo ${RING_FILE_GPG_BASE64} | base64 -d > ${PROJECT_DIRECTORY}/secring.gpg
1212

1313
trap "rm ${PROJECT_DIRECTORY}/secring.gpg; exit" EXIT HUP
1414

15-
echo "Publishing snapshot with jdk8"
15+
echo "Publishing snapshot with jdk9"
1616

17-
export JAVA_HOME="/opt/java/jdk8"
17+
export JAVA_HOME="/opt/java/jdk9"
1818

1919
export ORG_GRADLE_PROJECT_nexusUsername=${NEXUS_USERNAME}
2020
export ORG_GRADLE_PROJECT_nexusPassword=${NEXUS_PASSWORD}

.evergreen/run-connectivity-tests.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ set -o errexit # Exit the script with error if any of the commands fail
55

66
# Supported/used environment variables:
77
# JDK Set the version of java to be used. Java versions can be set from the java toolchain /opt/java
8-
# "jdk5", "jdk6", "jdk7", "jdk8"
8+
# "jdk5", "jdk6", "jdk7", "jdk8", "jdk9"
99
# Support arguments:
1010
# Pass as many MongoDB URIS as arguments to this script as required
1111

@@ -18,7 +18,7 @@ JDK=${JDK:-jdk}
1818
echo "Running connectivity tests with ${JDK}"
1919

2020
# We always compile with the latest version of java
21-
export JAVA_HOME="/opt/java/jdk8"
21+
export JAVA_HOME="/opt/java/jdk9"
2222

2323
./gradlew -version
2424

.evergreen/run-gssapi-auth-test.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ set -o errexit # Exit the script with error if any of the commands fail
66
# Supported/used environment variables:
77
# MONGODB_URI Set the URI, including username/password to use to connect to the server via PLAIN authentication mechanism
88
# JDK Set the version of java to be used. Java versions can be set from the java toolchain /opt/java
9-
# "jdk5", "jdk6", "jdk7", "jdk8"
9+
# "jdk5", "jdk6", "jdk7", "jdk8", "jdk9"
1010
# KDC The KDC
1111
# REALM The realm
1212
# KEYTAB_BASE64 The BASE64-encoded keytab
@@ -31,10 +31,10 @@ com.sun.security.jgss.krb5.initiate {
3131
};
3232
EOF
3333

34-
echo "Compiling java driver with jdk8"
34+
echo "Compiling java driver with jdk9"
3535

3636
# We always compile with the latest version of java
37-
export JAVA_HOME="/opt/java/jdk8"
37+
export JAVA_HOME="/opt/java/jdk9"
3838

3939
echo "Running tests with ${JDK}"
4040
./gradlew -version

.evergreen/run-plain-auth-test.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ set -o errexit # Exit the script with error if any of the commands fail
66
# Supported/used environment variables:
77
# MONGODB_URI Set the URI, including username/password to use to connect to the server via PLAIN authentication mechanism
88
# JDK Set the version of java to be used. Java versions can be set from the java toolchain /opt/java
9-
# "jdk5", "jdk6", "jdk7", "jdk8"
9+
# "jdk5", "jdk6", "jdk7", "jdk8", "jdk9"
1010

1111
JDK=${JDK:-jdk}
1212

@@ -17,7 +17,7 @@ JDK=${JDK:-jdk}
1717
echo "Running PLAIN authentication tests"
1818

1919
# We always compile with the latest version of java
20-
export JAVA_HOME="/opt/java/jdk8"
20+
export JAVA_HOME="/opt/java/jdk9"
2121

2222
echo "Running tests with ${JDK}"
2323
./gradlew -version

.evergreen/run-socket-tests.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ set -o errexit # Exit the script with error if any of the commands fail
1010
# Supported values: "server", "replica_set", "sharded_cluster"
1111
# COMPRESSOR Set to enable compression. Values are "snappy" and "zlib" (default is no compression)
1212
# JDK Set the version of java to be used. Java versions can be set from the java toolchain /opt/java
13-
# "jdk5", "jdk6", "jdk7", "jdk8"
13+
# "jdk5", "jdk6", "jdk7", "jdk8", "jdk9"
1414

1515
AUTH=${AUTH:-noauth}
1616
MONGODB_URI=${MONGODB_URI:-}
@@ -48,7 +48,7 @@ fi
4848
echo "Running $AUTH tests over for $TOPOLOGY and connecting to $MONGODB_URI"
4949

5050
# We always compile with the latest version of java
51-
export JAVA_HOME="/opt/java/jdk8"
51+
export JAVA_HOME="/opt/java/jdk9"
5252

5353
echo "Running tests with ${JDK}"
5454
./gradlew -version

.evergreen/run-tests.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ set -o errexit # Exit the script with error if any of the commands fail
1111
# Supported values: "server", "replica_set", "sharded_cluster"
1212
# COMPRESSOR Set to enable compression. Values are "snappy" and "zlib" (default is no compression)
1313
# JDK Set the version of java to be used. Java versions can be set from the java toolchain /opt/java
14-
# "jdk5", "jdk6", "jdk7", "jdk8"
14+
# "jdk5", "jdk6", "jdk7", "jdk8", "jdk9"
1515

1616
AUTH=${AUTH:-noauth}
1717
SSL=${SSL:-nossl}
@@ -28,7 +28,7 @@ else
2828
fi
2929

3030
# We always compile with the latest version of java
31-
export JAVA_HOME="/opt/java/jdk8"
31+
export JAVA_HOME="/opt/java/jdk9"
3232

3333

3434
############################################
@@ -43,7 +43,7 @@ provision_ssl () {
4343
openssl pkcs12 -CAfile ${DRIVERS_TOOLS}/.evergreen/x509gen/ca.pem -export -in ${DRIVERS_TOOLS}/.evergreen/x509gen/client.pem -out client.pkc -password pass:bithere
4444
fi
4545
if [ ! -f mongo-truststore ]; then
46-
echo "y" | ${JAVA_HOME}/bin/keytool -importcert -trustcacerts -file ${DRIVERS_TOOLS}/.evergreen/x509gen/ca.pem -keystore mongo-truststore -storepass hithere
46+
${JAVA_HOME}/bin/keytool -importcert -trustcacerts -file ${DRIVERS_TOOLS}/.evergreen/x509gen/ca.pem -keystore mongo-truststore -storepass hithere -storetype JKS -noprompt
4747
fi
4848

4949
# We add extra gradle arguments for SSL

0 commit comments

Comments
 (0)