Here is the ant script to deploy SOA composites in 11g.
<?xml version="1.0" encoding="UTF-8" ?>
<project name="DeployComposite">
<!-- build.properties -->
<property file="build.properties"/>
<property name="deploy.dir" value="${basedir}/deploy"/>
<!-- Add targets here -->
<target name="compile-package">
<property name="sca-inf.classes.dir" value="../SCA-INF/classes"/>
<mkdir dir="${sca-inf.classes.dir}"/>
<ant antfile="${oracle.home}/bin/ant-sca-package.xml" target="package"
inheritall="false">
<property name="oracle.home" value="${oracle.home}"/>
<property name="compositeDir" value="${basedir}"/>
<!-- needed for adf config -->
<property name="scac.application.home" value="${basedir}/.."/>
<!-- name of the composite -->
<property name="compositeName" value="${composite.name}"/>
<!-- revision of the composite -->
<property name="revision" value="${composite.revision}"/>
<!-- java.passed.home passed to scac, this property will be
overwritten to the env.JAVA_HOME if such env variable is defined in OS level-->
<property name="java.passed.home" value="${java.passed.home}"/>
<property name="wl_home" value="${wl.home}"/>
</ant>
</target>
<target name="deploy" depends="compile-package">
<condition property="deploymentplan.name" value="null">
<not>
<isset property="${deploymentplan.name}"/>
</not>
</condition>
<echo>Deploying to http://${managed.server.host}:${managed.server.port}/soa-infra/deployer</echo>
<ant antfile="${oracle.home}/bin/ant-sca-deploy.xml" target="deploy"
inheritall="false">
<property name="user" value="${server.user}"/>
<property name="password" value="${server.password}"/>
<!-- create the url for deployment -->
<property name="serverURL"
value="http://${managed.server.host}:${managed.server.port}/soa-infra/deployer"/>
<!-- location of the sar -->
<property name="sarLocation"
value="${deploy.dir}/sca_${composite.name}_rev${composite.revision}.jar"/>
<!-- force overwrite if already there -->
<property name="overwrite" value="true"/>
<!-- configplan-->
<property name="configplan" value="${deploymentplan.name}"/>
</ant>
</target>
</project>
build.properties file used in this script
# build file for DeployComposite
composite.name=DeployComposite
# revision of the composite
composite.revision=1
# Set oracle.home to <JDEV_HOME>/jdeveloper, where <JDEV_HOME> is JDEV # installation directory
wn.bea.home=C:/oracle/Middleware/jdev_11gR3/
oracle.home=${wn.bea.home}/jdeveloper
java.passed.home=${wn.bea.home}/jdk160_18
wl.home=${wn.bea.home}/wlserver_10.3
# soa-server side oracle home directory - needed for deployment plans
# and the weblogic sca library deployment
soa.server.oracle.home=/product/Oracle/Middleware/Oracle_SOA1
###### Deployment server connection information ###############
# the admin server connection information
admin.server.host=<host>
admin.server.port=7001
# the domain where soa infra is installed
server.domain.name=soa_server1
# connection information for the managed server, used for soa-deployment
managed.server.host=<host>
managed.server.port=8001
# User and credentials for the servers
server.user=<username>
server.password=<password>
# wls server where soa is targeted.
server.targets=soa_server1
0 comments :
Post a Comment