Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimize STF generated paths to keep test paths as short as possible #95

Open
Mesbah-Alam opened this issue Dec 15, 2020 · 2 comments
Open
Assignees

Comments

@Mesbah-Alam
Copy link
Contributor

Mesbah-Alam commented Dec 15, 2020

Background

Windows platform's MAX_PATH restrictions have sporadically been causing STF based system tests to fail due to generated path lengths > MAX_PATH.

We have already been shortening some system test names as a fix.

However, to avoid such issues in future, we should investigate ways to optimize STF generated paths to keep them as short as possible.

Possible options to consider:

  1. Timestamp: When STF based system tests are run coupled with TKG, there are two timestamp values added in the test paths-- one from TKG and one from STF (e.g. F:/Users/jenkins/workspace/Test_openjdk11_j9_sanity.system_x86-64_windows_mixed_cm_Nightly_testList_1/openjdk-tests/\TKG\test_output_16076325439603\MauveSingleInvocationLoadTest_OpenJ9_0/20201210-145632-MauveSingleInvocationLoadTest/generation/generation.st). Could we remove the STF generated timestamp?
    1.1) Pro: It gives us test paths with only one timestamp in TKG runs.
    1.2) Con: It violates the STF use-case of running tests locally using system test make layer - when the STF generated timestamp is essential to distinguish between multiple runs of a particular test.

  2. STF appends the current tests's name after timestamp. This is useful when STF tests are run locally using the make layer, as we then get generated paths such as /tmp/stf/20201215-130158-MixedLoadTest/ - which clearly signify which test they belong to. However, when STF is used coupled with TKG (e.g. in Jenkins builds), we are already in a working directory that contains the test name, so the test folder name under that may not need the test name signifier again (e.g., ../MauveSingleInvocationLoadTest_OpenJ9_0/20201210-145632-MauveSingleInvocationLoadTest - which is unnecessary). Can we simply not append the test name in stf.pl ?
    2.1) Pro: This gives us a shorter path in Jenkins runs.
    2.2) Con: This means the local run using system test make layer would end up with paths without test name in them (e.g. /tmp/stf/20201215-130158).

@llxia @lumpfish

@lumpfish
Copy link
Contributor

lumpfish commented Dec 16, 2020

I run locally a lot, and find the current STF output naming system works very well.
Isn't the TKG name actually the playlist test target name (as opposed to the STF plugin test name)?

The way this has been fixed before (and the preferable way imo) is to use the Windows subst command to assign a drive letter to the root of the test output directory - e.g.

subst /d "T:" "F:/Users/jenkins/workspace/Test_openjdk11_j9_sanity.system_x86-64_windows_mixed_cm_Nightly_testList_1/openjdk-tests/\TKG\test_output_16076325439603\MauveSingleInvocationLoadTest_OpenJ9_0"

and from that point on use T: to refer to that location.

See #43 for more history. The subst option appears to have been disabled because of cygwin. Perhaps fixing that issue might be the best solution.

@llxia
Copy link
Contributor

llxia commented Dec 17, 2020

Have we tried mklink? Something like
mklink /J myShortDir F:/Users/jenkins/workspace/Test_openjdk11_j9_sanity.system_x86-64_windows_mixed_cm_Nightly_testList_1/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants