| <!-- |
| |
| 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 |
| |
| --> |
| |
| <target name="deploy-jbi-component-su" depends="init-common"> |
| <antcall target="deploy-service-assembly"/> |
| <antcall target="start-service-assembly"/> |
| </target> |
| <target name="start-service-assembly" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target= |
| "start-service-assembly"> |
| <property name="jbi.service.assembly.name" value="${jbi-component-su-assembly}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| </ant> |
| </target> |
| <target name="deploy-service-assembly" depends="init-common"> |
| <property name="base-dir" value="."/> |
| <property name="temp" value="${base-dir}/temp" /> |
| <property name="su-dir" value="${base-dir}/${jbi-component-su-dir}"/> |
| <mkdir dir="${temp}"/> |
| <jar basedir="${su-dir}/su" destfile="${temp}/${jbi-component-su}.jar"/> |
| <copy todir="${temp}"> |
| <fileset dir="${su-dir}/assembly"/> |
| </copy> |
| |
| <zip destfile="${assemble.dir}/${jbi-component-su-assembly}.zip" basedir="${temp}"/> |
| <delete dir="${temp}"/> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target= |
| "deploy-service-assembly"> |
| <property name="jbi.deploy.file" value="${assemble.dir}/${jbi-component-su-assembly}.zip"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| </ant> |
| </target> |
| <target name="undeploy-jbi-component-su" depends="init-common"> |
| <antcall target="stop-service-assembly"/> |
| <antcall target="shut-down-service-assembly"/> |
| <antcall target="undeploy-service-assembly"/> |
| </target> |
| |
| <target name="stop-service-assembly" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target= |
| "stop-service-assembly"> |
| <property name="jbi.service.assembly.name" value="${jbi-component-su-assembly}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| </ant> |
| </target> |
| <target name="shut-down-service-assembly" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target= |
| "shut-down-service-assembly"> |
| <property name="jbi.service.assembly.name" value="${jbi-component-su-assembly}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| </ant> |
| </target> |
| <target name="undeploy-service-assembly" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target= |
| "undeploy-service-assembly"> |
| <property name="jbi.service.assembly.name" value="${jbi-component-su-assembly}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| </ant> |
| </target> |
| <target name="stop-binding" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target="stop-component"> |
| <property name="jbi.component.name" value="${jbi.component.name}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| <property name="jbi.task.fail.on.error" value="true"/> |
| </ant> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target="shut-down-component"> |
| <property name="jbi.component.name" value="${jbi.component.name}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| <property name="jbi.task.fail.on.error" value="true"/> |
| </ant> |
| </target> |
| <target name="start-binding" depends="init-common"> |
| <ant dir="${jbi-installation}/bin" antfile="${jbi-installation}/bin/jbi_admin.xml" target="start-component"> |
| <property name="jbi.component.name" value="${jbi.component.name}"/> |
| <property name="jbi.port" value="${jmx.port}"/> |
| <property name="jbi.task.fail.on.error" value="true"/> |
| </ant> |
| </target> |
| |
| <!-- |
| Arguments to this target are- |
| appName - application name |
| wsName - web service name |
| module - ejb-module|web-module|j2ee-application.ejb-module|j2ee-application.web-module |
| flag - true|false |
| --> |
| <target name="set-jbi-enabled" depends="init-common"> |
| <antcall target="asadmin-common"> |
| <param name="admin.command" value="configure-webservice-management"/> |
| <param name="operand.props" value="${appName}#${wsName}"/> |
| </antcall> |
| <echo message="calling asadmin set server.applications.${module}.${appName}.web-service-endpoint.${wsName}.jbi-enabled=${flag}"/> |
| |
| <antcall target="asadmin-common"> |
| <param name="admin.command" value="set"/> |
| <param name="operand.props" value="server.applications.${module}.${appName}.web-service-endpoint.${wsName}.jbi-enabled=${flag}"/> |
| </antcall> |
| </target> |