Correct log4j file
[jabaws.git] / build.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2
3 <project default="jabaws" name="Build Java Bioinformatics Analysis Web Services" basedir=".">
4
5         <property name="basedir" location="${basedir}/log" />
6         <property name="LD_LIBRARY_PATH" value="/gridware/sge/lib/lx24-amd64"/>
7
8         <!-- Distributive file names-->
9         <property name="distdir" value="website/archive"/>
10         <mkdir dir="${distdir}" />
11
12         <!-- projects details -->
13         <property name="project.url" value="http://www.compbio.dundee.ac.uk/jabaws"/>
14         <property name="product" value="Java Bioinformatics Analyses Web Services"/>
15         <property name="author" value="Alexander Sherstnev, Peter Troshin"/>
16
17         <!-- dependencies on other compbio projects  -->
18         <property name="compbio-annotation" value="compbio-annotations-1.0.jar"/>
19         <property name="compbio-util" value="compbio-util-1.4.jar"/>
20         <property name="compbio-ga" value="compbio-ga-1.0.jar"/>
21
22         <!-- products -->
23         <property name="jaba_version" value="2.0.1"/>
24         <property name="datamodel" value="${distdir}/datamodel-${jaba_version}.jar"/>
25         <property name="datamodel-src" value="${distdir}/datamodel-src-${jaba_version}.jar"/>
26         <property name="min-jaba-client" value="${distdir}/min-jaba-client-${jaba_version}.jar"/>
27         <property name="jaba-client-src" value="${distdir}/jaba-client-src-${jaba_version}.jar"/>
28
29         <property name="full-jaba-jar" value="${distdir}/full-jabaws.jar"/>
30         <property name="aacon-ws-client" value="${distdir}/aacon-ws-client.jar"/>
31         <property name="full-jaba-client" value="${distdir}/full-jaba-client-${jaba_version}.jar"/>
32         <property name="jaba-source-jar" value="${distdir}/jabaws-src-${jaba_version}.jar"/>
33         <property name="full-jaba-client-pack" value="${distdir}/full-jaba-client-pack.zip"/>
34         <property name="jaba" value="${distdir}/jaba.war"/>
35         <!-- TODO  
36         <property name="jaba-dundee" value="${distdir}/jaba-dundee.war"/>
37          -->
38         <property name="jaba-no-binaries" value="${distdir}/jaba-no-binaries.war"/>
39         <property name="binaries" value="${distdir}/binaries.zip"/>
40         <property name="jaba-devel-web" value="${distdir}/jaba-devel-website.zip"/>
41
42         <!--Whole project archive -->
43         <property name="jaba-project" value="${distdir}/jaba-project.zip"/>
44
45         <!-- java -->
46         <property name="test.src" location="${basedir}/testsrc" />
47         <property name="classes" location="${basedir}/WEB-INF/classes" />
48         <property name="lib.path" location="${basedir}/lib" />
49         <property name="web.lib.path" location="${basedir}/WEB-INF/lib" />
50         <property name="test.lib.path" location="${basedir}/testsrc/lib" />
51         <property name="activity.log" location="${basedir}/activity.log" />
52
53         <!-- add libraries -->
54         <path id="project.classpath">
55                 <fileset dir="${lib.path}">
56                         <include name="*.jar" />
57                 </fileset>
58                 <fileset dir="${web.lib.path}">
59                         <include name="*.jar" />
60                 </fileset>
61         </path>
62
63         <!-- add test classes -->
64         <path id="test.classpath">
65                 <fileset dir="${test.lib.path}">
66                         <include name="*.jar" />
67                 </fileset>
68                 <pathelement location="${classes}" />
69         </path>
70
71         <!--
72         The compilation order is 
73         1. datamodel 
74         2. engine
75         3. runner
76         4. testscr
77         5. webservices
78         Packages of the lower order could not have dependencies on the packages on the next layer. 
79         So runners (layer 3) depends on the engines and the datamodel but engines does not depend on 
80         anything in runners or any other layers above. Testscr is not allowed to test webservices. 
81         -->
82         <target name="compile_with_debug" depends="clean" description="Perform a multiple step compilation to ensure layered structure is preserved. Debug enabled.">
83                 <!-- copy files to class path-->
84                 <copy file="${basedir}/log/log4j.properties" tofile="${classes}/log4j.properties" />
85                 <!-- Complile the datamodel first -->
86                 <javac srcdir="${basedir}/datamodel" destdir="${classes}" target="1.6"
87                                 source="1.6" debug="on" encoding="UTF-8" verbose="false" nowarn="true" >
88                         <compilerarg value="-Xlint:unchecked"/>
89                         <classpath refid="project.classpath" />
90                 </javac>
91                 <!-- Complile the engines -->
92                 <javac srcdir="${basedir}/engine" destdir="${classes}" target="1.6"
93                                 source="1.6" debug="on" encoding="UTF-8" verbose="false" nowarn="true" >
94                         <compilerarg value="-Xlint:unchecked"/>
95                         <classpath refid="project.classpath" />
96                 </javac>
97                 <!-- Complile the runners -->
98                 <javac srcdir="${basedir}/runner" destdir="${classes}" target="1.6"
99                                 source="1.6" debug="on" encoding="UTF-8" verbose="false" nowarn="true" >
100                         <compilerarg value="-Xlint:unchecked"/>
101                         <classpath refid="project.classpath" />
102                 </javac>
103                 <!-- Complile the webservices -->
104                 <javac srcdir="${basedir}/webservices" destdir="${classes}" target="1.6"
105                                 source="1.6" debug="on" encoding="UTF-8" verbose="false" nowarn="true" >
106                         <compilerarg value="-Xlint:unchecked"/>
107                         <classpath refid="project.classpath" />
108                 </javac>
109                 <!-- Complile the tests -->
110                 <javac srcdir="${basedir}/testsrc" destdir="${classes}" target="1.6"
111                                 source="1.6" debug="on" encoding="UTF-8" verbose="false" nowarn="true" >
112                         <compilerarg value="-Xlint:unchecked"/>
113                         <classpath refid="project.classpath" />
114                         <classpath refid="test.classpath" />
115                 </javac>
116         </target>
117
118         <!-- Clean temp directories -->
119         <target name="clean">
120                 <delete dir="${classes}" />
121                 <delete file="${distdir}/binaries.zip" />
122                 <delete file="${basedir}/activity.log" />
123                 <delete file="${basedir}/derby.log" />
124                 <mkdir dir="${classes}" />
125                 <copy file="${basedir}/log/log4j.properties" tofile="${classes}/log4j.properties" />
126         </target>
127
128         <!-- Clean up temp directories and dist directory (all jar, zip, and war files deleted) -->
129         <target name="full-clean" depends="clean">
130                 <delete>
131                         <fileset dir="${distdir}">
132                                 <include name="*.jar"/>
133                                 <include name="*.zip"/>
134                                 <include name="*.war"/>
135                         </fileset>
136                 </delete>
137         </target>
138
139         <target name="clearStatDB" description="Remove all records from statistics database">
140                 <echo>Cleaning Statistics database</echo>
141                 <java classname="compbio.stat.collector.StatDB" fork="false" failonerror="true" classpath="${classes}">
142                 <classpath refid="project.classpath" />
143                 </java>
144         </target>
145
146         <!--
147         Compile with optimisation. Do not compile testsrc 
148         The compilation order is 
149         1. datamodel 
150         2. engine
151         3. runner
152         4. webservices
153         Packages of the lower order could not have dependencies on the packages on the next layer. 
154         So runners (layer 3) depends on the engines and the datamodel but engines does not depend on 
155         anything in runners or any other layers above.  
156         -->
157         <target name="compile" depends="clean" description="Perform a multiple step compilation to ensure layered structure is preserved. Debug disabled, optimisation enabled. Tests are not compiled.">
158                 <!-- copy files to class path-->
159                 <copy file="${basedir}/log/log4j.properties" tofile="${classes}/log4j.properties" />
160                 <!-- Complile the datamodel first -->
161                 <javac srcdir="${basedir}/datamodel" destdir="${classes}" target="1.6" source="1.6" debug="off" optimize="on" encoding="UTF-8" verbose="false" nowarn="true">
162                         <compilerarg value="-Xlint:-unchecked" />
163                         <classpath refid="project.classpath" />
164                 </javac>
165                 <!-- Complile the engines -->
166                 <javac srcdir="${basedir}/engine" destdir="${classes}" target="1.6" source="1.6" debug="off" optimize="on" encoding="UTF-8" verbose="false" nowarn="true">
167                         <compilerarg value="-Xlint:-all" />
168                         <compilerarg value="-Xlint:-unchecked" />
169                         <classpath refid="project.classpath" />
170                 </javac>
171                 <!-- Complile the runners -->
172                 <javac srcdir="${basedir}/runner" destdir="${classes}" target="1.6" source="1.6" debug="off" optimize="on" encoding="UTF-8" verbose="false" nowarn="true">
173                         <compilerarg value="-Xlint:-unchecked" />
174                         <classpath refid="project.classpath" />
175                 </javac>
176                 <!-- Complile the webservices -->
177                 <javac srcdir="${basedir}/webservices" destdir="${classes}" target="1.6" source="1.6" debug="off" optimize="on" encoding="UTF-8" verbose="false" nowarn="true">
178                         <compilerarg value="-Xlint:-unchecked" />
179                         <classpath refid="project.classpath" />
180                 </javac>
181
182         </target>
183
184
185         <target name="datamodel-jar" description="Pack data model classes" depends="compile">
186                 <echo>Jar file: Minimal WS client jar</echo>
187                 <delete file="${basedir}/${datamodel}">
188                 </delete>
189                 <jar jarfile="${basedir}/${datamodel}">
190                         <zipgroupfileset excludes="META-INF/*.SF" dir="${web.lib.path}" >
191                                 <include name="${compbio-util}"/>
192                                 <include name="${compbio-annotation}"/>
193                         </zipgroupfileset>
194                         <fileset dir="${basedir}/WEB-INF/classes/">
195                                 <include name="compbio/data/sequence/*.class"/>
196                                 <include name="compbio/metadata/*.class"/>
197                         </fileset>
198                         <manifest>
199                                 <attribute name="Built-By" value="${author}" />
200                                 <attribute name="Class-Path" value="." />
201                                 <attribute name="Implementation-Title" value="Datamodel for ${product} " />
202                                 <attribute name="Implementation-Vendor" value="${author}" />
203                                 <attribute name="Implementation-URL" value="${project.url}" />
204                         </manifest>
205                 </jar>
206         </target>
207
208         <target name="jaba-client-src-jar" description="Pack metadata, data model, WS interfaces, a simple ws client class" depends="datamodel-source-jar">
209                 <echo>Jar file: JABAWS client source</echo>
210                 <delete file="${jaba-client-src}">
211                 </delete>
212                 <jar jarfile="${jaba-client-src}">
213                         <zipgroupfileset  excludes="META-INF/*.MF" file="${datamodel-src}"/>
214                                 <fileset dir="${basedir}/webservices">
215                                         <!-- This will include JAXWS artifacts. Alternatively they can be generated on the fly. -->
216                                         <include name="compbio/data/msa/**"/>
217                                         <exclude name="compbio/ws/client/ServicesUtil**"/>
218                                         <exclude name="compbio/ws/client/AAConClient**"/>
219                                         <include name="compbio/ws/client/**"/>
220                                 </fileset>
221                                 <manifest>
222                                         <attribute name="Built-By" value="${author}" />
223                                         <attribute name="Implementation-Title" value="${product} Client Source Code" />
224                                         <attribute name="Implementation-Vendor" value="${author}" />
225                                         <attribute name="Implementation-URL" value="${project.url}" />
226                                 </manifest>
227                         </jar>
228         </target>
229         
230         <target name="minimal-jaba-client-jar" description="Pack metadata, data model, WS interfaces, a simple ws client class" depends="compile, datamodel-jar">
231                 <echo>Jar file: Minimal WS client jar</echo>
232                 <delete file="${basedir}/${min-jaba-client}">
233                 </delete>
234                 <jar jarfile="${basedir}/${min-jaba-client}">
235                         <zipgroupfileset excludes="META-INF/*.SF" dir="" includes="${datamodel}" />
236                         <fileset dir="${basedir}/WEB-INF/classes/">
237                                 <!-- This will include JAXWS artifacts. Alternatively they can be generated on the fly. -->
238                                 <include name="compbio/data/msa/**"/>
239                                 <include name="compbio/ws/client/**"/>
240                         </fileset>
241                         <zipgroupfileset  excludes="META-INF/*" dir="" includes="WEB-INF/lib/log4j-1.2.15.jar" />
242                         <manifest>
243                                 <attribute name="Built-By" value="${author}" />
244                                 <attribute name="Main-Class" value="compbio.ws.client.Jws2Client" />
245                                 <attribute name="Class-Path" value="." />
246                                 <attribute name="Implementation-Title" value="Minimal ${product} Client" />
247                                 <attribute name="Implementation-Vendor" value="${author}" />
248                                 <attribute name="Implementation-URL" value="${project.url}" />
249                         </manifest>
250                 </jar>
251         </target>
252
253         <target name="aacon-ws-client-jar" description="Pack metadata, data model, WS interfaces, a simple ws client class" depends="compile, datamodel-jar">
254                 <echo>Jar file: AAConWS client jar</echo>
255                 <delete file="${basedir}/${aacon-ws-client}">
256                 </delete>
257                 <jar jarfile="${basedir}/${aacon-ws-client}">
258                         <zipgroupfileset excludes="META-INF/*.SF" dir="" includes="${datamodel}" />
259                         <fileset dir="${basedir}/WEB-INF/classes/">
260                                 <!-- This will include JAXWS artifacts. Alternatively they can be generated on the fly. -->
261                                 <include name="compbio/data/msa/**"/>
262                                 <include name="compbio/ws/client/**"/>
263                         </fileset>
264                         <manifest>
265                                 <attribute name="Built-By" value="${author}" />
266                                 <attribute name="Main-Class" value="compbio.ws.client.AAConClient" />
267                                 <attribute name="Class-Path" value="." />
268                                 <attribute name="Implementation-Title" value="AACon Client" />
269                                 <attribute name="Implementation-Vendor" value="${author}" />
270                                 <attribute name="Implementation-URL" value="http://www.compbio.dundee.ac.uk/aacon" />
271                         </manifest>
272                 </jar>
273         </target>
274
275         <target name="source-jar" description="Pack java sources" depends="datamodel-source-jar">
276                 <delete file="${basedir}/${jaba-source-jar}">
277                 </delete>
278                 <jar jarfile="${basedir}/${jaba-source-jar}">
279                         <zipgroupfileset  excludes="META-INF/*.MF" file="${datamodel-src}"/>
280                         <fileset dir="${basedir}/runner">
281                                 <include name="**"/>
282                         </fileset>
283                         <fileset dir="${basedir}/engine">
284                                 <include name="**"/>
285                         </fileset>
286                         <fileset dir="${basedir}/webservices/">
287                                 <include name="**"/>
288                         </fileset>
289                         <manifest>
290                                 <attribute name="Built-By" value="${author}" />
291                                 <attribute name="Class-Path" value="." />
292                                 <attribute name="Implementation-Title" value="${product} Source Code Archive" />
293                                 <attribute name="Implementation-Vendor" value="${author}" />
294                                 <attribute name="Implementation-URL" value="${project.url}" />
295                         </manifest>
296                 </jar>
297         </target>
298         
299         <target name="datamodel-source-jar" description="Pack java sources" depends="compile">
300                         <delete file="${datamodel-src}">
301                         </delete>
302                         <jar jarfile="${datamodel-src}">
303                                 <fileset dir="${basedir}/datamodel">
304                                         <include name="**"/>
305                                 </fileset>
306                                 <zipgroupfileset excludes="META-INF/*.MF" dir="${lib.path}/src">
307                                         <include name="**"/>
308                                 </zipgroupfileset>
309                                 <manifest>
310                                         <attribute name="Built-By" value="${author}" />
311                                         <attribute name="Implementation-Title" value="${product} Datamodel Source Code Archive" />
312                                         <attribute name="Implementation-Vendor" value="${author}" />
313                                         <attribute name="Implementation-URL" value="${project.url}" />
314                                 </manifest>
315                         </jar>
316                 </target>
317
318         <fileset dir="${basedir}/WEB-INF/classes/" id="fullclient">
319                 <!-- Datamodel -->
320                 <include name="compbio/data/**"/>
321                 <include name="compbio/metadata/**"/>
322                 <!-- Engines -->
323                 <include name="compbio/engine/**"/>
324                 <!-- Runners -->
325                 <include name="compbio/runner/**"/>
326                 <!-- Logging configuration -->
327         </fileset>
328
329         <target name="full-jaba-client-jar" description="Pack datamodel, engine and runners" depends="compile">
330                 <echo>Jar file: Full WS client jar</echo>
331                 <delete file="${full-jaba-client}">
332                 </delete>
333                 <jar jarfile="${full-jaba-client}">
334                         <zipgroupfileset excludes="META-INF/*.SF" dir="${web.lib.path}" >
335                                 <include name="log4j-1.2.15.jar"/>
336                                 <include name="${compbio-util}"/>
337                                 <include name="${compbio-annotation}"/>
338                                 <include name="drmaa.jar"/>
339                         </zipgroupfileset>
340                         <fileset refid="fullclient"/>
341                         <manifest>
342                                 <attribute name="Built-By" value="${author}" />
343                                 <attribute name="Class-Path" value="." />
344                                 <attribute name="Implementation-Title" value="Full ${product} Client" />
345                                 <attribute name="Implementation-Vendor" value="${author}" />
346                                 <attribute name="Implementation-URL" value="${project.url}" />
347                         </manifest>
348                 </jar>
349         </target>
350
351         <target name="full-jaba-client" description="Pack binaries with sources and configuration files" 
352                         depends="full-jaba-client-jar, pack-binaries">
353                 <echo>Packing binaries, and configuration files</echo>
354                 <zip destfile="${full-jaba-client-pack}" >
355                         <zipgroupfileset file="${binaries}" />
356                         <zipfileset dir="conf" prefix="conf" >
357                                 <exclude name="**/temp/**"/>
358                         </zipfileset>
359                         <fileset file="${full-jaba-client}" />
360                 </zip>
361         </target>
362
363         
364         <target name="full-jaba-jar" description="Pack datamodel, engine, runners, configuration, binaries and webservices" depends="compile">
365                 <echo>Jar file: Full JABAWS jar</echo>
366                 <delete file="${full-jaba-jar}">
367                 </delete>
368                 <jar jarfile="${full-jaba-jar}">
369                         <zipgroupfileset excludes="META-INF/*.SF" dir="${web.lib.path}" >
370                                 <include name="log4j-1.2.15.jar"/>
371                                 <include name="${compbio-util}"/>
372                                 <include name="${compbio-annotation}"/>
373                                 <include name="drmaa.jar"/>
374                         </zipgroupfileset>
375                         <fileset dir="${basedir}/WEB-INF/classes/">
376                                 <include name="compbio/**"/>
377                         </fileset>
378                         <!-- Set WSTester as main to help user to test their deployments -->
379                         <manifest>
380                                 <attribute name="Built-By" value="${author}" />
381                                 <attribute name="Class-Path" value="." />
382                                 <attribute name="Main-Class" value="compbio.ws.client.WSTester" />
383                                 <attribute name="Implementation-Title" value="${product}" />
384                                 <attribute name="Implementation-Vendor" value="${author}" />
385                                 <attribute name="Implementation-URL" value="${project.url}" />
386                         </manifest>
387                 </jar>
388         </target>
389
390         <target name="pack-binaries" description="Zip all binary files">
391                 <delete file="${binaries}" failonerror="false"/>
392                 <zip destfile="${binaries}" >
393                         <zipfileset dir="${basedir}/binaries" prefix="binaries" excludes="**/linux*/**"/>
394                 </zip>
395         </target>
396
397 <!-- DEPRICATED 
398         <target name="pack-windows-binaries" description="Zip only windows binary files">
399                 <delete file="${win-binaries}" failonerror="false" />
400                 <zip destfile="${win-binaries}">
401                         <zipfileset dir="${basedir}/binaries" prefix="binaries" >
402                                 <include name="matrices/*" />
403                                 <include name="windows/*" />
404                         </zipfileset>
405                 </zip>
406         </target>
407 -->
408
409         <target name="jaba-no-binaries" description="Prepare JABAWS war file without native binaries" depends="full-jaba-jar, clearStatDB">
410                 <echo>Preparing a war file without binaries</echo>
411                 <delete file="${jaba-no-binaries}">
412                 </delete>
413                 <zip destfile="${jaba-no-binaries}" whenempty="create">
414                         <zipfileset dir="${basedir}/WEB-INF" prefix="WEB-INF">
415                                 <exclude name="classes"/>
416                                 <!-- These are included into JABA client so exclude the jars -->
417                                 <exclude name="lib/drmaa.jar"/>
418                                 <exclude name="lib/log4j-1.2.15.jar"/>
419                                 <exclude name="lib/${compbio-annotation}"/>
420                                 <exclude name="lib/${compbio-util}"/>
421                                 
422                                 <include name="web.xml"/>
423                                 <include name="sun-jaxws.xml"/>
424                                 <include name="lib/*"/>
425                         </zipfileset>
426                         <zipfileset dir="${basedir}/ExecutionStatistic" prefix="ExecutionStatistic" />
427                         <zipfileset dir="${basedir}/statpages" prefix="statpages" />
428                         <zipfileset dir="${basedir}/jobsout" prefix="jobsout" excludes="**/*"/>
429                         <zipfileset dir="conf" prefix="conf" >
430                                 <exclude name="**/temp/**"/>
431                         </zipfileset>
432                         <!-- Add JABAWS web site apart from the binary archive -->
433                         <zipfileset dir="${basedir}/website" excludes="archive/**, devel*.html, tests/**, template.html"/>
434                         <zipfileset dir="." includes="${full-jaba-client}" fullpath="WEB-INF/lib/jaba-client.jar"/>
435                         <!-- Put a copy of log4j configuration file where it can be used  -->
436                         <zipfileset dir="log" includes="log4j.properties" prefix="WEB-INF/classes"/>
437                 </zip>
438         </target>
439
440         <target name="build-devel-website" description="Pack developement related pages, tests, javadoc" >
441                 <echo>Packing data for internal web site</echo>
442                 <delete file="${jaba-devel-web}">
443                 </delete>
444                 <zip destfile="${jaba-devel-web}" whenempty="create">
445                         <!-- Add JABAWS web site apart from the binary archive -->
446                         <zipfileset dir="${basedir}/website" excludes="template.html, download.html, index.html, manual.html, howto.html, archive/**, prog_docs/**"/>
447                 </zip>
448         </target>
449
450         <target name="jaba-complete" description="Prepare JABAWS war file without runtime dependency - JAXWS jars" depends="jaba-no-binaries, pack-binaries">
451                 <echo>Preparing a complete war file</echo>
452                 <delete file="${jaba}">
453                 </delete>
454                 <copy tofile="${jaba}" file="${jaba-no-binaries}"/>
455                 <zip destfile="${jaba}" update="true" >
456                         <zipgroupfileset file="${binaries}" />
457                 </zip>
458         </target>
459
460 <!--
461 DEPRICATED - STANDARD JABA WAR WILL WORK FOR WINDOWS JUST FINE, DOWNLOAD SPACE SAVING IS NOT WORTH THE ADDITIONAL COMPLEXITY 
462         <target name="jaba-complete-windows" description="Prepare JABAWS war file for windows" depends="jaba-no-binaries">
463                 <echo>Preparing a complete war file</echo>
464                 <copy tofile="${jaba-windows}" file="${jaba-no-binaries}"/>
465                 <zip destfile="${jaba-windows}" update="true" >
466                         <zipgroupfileset file="${win-binaries}" />
467                 </zip>
468         </target>
469 -->
470  
471         <target name="build-all" description="Build-all the distributives"
472                 depends="full-jaba-client, minimal-jaba-client-jar, jaba-no-binaries, jaba-complete, datamodel-jar, datamodel-source-jar, source-jar, jaba-client-src-jar"/>
473
474         <!-- This task does not really depends on compile, but it is better to make sure that the code is sound -->
475         <target name="archive-project" description="Pack everything in the project for those who do not have access to SVN" depends="compile">
476                 <delete file="${jaba-project}">
477                 </delete>
478                 <zip destfile="${jaba-project}" whenempty="create" >
479                         <fileset dir="." excludes="${distdir}/**, jobsout/**, test-output/**, **.svn, dundee-conf/**, TODO.txt, IDEAS.txt, ${activity.log}, **/*.zip, **/*.war"/>
480                         <!-- Add jobsout directory but no content -->
481                         <zipfileset dir="${basedir}/jobsout" prefix="jobsout" excludes="*/**"/>
482                 </zip>
483         </target>
484
485
486         <taskdef name="testNG" classname="org.testng.TestNGAntTask">
487                 <classpath refid="test.classpath">
488                 </classpath>
489         </taskdef>
490
491         <target name="CustomTest" depends="compile_with_debug">
492                 <delete file="${activity.log}"/>
493                 <testNG haltonfailure="true" enableassert="true" >
494                         <jvmarg value="-server" />
495                         <jvmarg value="-enableassertions" />
496                         <jvmarg value="-Xms1024m" />
497                         <jvmarg value="-Xmx1024m" />
498                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
499                         <classpath refid="test.classpath" />
500                         <classpath refid="project.classpath" />
501                         <xmlfileset dir="." includes="temp-testng-customsuite.xml"/>
502                         <sysproperty key="TestingDataPath" value="${data.src}"/>
503                 </testNG>
504         </target>
505
506         <target name="Run_cluster_dependent_test" depends="compile_with_debug">
507                 <delete file="${activity.log}"/>
508                 <testNG groups="cluster" haltonfailure="true" enableassert="true" parallel="false" verbose="3">
509                         <jvmarg value="-server" />
510                         <jvmarg value="-enableassertions" />
511                         <jvmarg value="-Xms1024m" />
512                         <jvmarg value="-Xmx1024m" />
513                         <classfileset dir="${classes}" includes="**/*.class" />
514                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
515                         <classpath refid="test.classpath" />
516                         <classpath refid="project.classpath" />
517                         <sysproperty key="TestingDataPath" value="${data.src}"/>
518                 </testNG>
519         </target>
520
521         <target name="Test" depends="compile_with_debug">
522                 <delete file="${activity.log}"/>
523                 <testNG haltonfailure="true" enableassert="true" verbose="3" excludedgroups="performance, webservices" >
524                         <jvmarg value="-server" />
525                         <jvmarg value="-enableassertions" />
526                         <jvmarg value="-Xms1024m" />
527                         <jvmarg value="-Xmx1024m" />
528                         <classfileset dir="${classes}" includes="**/*.class" />
529                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
530                         <classpath refid="test.classpath" />
531                         <classpath refid="project.classpath" />
532                         <sysproperty key="TestingDataPath" value="${data.src}"/>
533                 </testNG>
534         </target>
535
536         <target name="Performance_tests" depends="compile_with_debug">
537                 <delete file="${activity.log}"/>
538                 <testNG haltonfailure="true" enableassert="true" verbose="3" groups="performance" >
539                         <jvmarg value="-server" />
540                         <jvmarg value="-enableassertions" />
541                         <jvmarg value="-Xms1024m" />
542                         <jvmarg value="-Xmx1024m" />
543                         <classfileset dir="${classes}" includes="**/*.class" />
544                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
545                         <classpath refid="test.classpath" />
546                         <classpath refid="project.classpath" />
547                         <sysproperty key="TestingDataPath" value="${data.src}"/>
548                 </testNG>
549         </target>
550
551         <target name="Test_runners" depends="compile_with_debug">
552                 <delete file="${activity.log}"/>
553                 <testNG groups="runner" haltonfailure="true" verbose="3" enableassert="true" >
554                         <jvmarg value="-server" />
555                         <jvmarg value="-enableassertions" />
556                         <jvmarg value="-Xms1024m" />
557                         <jvmarg value="-Xmx1024m" />
558                         <classfileset dir="${classes}" includes="**/*.class" />
559                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
560                         <classpath refid="test.classpath" />
561                         <classpath refid="project.classpath" />
562                         <sysproperty key="TestingDataPath" value="${data.src}"/>
563                 </testNG>
564         </target>
565
566         <target name="Test_engines" depends="compile_with_debug">
567                 <delete file="${activity.log}"/>
568                 <testNG groups="engine" haltonfailure="true" verbose="3" enableassert="true" >
569                         <jvmarg value="-server" />
570                         <jvmarg value="-enableassertions" />
571                         <jvmarg value="-Xms1024m" />
572                         <jvmarg value="-Xmx1024m" />
573                         <classfileset dir="${classes}" includes="**/*.class" />
574                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
575                         <classpath refid="test.classpath" />
576                         <classpath refid="project.classpath" />
577                         <sysproperty key="TestingDataPath" value="${data.src}"/>
578                 </testNG>
579         </target>
580
581         <target name="All_cluster_independent_windows_only_tests" depends="compile_with_debug">
582                 <delete file="${activity.log}" failonerror="false"/>
583                 <testNG excludedgroups="cluster, non_windows" haltonfailure="true" verbose="3" enableassert="true"  >
584                         <jvmarg value="-server" />
585                         <jvmarg value="-enableassertions" />
586                         <jvmarg value="-Xms1024m" />
587                         <jvmarg value="-Xmx1024m" />
588                         <classfileset dir="${classes}" includes="**/*.class" />
589                         <classpath refid="test.classpath" />
590                         <classpath refid="project.classpath" />
591                         <sysproperty key="TestingDataPath" value="${data.src}"/>
592                 </testNG>
593         </target>
594
595         <target name="All_cluster_independent_tests" depends="compile_with_debug">
596                 <delete file="${activity.log}" failonerror="false"/>
597                 <testNG excludedgroups="cluster, performance" haltonfailure="true" verbose="3" enableassert="true"  >
598                         <jvmarg value="-server" />
599                         <jvmarg value="-enableassertions" />
600                         <jvmarg value="-Xms1024m" />
601                         <jvmarg value="-Xmx1024m" />
602                         <classfileset dir="${classes}" includes="**/*.class" />
603                         <classpath refid="test.classpath" />
604                         <classpath refid="project.classpath" />
605                         <sysproperty key="TestingDataPath" value="${data.src}"/>
606                 </testNG>
607         </target>
608
609         <target name="Rerun_failed_tests" depends="compile_with_debug">
610                 <delete file="${activity.log}" failonerror="false"/>
611                 <testNG haltonfailure="true" enableassert="true" verbose="9" >
612                         <jvmarg value="-server" />
613                         <jvmarg value="-enableassertions" />
614                         <jvmarg value="-Xms1024m" />
615                         <jvmarg value="-Xmx1024m" />
616                         <env key="LD_LIBRARY_PATH" value="${LD_LIBRARY_PATH}"/>
617                         <classpath refid="test.classpath" />
618                         <classpath refid="project.classpath" />
619                         <xmlfileset dir="." includes="test-output/testng-failed.xml"/>
620                         <sysproperty key="TestingDataPath" value="${data.src}"/>
621                 </testNG>
622         </target>
623
624
625 </project>