adoptium / adoptium/infrastructure

Three jdk21u tests in `jdk_security1_0` fail on Windows if `wsl.exe` is available

Open
#3,853 3 comments 0 reactions 0 assignees View on GitHub
os:windows testFail
Dominant language
Python
Stars
96
Forks
106
Avg merge
1d 23h
Merged PRs (30d)
13

Description

Please set the title to indicate the test name and machine name where known.

To make it easy for the infrastructure team to repeat and diagnose, please
answer the following questions:

- test suite/name (e.g, BUILD_LIST, TARGET, CUSTOM_TARGET)? jdk_security1_0 but specifically [java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh.ClassLoaderDeadlock](https://ci.adoptium.net/job/Grinder/12157/testReport/java_security_Security_ClassLoaderDeadlock_ClassLoaderDeadlock/sh/ClassLoaderDeadlock/) [java/security/Security/ClassLoaderDeadlock/Deadlock.sh.Deadlock](https://ci.adoptium.net/job/Grinder/12157/testReport/java_security_Security_ClassLoaderDeadlock_Deadlock/sh/Deadlock/) [java/security/cert/CertificateFactory/slowstream.sh.slowstream](https://ci.adoptium.net/job/Grinder/12157/testReport/java_security_cert_CertificateFactory_slowstream/sh/slowstream/)
- a link into recent `Test_` job on https://ci.adoptium.net which showed the failure https://ci.adoptium.net/job/Grinder/12157/testReport/ - pass with workaround is shown in https://ci.adoptium.net/job/Grinder/12158/testReport/
- **Hyperlink** to re-run in Grinder: [Full suite](https://ci.adoptium.net/job/Grinder/parambuild/?SDK_RESOURCE=upstream&TARGET=testList+TESTLIST=jdk_security1_0&TEST_FLAG=&UPSTREAM_TEST_JOB_NAME=&DOCKER_REQUIRED=false&ACTIVE_NODE_TIMEOUT=5&VENDOR_TEST_DIRS=&EXTRA_DOCKER_ARGS=&TKG_OWNER_BRANCH=adoptium%3Amaster&OPENJ9_SYSTEMTEST_OWNER_BRANCH=eclipse%3Amaster&PLATFORM=x86-64_windows&GENERATE_JOBS=true&KEEP_REPORTDIR=true&PERSONAL_BUILD=false&ADOPTOPENJDK_REPO=https%3A%2F%2Fgithub.com%2Fadoptium%2Faqa-tests.git&RERUN_ITERATIONS=0&LABEL=&EXTRA_OPTIONS=&CUSTOMIZED_SDK_URL=&BUILD_IDENTIFIER=&ADOPTOPENJDK_BRANCH=master&LIGHT_WEIGHT_CHECKOUT=false&NON_AQA_TEST_REPOS=&USE_JRE=false&ARTIFACTORY_SERVER=&KEEP_WORKSPACE=false&USER_CREDENTIALS_ID=&JDK_VERSION=21&ITERATIONS=1&VENDOR_TEST_REPOS=&JDK_REPO=https%3A%2F%2Fgithub.com%2Fadoptium%2Fjdk21u&OPENJ9_BRANCH=master&OPENJ9_SHA=&JCK_GIT_REPO=&VENDOR_TEST_BRANCHES=&OPENJ9_REPO=https%3A%2F%2Fgithub.com%2Feclipse-openj9%2Fopenj9.git&UPSTREAM_JOB_NAME=build-scripts%2Fjobs%2Fjdk21u%2Fjdk21u-windows-x64-temurin&CLOUD_PROVIDER=&PLATFORM_AND_MACHINE=&CUSTOM_TARGET=&VENDOR_TEST_SHAS=&JDK_BRANCH=jdk-21.0.6%2B6_adopt&TEST_IMAGES_REQUIRED=true&LABEL_ADDITION=test-azure-win2022-x64-1&ARTIFACTORY_REPO=&ARTIFACTORY_ROOT_DIR=&UPSTREAM_TEST_JOB_NUMBER=&DOCKERIMAGE_TAG=&JDK_IMPL=hotspot&TEST_TIME=120&SSH_AGENT_CREDENTIAL=&AUTO_DETECT=true&SLACK_CHANNEL=aqavit-bot&DYNAMIC_COMPILE=false&ADOPTOPENJDK_SYSTEMTEST_OWNER_BRANCH=adoptium%3Amaster&APPLICATION_OPTIONS=&CUSTOMIZED_SDK_URL_CREDENTIAL_ID=eclipse_temurin_bot_email_and_token&ARCHIVE_TEST_RESULTS=false&OPENJDK_SHA=&NUM_MACHINES=&RERUN_FAILURE=false&BUILD_LIST=openjdk&USE_TESTENV_PROPERTIES=false&UPSTREAM_JOB_NUMBER=248&STF_OWNER_BRANCH=adoptium%3Amaster&TIME_LIMIT=25&JVM_OPTIONS=&PARALLEL=None) and [just the three test cases](https://ci.adoptium.net/job/Grinder/parambuild/?SDK_RESOURCE=upstream&TARGET=jdk_custom&TEST_FLAG=&UPSTREAM_TEST_JOB_NAME=&DOCKER_REQUIRED=false&ACTIVE_NODE_TIMEOUT=5&VENDOR_TEST_DIRS=&EXTRA_DOCKER_ARGS=&TKG_OWNER_BRANCH=adoptium%3Amaster&OPENJ9_SYSTEMTEST_OWNER_BRANCH=eclipse%3Amaster&PLATFORM=x86-64_windows&GENERATE_JOBS=true&KEEP_REPORTDIR=true&PERSONAL_BUILD=false&ADOPTOPENJDK_REPO=https%3A%2F%2Fgithub.com%2Fadoptium%2Faqa-tests.git&RERUN_ITERATIONS=0&LABEL=&EXTRA_OPTIONS=&CUSTOMIZED_SDK_URL=&BUILD_IDENTIFIER=&ADOPTOPENJDK_BRANCH=master&LIGHT_WEIGHT_CHECKOUT=false&NON_AQA_TEST_REPOS=&USE_JRE=false&ARTIFACTORY_SERVER=&KEEP_WORKSPACE=false&USER_CREDENTIALS_ID=&JDK_VERSION=21&ITERATIONS=1&VENDOR_TEST_REPOS=&JDK_REPO=https%3A%2F%2Fgithub.com%2Fadoptium%2Fjdk21u&OPENJ9_BRANCH=master&OPENJ9_SHA=&JCK_GIT_REPO=&VENDOR_TEST_BRANCHES=&OPENJ9_REPO=https%3A%2F%2Fgithub.com%2Feclipse-openj9%2Fopenj9.git&UPSTREAM_JOB_NAME=build-scripts%2Fjobs%2Fjdk21u%2Fjdk21u-windows-x64-temurin&CLOUD_PROVIDER=&PLATFORM_AND_MACHINE=&CUSTOM_TARGET=java%2Fsecurity%2Fcert%2FCertificateFactory%2Fslowstream.sh+java%2Fsecurity%2FSecurity%2FClassLoaderDeadlock%2FClassLoaderDeadlock.sh+java%2Fsecurity%2FSecurity%2FClassLoaderDeadlock%2FDeadlock.sh&VENDOR_TEST_SHAS=&JDK_BRANCH=jdk-21.0.6%2B6_adopt&TEST_IMAGES_REQUIRED=true&LABEL_ADDITION=test-azure-win2022-x64-1&ARTIFACTORY_REPO=&ARTIFACTORY_ROOT_DIR=&UPSTREAM_TEST_JOB_NUMBER=&DOCKERIMAGE_TAG=&JDK_IMPL=hotspot&TEST_TIME=120&SSH_AGENT_CREDENTIAL=&AUTO_DETECT=true&SLACK_CHANNEL=aqavit-bot&DYNAMIC_COMPILE=false&ADOPTOPENJDK_SYSTEMTEST_OWNER_BRANCH=adoptium%3Amaster&APPLICATION_OPTIONS=&CUSTOMIZED_SDK_URL_CREDENTIAL_ID=eclipse_temurin_bot_email_and_token&ARCHIVE_TEST_RESULTS=false&OPENJDK_SHA=&NUM_MACHINES=&RERUN_FAILURE=false&BUILD_LIST=openjdk&USE_TESTENV_PROPERTIES=false&UPSTREAM_JOB_NUMBER=248&STF_OWNER_BRANCH=adoptium%3Amaster&TIME_LIMIT=25&JVM_OPTIONS=&PARALLEL=None)
- Is there an existing issue elsewhere covering this? Not exactly, but the analysis in https://github.com/adoptium/infrastructure/issues/2885#issuecomment-1942184443 seems relevant
- Which machine(s) does it work on? Probably none at the moment due to a wsl.exe update
- Which machine(s) does it fail on? Definitely test-azure-win2022-x64-1

Any other details:
- Renaming `wsl.exe` allows the tests to pass, although note that this has to be done using cygwin's `mv` command as `ren`, `move` from `cmd.exe` or renaming via explorer will [fail with a permission denied message](https://fosstodon.org/@sxa/113764095959162902). **THIS HAS BEEN DONE ON TEST-AZURE-WIN2022-X64-1 ONLY FOR NOW**
```
10:29:36 WSLENV=SystemDrive:SystemRoot:TEMP:TMP:windir:TESTFILE:TESTSRC:TESTSRCPATH:TESTCLASSES:TESTCLASSPATH:COMPILEJAVA/p:TESTJAVA/p:TESTVMOPTS:TESTTOOLVMOPTS:TESTJAVACOPTS:TESTJAVAOPTS:TESTTIMEOUTFACTOR:TESTROOT/p:TESTNATIVEPATH:NULL:EXE_SUFFIX:FS:PS \
10:29:36 wsl.exe \
10:29:36 sh /mnt/c/Jenkins/workspace/Grinder/aqa-tests/openjdk/openjdk-jdk/test/jdk/java/security/Security/ClassLoaderDeadlock/Deadlock.sh
10:29:36
10:29:36 TEST RESULT: Failed. Execution failed: exit code 1
10:29:36 --------------------------------------------------
10:30:45 Test results: passed: 218; failed: 3
```
Note that I'm not currently certain of what has caused this but there have been two potential things recently:
- `wsl.exe` on the machine is dated 14th November
- https://github.com/adoptium/jdk21u/commit/1af737e55216ca173e417ca56b82fb7487436789#diff-99681e386f74033838270af6ff252a91954e926643440ffd051f2adcaecf3e3f started passing in `TESTJAVAOPTS` to some of these tests which may have resulted in a dependency of having a WSL distribution installed if `wsl.exe` is on the machine.

Contributor guide

Open the contributing guide

Research direction

Start with the three named scripts: java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh, Deadlock.sh, and java/security/cert/CertificateFactory/slowstream.sh. Reproduce the failures using the linked Grinder jobs, then compare the behavior with wsl.exe renamed and review jdk21u commit 1af737e55216ca173e417ca56b82fb7487436789 and infrastructure issue 2885. Done means all three tests pass on test-azure-win2022-x64-1 without renaming wsl.exe.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
infrastructure, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.