blob: 1d1083e445364b39417a201abd17a3ba9bc8246d [file] [log] [blame]
<project
default="main"
basedir=".">
<!--
Required inputs:
build.home
buildType
buildId
date
time
env.BASEOS
env.BASEWS
env.BASEARCH
buildType.tests [optional]
buildId.tests [optional]
date.tests [optional]
time.tests [optional]
build.stream [optional]
build.committers [optional]
releng.tag [optional]
perf.target [optional]
-->
<!-- Note to be cross-platform, "environment variables" are only appropriate for
some variables, e.g. ones we set, since properties are case sensitive, even if
the environment variables on your operating system are not, e.g. it will
be ${env.Path} not ${env.PATH} on Windows -->
<property environment="env" />
<target name="main">
<property
name="perf.buildId"
value="${buildType}${date}-${time}" />
<property
name="timestamp"
value="${date}${time}" />
<property
name="buildType.tests"
value="${buildType}" />
<property
name="buildId.tests"
value="${buildId}" />
<property
name="date.tests"
value="${date}" />
<property
name="time.tests"
value="${time}" />
<property
name="timestamp.tests"
value="${date.tests}${time.tests}" />
<property
file="${build.home}/${env.RELENG_BUILDER}/build.properties" />
<property
name="local.cache.dir"
value="${env.LOCAL_PREREQS_CACHE}" />
<property
name="workDir"
value="${build.home}/workDir" />
<property
name="perfRoot"
value="${build.home}/perfRoot" />
<delete
dir="${workDir}"
failonerror="false" />
<delete
dir="${perfRoot}"
failonerror="false" />
<mkdir dir="${local.cache.dir}" />
<mkdir dir="${workDir}" />
<mkdir dir="${perfRoot}" />
<antcall target="getReleng" />
<property
file="${perfRoot}/${env.RELENG}/maps/dependencies.properties" />
<antcall target="getDependencies" />
<condition
property="wtp-sdk"
value="wtp-sdk-${buildId}.zip"
else="wtp-sdk-${buildType}-${buildId}-${timestamp}.zip">
<available file="${local.cache.dir}/wtp-sdk-${buildId}.zip" />
</condition>
<condition
property="wtp-wst-tests"
value="wtp-wst-Automated-Tests-${buildId}.zip"
else="wtp-wst-Automated-Tests-${buildType}-${buildId}-${timestamp}.zip">
<available
file="${local.cache.dir}/wtp-wst-Automated-Tests-${buildId}.zip" />
</condition>
<condition
property="wtp-jst-tests"
value="wtp-jst-Automated-Tests-${buildId}.zip"
else="wtp-jst-Automated-Tests-${buildType}-${buildId}-${timestamp}.zip">
<available
file="${local.cache.dir}/wtp-jst-Automated-Tests-${buildId}.zip" />
</condition>
<antcall target="setup" />
<condition property="15x">
<equals
arg1="R1.5"
arg2="${build.stream}" />
</condition>
<antcall target="run_deprecated" />
<antcall target="run" />
</target>
<target name="getReleng">
<property
name="releng.tag"
value="v${buildType}${timestamp}" />
<cvs
cvsRoot=":pserver:anonymous@dev.eclipse.org:/cvsroot/webtools"
package="${env.RELENG}"
dest="${perfRoot}"
command="export"
tag="${releng.tag}"
quiet="${env.CVS_QUIET}"
reallyquiet="${env.CVS_REALLY_QUIET}" />
</target>
<target name="getDependencies">
<property
name="install.destination"
value="${workDir}/" />
<antcall target="getAndInstall">
<param
name="groupId"
value="eclipse" />
<param
name="clean"
value="true" />
</antcall>
</target>
<target name="setup">
<property
file="${build.home}/${env.RELENG_BUILDER}/build.properties" />
<property
file="${perfRoot}/${env.RELENG}/maps/dependencies.properties" />
<property
name="install.destination"
value="${perfRoot}" />
<antcall target="getAndInstall">
<param
name="groupId"
value="eclipse" />
<param
name="clean"
value="true" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="eclipseTestFramework" />
<param
name="clean"
value="true" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="emf" />
<param
name="clean"
value="true" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="gef" />
<param
name="clean"
value="true" />
</antcall>
<condition property="15x">
<equals
arg1="R1.5"
arg2="${build.stream}" />
</condition>
<antcall target="getAndInstallDtp" />
<antcall target="getAndInstall">
<param
name="groupId"
value="tomcat.5" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="tomcat.4" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="jonas.4" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="oagis.release" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="oagis.wsdl" />
</antcall>
<antcall target="getAndInstall">
<param
name="groupId"
value="derby" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-sdk-${buildId}.zip" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-sdk-${buildType}-${buildId}-${timestamp}.zip" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-wst-Automated-Tests-${buildId.tests}.zip" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-wst-Automated-Tests-${buildType.tests}-${buildId.tests}-${timestamp.tests}.zip" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-jst-Automated-Tests-${buildId.tests}.zip" />
</antcall>
<antcall target="getAndInstallWTP">
<param
name="file"
value="wtp-jst-Automated-Tests-${buildType.tests}-${buildId.tests}-${timestamp.tests}.zip" />
</antcall>
<antcall target="setup.derby" />
<copy
file="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/performance-tests.xml"
tofile="${perfRoot}/performance-tests.xml">
</copy>
<!-- get path to equinox jar inside ${eclipse.home} folder (copy/rename actual jar) -->
<copy todir="${workDir}/eclipse">
<fileset dir="${workDir}/eclipse/plugins">
<include name="org.eclipse.equinox.launcher_*.jar" />
</fileset>
</copy>
</target>
<target
name="getAndInstallDtp"
unless="15x">
<antcall target="getAndInstall">
<param
name="groupId"
value="dtp" />
<param
name="clean"
value="true" />
</antcall>
</target>
<target name="getAndInstall">
<property
name="dependencyTargets"
value="${build.home}/${env.RELENG_BUILDER}/scripts/dependency/build.xml" />
<ant
antfile="${dependencyTargets}"
target="checkDependency">
<property
name="groupId"
value="${groupId}" />
</ant>
<ant
antfile="${dependencyTargets}"
target="installDependency">
<property
name="groupId"
value="${groupId}" />
</ant>
</target>
<target name="getAndInstallWTP">
<available
file="${local.cache.dir}/${file}"
property="file.exists" />
<antcall target="getWTP" />
<available
file="${local.cache.dir}/${file}"
property="file.exists" />
<antcall target="installWTP" />
</target>
<target name="getWTP">
<condition
property="file.url.1"
value="http://download.eclipse.org/webtools/committers"
else="http://download.eclipse.org/webtools/downloads">
<isset property="build.committers" />
</condition>
<condition
property="file.url"
value="${file.url.1}/drops/${build.stream}/${buildType}-${buildId}-${timestamp}"
else="${file.url.1}/drops/${buildType}-${buildId}-${timestamp}">
<isset property="build.stream" />
</condition>
<antcall target="getWTP2" />
</target>
<target
name="getWTP2"
unless="file.exists">
<property
name="file.url"
value="http://download.eclipse.org/webtools/downloads/drops/${build.stream}/${buildType}-${buildId}-${timestamp}" />
<get
dest="${local.cache.dir}/${file}"
src="${file.url}/${file}"
ignoreerrors="true" />
</target>
<target
name="installWTP"
if="file.exists">
<unzip
src="${local.cache.dir}/${file}"
dest="${install.destination}"
overwrite="true" />
</target>
<target name="setup.derby">
<property
name="derby"
value="${install.destination}/eclipse/plugins/org.apache.derby" />
<mkdir dir="${derby}" />
<copy
todir="${derby}"
overwrite="true">
<fileset
dir="${perfRoot}/incubating-derby-10.0.2.1-bin/lib">
<include name="**/*.jar" />
</fileset>
</copy>
<copy
tofile="${derby}/plugin.xml"
file="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/derby.plugin.xml.template"
overwrite="true" />
<replace
dir="${perfRoot}/eclipse/plugins"
value="&lt;import plugin=&quot;org.apache.derby&quot;/&gt;">
<include name="org.eclipse.test.performance_*/plugin.xml" />
<replacetoken>
<![CDATA[<import plugin="org.apache.derby" optional="true"/>]]></replacetoken>
</replace>
</target>
<target
name="run"
unless="15x">
<property
name="perf.target"
value="main" />
<mkdir dir="${perfRoot}/results/consolelogs" />
<java
fork="true"
failonerror="true"
timeout="230400000"
output="${perfRoot}/results/consolelogs/wtpperflog.txt"
dir="${workDir}"
classname="org.eclipse.equinox.launcher.Main">
<classpath>
<fileset dir="${workDir}/eclipse/plugins">
<include name="org.eclipse.equinox.launcher_*.jar" />
</fileset>
</classpath>
<jvmarg value="-Dosgi.ws=${env.BASEWS}" />
<jvmarg value="-Dosgi.os=${env.BASEOS}" />
<jvmarg value="-Dosgi.arch=${env.BASEARCH}" />
<jvmarg value="-Dnoclean=true" />
<jvmarg value="-DbuildType=${buildType}" />
<jvmarg value="-DbuildId=${buildId}" />
<jvmarg value="-Dtimestamp=${timestamp}" />
<jvmarg value="-DbuildType.tests=${buildType.tests}" />
<jvmarg value="-DbuildId.tests=${buildId.tests}" />
<jvmarg value="-Dtimestamp.tests=${timestamp.tests}" />
<jvmarg value="-Djava.io.tmpdir=${env.RECOMMENDED_TMP_DIR}" />
<arg value="-propertyfile" />
<arg
value="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/perf.properties" />
<arg value="-application" />
<arg value="org.eclipse.ant.core.antRunner" />
<arg value="-file" />
<arg
value="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/perf.xml" />
<arg value="-logger" />
<arg value="org.apache.tools.ant.DefaultLogger" />
<arg value="${perf.target}" />
<sysproperty
key="eclipse-home"
value="${perfRoot}/eclipse" />
<sysproperty
key="perf.buildId"
value="${perf.buildId}" />
<sysproperty
key="build.home"
value="${build.home}" />
<sysproperty
key="local.cache.dir"
value="${local.cache.dir}" />
<sysproperty
key="perfRoot"
value="${perfRoot}" />
<sysproperty
key="testDir"
value="${perfRoot}" />
</java>
</target>
<target
name="run_deprecated"
if="15x">
<property
name="perf.target"
value="main" />
<mkdir dir="${perfRoot}/results/consolelogs" />
<java
fork="true"
failonerror="true"
timeout="230400000"
output="${perfRoot}/results/consolelogs/wtpperflog.txt"
dir="${workDir}"
classname="org.eclipse.core.launcher.Main">
<classpath>
<fileset dir="${workDir}/eclipse">
<include name="startup.jar" />
</fileset>
</classpath>
<jvmarg value="-Dosgi.ws=${env.BASEWS}" />
<jvmarg value="-Dosgi.os=${env.BASEOS}" />
<jvmarg value="-Dosgi.arch=${env.BASEARCH}" />
<jvmarg value="-Dnoclean=true" />
<jvmarg value="-DbuildType=${buildType}" />
<jvmarg value="-DbuildId=${buildId}" />
<jvmarg value="-Dtimestamp=${timestamp}" />
<jvmarg value="-DbuildType.tests=${buildType.tests}" />
<jvmarg value="-DbuildId.tests=${buildId.tests}" />
<jvmarg value="-Dtimestamp.tests=${timestamp.tests}" />
<arg value="-propertyfile" />
<arg
value="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/perf.properties" />
<arg value="-application" />
<arg value="org.eclipse.ant.core.antRunner" />
<arg value="-file" />
<arg
value="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/perf.xml" />
<arg value="-logger" />
<arg value="org.apache.tools.ant.DefaultLogger" />
<arg value="${perf.target}" />
<sysproperty
key="eclipse-home"
value="${perfRoot}/eclipse" />
<sysproperty
key="perf.buildId"
value="${perf.buildId}" />
<sysproperty
key="build.home"
value="${build.home}" />
<sysproperty
key="local.cache.dir"
value="${local.cache.dir}" />
<sysproperty
key="perfRoot"
value="${perfRoot}" />
<sysproperty
key="testDir"
value="${perfRoot}" />
</java>
</target>
<target name="graph">
<property
name="perf.buildId"
value="${buildType}${date}-${time}" />
<property
name="perfRoot"
value="${build.home}/perfRoot" />
<cvs
cvsRoot=":pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse"
package="org.eclipse.releng.basebuilder"
dest="${perfRoot}"
command="export"
tag="RC4_33" />
<property
file="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/perf.properties" />
<antcall target="setup.derby">
<param
name="derby"
value="${perfRoot}/org.eclipse.releng.basebuilder/plugins/org.apache.derby" />
</antcall>
<mkdir dir="${perfRoot}/results/graph" />
<java
fork="true"
failonerror="true"
timeout="28800000"
dir="${perfRoot}"
classname="org.eclipse.equinox.launcher.Main">
<classpath>
<fileset
dir="${perfRoot}/org.eclipse.releng.basebuilder/plugins">
<include name="org.eclipse.equinox.launcher*.jar" />
</fileset>
</classpath>
<jvmarg value="-Dosgi.ws=${env.BASEWS}" />
<jvmarg value="-Dosgi.os=${env.BASEOS}" />
<jvmarg value="-Dosgi.arch=${env.BASEARCH}" />
<jvmarg
value="-Declipse.perf.dbloc=${build.home}/${perf.dbloc}" />
<arg value="-application" />
<arg
value="org.eclipse.test.performance.ui.resultGenerator" />
<arg value="-baseline" />
<arg value="${perf.ref.buildId}" />
<arg value="-baseline.prefix" />
<arg value="${perf.ref.config}" />
<arg value="-current" />
<arg value="${perf.buildId}" />
<arg value="-current.prefix" />
<arg value="${perf.config}" />
<arg value="-jvm" />
<arg value="${perf.jvm}" />
<arg value="-config" />
<arg value="${perf.config}" />
<arg value="-output" />
<arg value="${perfRoot}/results/graph" />
</java>
<copy
file="${build.home}/${env.RELENG_BUILDER}/distribution/wtp.perf/performance.php"
tofile="${perfRoot}/results/graph/performance.php" />
</target>
<target
name="upload"
if="login">
<mkdir dir="${build.home}/archives" />
<zip
destfile="${build.home}/archives/${buildType}-${buildId}-${date}${time}.zip"
basedir="${build.home}/perfRoot/results" />
<condition
property="upload.path.1"
else="~/downloads/webtools/downloads"
value="~/downloads/webtools/committers">
<isset property="build.committers" />
</condition>
<condition
property="upload.path"
else="${upload.path.1}/drops/${buildType}-${buildId}-${date}${time}/perfresults"
value="${upload.path.1}/drops/${build.stream}/${buildType}-${buildId}-${date}${time}/perfresults">
<isset property="build.stream" />
</condition>
<exec
executable="ssh"
dir="${build.home}">
<arg
line="${login}@download1.eclipse.org rm -rf ${upload.path}" />
</exec>
<exec
executable="ssh"
dir="${build.home}">
<arg
line="${login}@download1.eclipse.org mkdir ${upload.path}" />
</exec>
<exec
executable="scp"
dir="${build.home}">
<arg
line="-r ./perfRoot/results/consolelogs ${login}@download1.eclipse.org:${upload.path}" />
</exec>
<exec
executable="scp"
dir="${build.home}">
<arg
line="-r ./perfRoot/results/html ${login}@download1.eclipse.org:${upload.path}" />
</exec>
<exec
executable="scp"
dir="${build.home}">
<arg
line="-r ./perfRoot/results/xml ${login}@download1.eclipse.org:${upload.path}" />
</exec>
<exec
executable="scp"
dir="${build.home}">
<arg
line="-r ./perfRoot/results/graph ${login}@download1.eclipse.org:${upload.path}" />
</exec>
</target>
<target
name="clean"
if="clean">
<property
file="${build.home}/${env.RELENG_BUILDER}/build.properties" />
<property
name="local.cache.dir"
value="${env.LOCAL_PREREQS_CACHE}" />
<property
name="workDir"
value="${build.home}/workDir" />
<property
name="perfRoot"
value="${build.home}/perfRoot" />
<delete
dir="${workDir}"
failonerror="false" />
<delete
dir="${perfRoot}"
failonerror="false" />
<delete failonerror="false">
<fileset
dir="${local.cache.dir}"
includes="wtp-*" />
</delete>
</target>
</project>