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

Added builder scripts for more code-tools - jcstress, jtharness, sigtest and jcov #766

Merged
merged 6 commits into from
Aug 16, 2023

Conversation

judovana
Copy link
Contributor

@judovana judovana commented Aug 7, 2023

No description provided.

@github-actions
Copy link

github-actions bot commented Aug 7, 2023

Thank you for creating a pull request!

Please check out the information below if you have not made a pull request here before (or if you need a reminder how things work).

Code Quality and Contributing Guidelines

If you have not done so already, please familiarise yourself with our Contributing Guidelines and Code Of Conduct, even if you have contributed before.

Tests

Github actions will run a set of jobs against your PR that will lint and unit test your changes. Keep an eye out for the results from these on the latest commit you submitted. For more information, please see our testing documentation.

In order to run the advanced pipeline tests (executing a set of mock pipelines), it requires an admin to post run tests on this PR.
If you are not an admin, please ask for one's attention in #infrastructure on Slack or ping one here.
To run full set of tests, use "run tests"; a subset of tests on specific jdk version, use "run tests quick 11,20"

@judovana
Copy link
Contributor Author

judovana commented Aug 7, 2023

If you would create a staging jenkins job, it wouldbe awesome.

tools/code-tools/jcstress.sh Show resolved Hide resolved
}

function detectJdks() {
jvm_dir="/usr/lib/jvm/"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This only builds on Linux, I wonder if there's a more O/S independent way to pass the java in

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For our CI farm we can of course pin to a Linux node if need be

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like below that Java 11 is required?

# latest released
git checkout $latestRelease
export JAVA_HOME=$jdk11
mvn clean install
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assumes mvn is installed on build host

git checkout $latestRelease
export JAVA_HOME=$jdk11
mvn clean install
mv tests-all/target/jcstress.jar $rc
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
mv tests-all/target/jcstress.jar $rc
mv tests-all/target/jcstress.jar $rc

git checkout master
export JAVA_HOME=$jdk11
mvn clean install
mv tests-all/target/$main_file $main_name-$tip_shortened.jar
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
mv tests-all/target/$main_file $main_name-$tip_shortened.jar
mv tests-all/target/$main_file $main_name-$tip_shortened.jar

@judovana
Copy link
Contributor Author

judovana commented Aug 8, 2023

Hello!
Thanx a lot for eyball!
Will fix the spaces. Sorry for that. I will add the comment header a separate changeset to all scripts in this directory (I'm planning to add also jtharness, sigtests and jcov).

As for the mvn and linux concerns, they are all valid, but based on other scripts this https://github.com/adoptium/ci-jenkins-pipelines/blob/master/tools/code-tools/Jenkinsfile is running, and the deployment of this pipeline, the mvn and linux and /sur/lib/jvm is expected combo, so I would not change that.

As for the jdk, I will remove the non jdk11 versions (unless you say otherwise). I actually thought, that there will be 3 jcstress artifacts - one old, for jdk8, built by jdk8, 16, b uilt by jdk11 for jdk 9-20 and tip, built by jdk 17, for jdk17 and up. But my information were misshaped, and all thre variants builds by jdk11 and works fine for jdks 8-20.
It may happen, that jdk21 will enforce a change on this part due to bytecode incompatiblity, but that is not yet in jcstress itself.

@judovana
Copy link
Contributor Author

judovana commented Aug 8, 2023

Doubel sapces removed and jdk count reduced in rebase

@judovana
Copy link
Contributor Author

judovana commented Aug 8, 2023

Your remarks have been resolved in best will. How does it look to you now?

@judovana judovana changed the title Added builder script for code-tools/jcstress Added builder script for more code-tools - jcstress, jtharness Aug 8, 2023
@judovana judovana changed the title Added builder script for more code-tools - jcstress, jtharness Added builder scripts for more code-tools - jcstress, jtharness Aug 8, 2023
#!/bin/bash

###################################################################
# Scrtipt to build jtharness reusable by jdk testing community #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Scrtipt to build jtharness reusable by jdk testing community #
# Script to build jtharness reusable by jdk testing community #

#!/bin/bash

###################################################################
# Scrtipt to build asmtools to be reused by jdk testing community #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Scrtipt to build asmtools to be reused by jdk testing community #
# Script to build asmtools to be reused by jdk testing community #


###################################################################
# Scrtipt to build jtharness reusable by jdk testing community #
# currenlty builds tip and latest released version #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# currenlty builds tip and latest released version #
# currently builds tip and latest released version #


###################################################################
# Scrtipt to build asmtools to be reused by jdk testing community #
# currenlty builds tip of master and tip of at8 branch #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# currenlty builds tip of master and tip of at8 branch #
# currently builds tip of master and tip of at8 branch #

#!/bin/bash

###################################################################
# Scrtipt to build jcstress to be reused by jdk testing community #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Scrtipt to build jcstress to be reused by jdk testing community #
# Script to build jcstress to be reused by jdk testing community #


###################################################################
# Scrtipt to build jcstress to be reused by jdk testing community #
# currenlty builds tip and latest released version #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# currenlty builds tip and latest released version #
# currently builds tip and latest released version #

@@ -1,4 +1,10 @@
#!/bin/bash

###################################################################
# Scrtipt to build jtreg test suite harness #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Scrtipt to build jtreg test suite harness #
# Script to build jtreg test suite harness #


###################################################################
# Scrtipt to build jtreg test suite harness #
# currenlty builds tip, 5.1, 6, 6.1, 7, 7.1, 7.2 #
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# currenlty builds tip, 5.1, 6, 6.1, 7, 7.1, 7.2 #
# currently builds tip, 5.1, 6, 6.1, 7, 7.1, 7.2 #

@judovana
Copy link
Contributor Author

judovana commented Aug 9, 2023

//me counting typo free lines
...2!

Sorry,:( all fixed, ty!

@judovana
Copy link
Contributor Author

judovana commented Aug 9, 2023

@karianna ty! @sophia-guo ca you set up a staging job for me please?

@judovana judovana changed the title Added builder scripts for more code-tools - jcstress, jtharness Added builder scripts for more code-tools - jcstress, jtharness, sigtest Aug 14, 2023
@github-actions github-actions bot added testing and removed testing labels Aug 14, 2023
@github-actions github-actions bot added testing and removed testing labels Aug 14, 2023
mv testng-$testngv.jar testng.jar
fi
if [ ! -e jcommander.jar ] ; then
jcommanderv=1.81
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
jcommanderv=1.81
local jcommanderv=1.81

@judovana
Copy link
Contributor Author

@karianna Sharp eye! fixed. TYVM!

@judovana
Copy link
Contributor Author

Usptream issue dealing with versions of jcov deps: https://bugs.openjdk.org/browse/CODETOOLS-7903520

WORKSPACE=$PWD

function hashArtifacts() {
echo "Creating checksums all sigtest*.jar"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sigtest*.jar --> sigtest*.zip?

@sophia-guo
Copy link
Contributor

I noticed that stage('sigtest') isn't added, is that expected?

Currently the stage('jtreg') builds jtreg.jar, which includes javatest.jar, asmtools.jar, jcov.jar and jcov_network_saver.jar, will the stage('javatest') and stage('jcov') be duplicate?

@judovana
Copy link
Contributor Author

Missing stage ro sigtest is error. Will fix. sorry.

Jtreg indeed downloads/builds its deps as it needs to do. They are version-less, and are not published as standalone artifacts.
Afaik it have sense to build all code-tools in the view of tip and latest released and soemtimes somespecial part (as eg asmtools does) and elave jtreg to pull what it needs.

But I do not insists. If you would eg rather copy the javatest and other similar artifacts out of jtreg.tar.gz then it can be done. But IMHO it is really different target.

@judovana
Copy link
Contributor Author

judovana commented Aug 16, 2023 via email

three tests are failing, and I think it is due to testng and
jcommander version clash, but I had failed to set better versions
combinations.

This needs to be elaborate in upstream
@judovana
Copy link
Contributor Author

Both issues fixed. Thank you.

Copy link
Contributor

@sophia-guo sophia-guo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks @judovana

@sophia-guo sophia-guo merged commit 41a2467 into adoptium:master Aug 16, 2023
6 checks passed
@judovana
Copy link
Contributor Author

Wait you merged it without staging job? :D I'm doomed..... Will keep en eye.. and tbh, I doubt I declared all the artifacts 100% correctly

@judovana
Copy link
Contributor Author

I can see the PR had all commits squashed. Is that a policy? The commits were maintained to be intentionally commit per script.

In https://ci.adoptium.net/view/Dependencies/job/dependency_pipeline/896/ are three errors:

  • jcov is missing in Jenkins file - I started to think git merge/reabse is doing something wrong
    • will fix
  • the version less simlinks are missing
    • I will replace soft link by hard links
  • the clone of javatest is failing, becasue the repo is actually named jtharness. I forget the jenkisn file is doing the clone on my behalf. Will fix too by renaming the stage to jtharness, and adjust artifacts

@judovana judovana mentioned this pull request Aug 16, 2023
@judovana
Copy link
Contributor Author

#783 is fixing ^

luhenry pushed a commit to luhenry/adoptium-ci-jenkins-pipelines that referenced this pull request Feb 3, 2024
…est and jcov (adoptium#766)

* Added builder script for code-tools/jcstress

* Added description to the code-tools build scripts

* Added builder for jtharness

* Added script for generating sigtest releases

* Added builder for jcov

* Added testrun for jcov

three tests are failing, and I think it is due to testng and
jcommander version clash, but I had failed to set better versions
combinations.

This needs to be elaborate in upstream
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants