| <?xml version="1.0" encoding="ISO-8859-1"?> |
| <!DOCTYPE project [ |
| <!-- |
| |
| Copyright (c) 2017, 2018 Oracle and/or its affiliates. All rights reserved. |
| |
| This program and the accompanying materials are made available under the |
| terms of the Eclipse Public License v. 2.0, which is available at |
| http://www.eclipse.org/legal/epl-2.0. |
| |
| This Source Code may also be made available under the following Secondary |
| Licenses when the conditions for such availability set forth in the |
| Eclipse Public License v. 2.0 are satisfied: GNU General Public License, |
| version 2 with the GNU Classpath Exception, which is available at |
| https://www.gnu.org/software/classpath/license.html. |
| |
| SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 |
| |
| --> |
| |
| <!ENTITY commonBuild SYSTEM "./../../../config/common.xml"> |
| ]> |
| |
| <project name="deployment-ejb31-ejblite-javamodule-App" default="usage" basedir="."> |
| |
| &commonBuild; |
| |
| <property name="testName" value="ejb-ejb31-ejblite-javamodule"/> |
| <property name="archivedir" value="${build}/archives"/> |
| <property name="se.client" value="com.acme.Client"/> |
| <property name="contextroot" value="${testName}"/> |
| |
| |
| <target name="prepare" depends="init"> |
| <mkdir dir="${build}"/> |
| <mkdir dir="${archivedir}"/> |
| <property name="all.war" value="${archivedir}/${testName}-web.war"/> |
| </target> |
| |
| <target name="compile" depends="prepare"> |
| <javac srcdir="war" destdir="${build}" debug="on" failonerror="true"> |
| <classpath refid="gfv3.classpath"/> |
| </javac> |
| <javac srcdir="client" destdir="${build}" debug="on" failonerror="true"> <classpath refid="gfv3.classpath"/> |
| </javac> |
| </target> |
| |
| <target name="assemble" depends="compile"> |
| <war destfile="${all.war}" webxml="descriptor/web.xml"> |
| <classes dir="${build}" excludes="**/Client.class"/> |
| </war> |
| </target> |
| |
| <target name="deploy.asadmin" depends="prepare"> |
| <antcall target="common.deploy.asadmin"> |
| <param name="arg.list" value="--retrieve ${archivedir} --name ${testName}-web --contextroot ${testName} ${all.war}"/> |
| <param name="testName" value="${testName}-web"/> |
| </antcall> |
| </target> |
| |
| |
| <target name="redeploy.asadmin" depends="prepare"> |
| <antcall target="common.redeploy.asadmin"> |
| <param name="arg.list" value="--retrieve ${archivedir} --name ${testName}-web --contextroot ${testName} ${all.war}"/> |
| <param name="testName" value="${testName}-web"/> |
| </antcall> |
| </target> |
| |
| <target name="runclient" depends="prepare,setHttpPort2"> |
| <javaWithResult fork="true" resultproperty="result" |
| failonerror="false" classname="${se.client}"> |
| <classpath> |
| <path refid="gfv3.classpath"/> |
| <path location="${build}"/> |
| </classpath> |
| <arg line="${contextroot}"/> |
| <arg line="${http.host}"/> |
| <arg line="${depltest.port}"/> |
| </javaWithResult> |
| <antcall target="processResult"> |
| <param name="result" value="${result}"/> |
| <param name="log" value="${build}/${log.id}.output.log"/> |
| </antcall> |
| </target> |
| |
| <target name="undeploy.asadmin" depends="prepare"> |
| <antcall target="common.undeploy.asadmin"> |
| <param name="arg.list" value="${testName}-web"/> |
| <param name="testName" value="${testName}-web"/> |
| </antcall> |
| </target> |
| |
| <target name="private-all"> |
| <antcall target="assemble"/> |
| <antcall target="declare-test"> |
| <param name="description" value="ejb31/ejblite/javamodule Test asadmin deploy"/> |
| </antcall> |
| <antcall target="deploy.asadmin"/> |
| <antcall target="runclient"> |
| <param name="log.id" value="1"/> |
| </antcall> |
| <antcall target="declare-test"> |
| <param name="description" value="ejb31/ejblite/javamodule Test asadmin redeploy"/> |
| </antcall> |
| <antcall target="redeploy.asadmin"/> |
| <antcall target="runclient"> |
| <param name="log.id" value="2"/> |
| </antcall> |
| <antcall target="undeploy.asadmin"/> |
| </target> |
| |
| </project> |