-
-
Notifications
You must be signed in to change notification settings - Fork 314
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 churn testsuite #5101
Merged
Merged
Added churn testsuite #5101
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
2833dee
Added churn testsuite
judovana f6fa4df
instead of pushd, moved to results dir pernamently
judovana 517b988
Added second set of tests - without compressed oops
judovana e7c6f7c
Moved to system group
judovana 3dc815d
Adjusted description
judovana 4db1633
Removed NOCOMP=-nocoops variant in favour of global setting
judovana 550593a
split churn testsuit to churn_1m_all and churn_5h_all
judovana 655e499
added proper quoting
judovana 1cc8542
Onem ore rename of targets to churn_5h_allGCs and churn_1m_allGCs
judovana 2249bc0
added custom churn testcase
judovana ec66f1a
Updated README to proeprly describe churn_custom and extend it as needed
judovana 59ebac8
churn_1m_allGCs churn_5h_allGCsare now eclipse and redhat vendor only
judovana a7457b6
churn_custom is now disabled from automated testing
judovana b69d963
Adapted readme
judovana 9684763
No longer generate tap files on automated runs
judovana 8826b5d
moved churn to system
judovana 90ec5e7
Limited custom churn to 24h to not overwhel grinder
judovana File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# churn | ||
Test targeting garbage collector(s). | ||
The suite is able to operate with all GCs in OpenJDK. If your implementation is missing some, the calls to them will fall. If you have some additional one, an enabling wrapper must be created first. | ||
|
||
## Running churn locally | ||
clone https://github.com/rh-openjdk/churn read https://github.com/rh-openjdk/churn/blob/master/README and run run.sh | ||
|
||
### Setting up the environment: | ||
Java required. Maven recommended, churn can be compiled via direct javac if needed | ||
Java is used from JAVA_HOME or guessed from PATH. | ||
run.sh can use OTOOL_garbageCollector and OTOOL_JDK_VERSION instead of GC argument. See https://github.com/rh-openjdk/churn/blob/master/README for details. | ||
See https://github.com/rh-openjdk/churn/tree/master/bin for list of supported GCs. The compressed ops in upstream run can be controlled by runner or NOCOMP=-nocoops variable (for run.sh) | ||
|
||
## Running via AQAvit | ||
|
||
The support for compressed ops is handled by AQAvit itself. It is currently not sure if churn will be able to honor it. If not, churn will be fixed. | ||
Similarly the java version and JAVA_HOME are handled by AQAvit. | ||
|
||
### Executing the testsuite | ||
The `BUILD_LIST of system/churn` contains three targets: | ||
* _churn_1m_allGCs | ||
* _churn_5h_allGCs | ||
* _churn_custom | ||
|
||
There are major differences in them: | ||
* churn_1m_allGCs - is testing ground, which runs each GC only for aprox 10 seconds, to simply see if the setup works | ||
* churn_5h_allGCs - Is running each GC a bit over, which runs each GC for aprox hour and half. A minimum, which can find some real GC issue. | ||
* churn_custom - this one is to support development, when run on the commandline you need to export at least DURATION and/or OTOOL_garbageCollector (+ many more optional, see [upstream readme](https://github.com/rh-openjdk/churn/blob/master/README) to select DURATION in seconds and GC(or GCs). So it allows you to test your custom GC - if churn supports that, despite what other churn options suggest (eg `default` or `ALL` thinks). When running in a Jenkins Grinder job, those are wrapped in CHURN_GCS and CHURN_DURATION | ||
|
||
churn_1m_allGCs and churn_5h_allGCs are using pony `ALL` keyword, which is interpreted (based on hardcoded list) as all GC in tested JVM. The set time is divided among them. | ||
Note, that if you use `churn_custom` and enumeration, set `CHURN_GCS="ALL"` anyway, then the time will not be divided. The `CHURN_DURATION` is in seconds. If you use set, off GCs, eg `CHURN_GCS="zgc shenandoah"`, each willt ake the full CHURN_DURATION. | ||
The `CHURN_GCS="defaultgc"`will set the tested GC to default GC as run.sh think is right. So be aware. Although it is maintained, if your custom JDK have custom GC, it is unlikely to be known. If it have different default gc, it will correctly fail. | ||
|
||
### Reading results | ||
tap file and compressed junit xmlfile are generated. Use eg https://github.com/jenkinsci/report-jtreg-plugin or https://plugins.jenkins.io/tap/ to read them. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
<?xml version="1.0"?> | ||
|
||
<!-- | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
--> | ||
|
||
<project name="churn" default="build" basedir="."> | ||
<taskdef resource="net/sf/antcontrib/antlib.xml" /> | ||
<description> | ||
Test targeting garbage collector(s) | ||
</description> | ||
|
||
<!-- set properties for this build --> | ||
<property name="TEST" value="churn" /> | ||
<property name="DEST" value="${BUILD_ROOT}/system/churn" /> | ||
<property name="src" location="./churn" /> | ||
|
||
<target name="THC.check"> | ||
<condition property="THCdir.exists"> | ||
<available file="churn" type="dir"/> | ||
</condition> | ||
</target> | ||
|
||
<if> | ||
<contains string="${SPEC}" substring="zos"/> | ||
<then> | ||
<property name="GIT_REPO" value="[email protected]:" /> | ||
</then> | ||
<else> | ||
<property name="GIT_REPO" value="https://github.com/" /> | ||
</else> | ||
</if> | ||
|
||
<target name="getChurn" depends="THC.check" unless="THCdir.exists"> | ||
<exec executable="git" failonerror="true"> | ||
<arg value="clone" /> | ||
<arg value="${GIT_REPO}rh-openjdk/churn.git" /> | ||
</exec> | ||
</target> | ||
|
||
<target name="init"> | ||
<mkdir dir="${DEST}"/> | ||
</target> | ||
|
||
<target name="dist" depends="getChurn" description="generate the distribution"> | ||
<copy todir="${DEST}"> | ||
<fileset dir="${src}" includes="*.xml, *.mk"/> | ||
</copy> | ||
</target> | ||
|
||
<target name="build"> | ||
<antcall target="dist" inheritall="true" /> | ||
</target> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
<?xml version='1.0' encoding='UTF-8'?> | ||
<!-- | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
--> | ||
<playlist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../TKG/resources/playlist.xsd"> | ||
<test> | ||
<testCaseName>churn_1m_allGCs</testCaseName> | ||
<command> | ||
export OTOOL_JDK_VERSION="$(JDK_VERSION)" ; \ | ||
export JREJDK="jdk" ; \ | ||
export OTOOL_garbageCollector="ALL" ; \ | ||
export DURATION="60" ; \ | ||
export CHURN_TAP=false ; \ | ||
export TMPRESULTS="$(Q)$(REPORTDIR)$(D)report$(Q)"; \ | ||
cd $TMPRESULTS ; \ | ||
bash "$(TEST_ROOT)$(D)system$(D)churn$(D)churn$(D)run.sh"; \ | ||
$(TEST_STATUS) | ||
</command> | ||
<levels> | ||
<level>dev</level> | ||
</levels> | ||
<platformRequirementsList> | ||
<platformRequirements>os.linux</platformRequirements> | ||
<platformRequirements>os.win</platformRequirements> | ||
<platformRequirements>os.osx</platformRequirements> | ||
</platformRequirementsList> | ||
<groups> | ||
<group>system</group> | ||
</groups> | ||
<vendors> | ||
<vendor>eclipse</vendor> | ||
<vendor>redhat</vendor> | ||
</vendors> | ||
</test> | ||
<test> | ||
<testCaseName>churn_5h_allGCs</testCaseName> | ||
<command> | ||
export OTOOL_JDK_VERSION="$(JDK_VERSION)" ; \ | ||
export JREJDK="jdk" ; \ | ||
export OTOOL_garbageCollector="ALL" ; \ | ||
export DURATION="18000" ; \ | ||
export CHURN_TAP=false ; \ | ||
export TMPRESULTS="$(Q)$(REPORTDIR)$(D)report$(Q)"; \ | ||
cd $TMPRESULTS ; \ | ||
bash "$(TEST_ROOT)$(D)system$(D)churn$(D)churn$(D)run.sh"; \ | ||
$(TEST_STATUS) | ||
</command> | ||
<levels> | ||
<level>dev</level> | ||
</levels> | ||
<platformRequirementsList> | ||
<platformRequirements>os.linux</platformRequirements> | ||
<platformRequirements>os.win</platformRequirements> | ||
<platformRequirements>os.osx</platformRequirements> | ||
</platformRequirementsList> | ||
<groups> | ||
<group>system</group> | ||
</groups> | ||
<vendors> | ||
<vendor>eclipse</vendor> | ||
<vendor>redhat</vendor> | ||
</vendors> | ||
</test> | ||
<test> | ||
<testCaseName>churn_custom</testCaseName> | ||
<disables> | ||
<disable> | ||
<comment>Can run disabled.churn_custom in Grinder, meant for dev use not regular automated tests.</comment> | ||
</disable> | ||
</disables> | ||
<command> | ||
export OTOOL_JDK_VERSION="$(JDK_VERSION)" ; \ | ||
export JREJDK="jdk" ; \ | ||
export OTOOL_garbageCollector="${CHURN_GCS}" ; \ | ||
if [ "0${CHURN_DURATION}" -gt 86400 ] ; then CHURN_DURATION=86400 ; fi ; \ | ||
export DURATION="${CHURN_DURATION}" ; \ | ||
export TMPRESULTS="$(Q)$(REPORTDIR)$(D)report$(Q)"; \ | ||
cd $TMPRESULTS ; \ | ||
bash "$(TEST_ROOT)$(D)system$(D)churn$(D)churn$(D)run.sh"; \ | ||
$(TEST_STATUS) | ||
</command> | ||
<levels> | ||
<level>dev</level> | ||
</levels> | ||
<platformRequirementsList> | ||
<platformRequirements>os.linux</platformRequirements> | ||
<platformRequirements>os.win</platformRequirements> | ||
<platformRequirements>os.osx</platformRequirements> | ||
</platformRequirementsList> | ||
<groups> | ||
<group>system</group> | ||
</groups> | ||
</test> | ||
</playlist> |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should add
init
task as dependsdepends="getChurn, init"
unless the non-exist directory will be created when doing the<copy todir="${DEST}">
? Not sure about this looking at the grinder the $DEST was created.