We have a lot of developers who are using JDeveloper to develop applications with Oracle SOA Suite, and in this blog I wanted to show them how the combination of JDeveloper along with Oracle Developer Cloud Service can help automate their whole development and delivery lifecycle.
One unique aspect of Developer Cloud Service is that it has an instance of JDeveloper available in the build environment. This allows customers who are building Oracle SOA artifacts to leverage the OJDeploy mechanism to package their applications as part of a continuous integration cycle just like they do during development time.
With the improved DevCS integration that we added in JDeveloper 12.2.1, developers can go beyond integration with the Git server offered by DevCS and can now interact with the DevCS task tracking system directly as well as associate code changes to specific tasks they are working on.
In this 10 minutes video I show:
- Creating Ant based builds for Oracle SOA artifacts
- Automating Continuous Integration build and packaging for Oracle SOA from Developer Cloud Service
- Managing SOA project code with Git and Developer Cloud Service
- Tracking tasks from JDeveloper and monitor agile development in Developer Cloud Service
By the way, for those who rather use Maven to automate their builds - this is totally possible and supported in DevCS as well. There is a set of videos that show you how to do that here.
(If you haven't seen how quick and easy it is to create a DevCS project, create a git repo, track tasks and create agile team boards - see this video and this one too).
Note that developers get access to Developer Cloud Service with every subscription to the Oracle SOA Cloud Service.
Here are the two ant files used in the video:
Note that in the build.properties you'll want to change the application and project names to match the ones you are working on.
As you see in the video the build.xml is generated for you automatically and you just need to add the line:
<propertyenvironment="env"/>
build.properties
oracle.commons=../../../../oracle_common/
oracle.commons=../../../../oracle_common/
install.dir=../../../..
oracle.home=${env.ORACLE_HOME_SOA_12_2_1}
oracle.jdeveloper.workspace.path=${env.WORKSPACE}/e2e-1201-composites.jws
middleware.home=${env.MIDDLEWARE_HOME_SOA_12_2_1}
workspace=${env.WORKSPACE}
oracle.jdeveloper.ant.library=${env.ORACLE_HOME_SOA_12_2_1}/jdev/lib/ant-jdeveloper.jar
oracle.jdeveloper.deploy.dir=${env.WORKSPACE}/ProcessOrder/deploy
oracle.jdeveloper.ojdeploy.path=${oracle.home}/jdev/bin/ojdeploy
javac.nowarn=off
oracle.jdeveloper.project.name=ProcessOrder
oracle.jdeveloper.deploy.outputfile=${env.WORKSPACE}/e2e-1201-composites/ProcessOrder/deploy/${profile.name}
output.dir=classes
javac.deprecation=off
oracle.jdeveloper.deploy.profile.name=*
javac.debug=on
build.xml
<?xml version="1.0" encoding="UTF-8"?>
<!--Ant buildfile generated by Oracle JDeveloper-->
<!--Generated Jul 25, 2016 5:11:09 PM-->
<projectxmlns="antlib:org.apache.tools.ant"name="ProcessOrder"default="all"basedir=".">
<propertyenvironment="env"/>
<propertyfile="build.properties"/>
<pathid="library.SOA.Designtime">
<pathelementlocation="${install.dir}/soa/plugins/jdeveloper/extensions/oracle.sca.modeler.jar"/>
</path>
<pathid="library.SOA.Runtime">
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.fabric_11.1.1/fabric-runtime.jar"/>
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.fabric_11.1.1/tracking-api.jar"/>
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.fabric_11.1.1/tracking-core.jar"/>
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.fabric_11.1.1/edn.jar"/>
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.mgmt_11.1.1/soa-infra-mgmt.jar"/>
<pathelementlocation="${oracle.commons}/modules/com.oracle.webservices.fabric-common-api.jar"/>
</path>
<pathid="library.BPEL.Runtime">
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.bpel_11.1.1/orabpel.jar"/>
</path>
<pathid="library.Mediator.Runtime">
<pathelementlocation="${install.dir}/soa/soa/modules/oracle.soa.mediator_11.1.1/mediator_client.jar"/>
</path>
<pathid="library.MDS.Runtime">
<pathelementlocation="${oracle.commons}/modules/oracle.mds/mdsrt.jar"/>
</path>
<pathid="library.BC4J.Service.Runtime">
<pathelementlocation="${oracle.commons}/modules/oracle.adf.model/adfbcsvc.jar"/>
<pathelementlocation="${oracle.commons}/modules/oracle.adf.model/adfbcsvc-share.jar"/>
<pathelementlocation="${oracle.commons}/modules/commonj.sdo.backward.jar"/>
<pathelementlocation="${oracle.commons}/modules/commonj.sdo.jar"/>
<pathelementlocation="${oracle.commons}/modules/oracle.toplink/eclipselink.jar"/>
<pathelementlocation="${oracle.commons}/modules/com.oracle.webservices.fmw.wsclient-impl.jar"/>
<pathelementlocation="${oracle.commons}/modules/com.oracle.webservices.fmw.jrf-ws-api.jar"/>
<pathelementlocation="${oracle.commons}/modules/com.oracle.webservices.fmw.web-common-schemas-impl.jar"/>
</path>
<pathid="classpath">
<pathrefid="library.SOA.Designtime"/>
<pathrefid="library.SOA.Runtime"/>
<pathrefid="library.BPEL.Runtime"/>
<pathrefid="library.Mediator.Runtime"/>
<pathrefid="library.MDS.Runtime"/>
<pathrefid="library.BC4J.Service.Runtime"/>
</path>
<targetname="init">
<tstamp/>
<mkdirdir="${output.dir}"/>
</target>
<targetname="all"description="Build the project"depends="deploy,compile,copy"/>
<targetname="clean"description="Clean the project">
<deleteincludeemptydirs="true"quiet="true">
<filesetdir="${output.dir}"includes="**/*"/>
</delete>
</target>
<targetname="deploy"description="Deploy JDeveloper profiles"depends="init">
<taskdefname="ojdeploy"classname="oracle.jdeveloper.deploy.ant.OJDeployAntTask"uri="oraclelib:OJDeployAntTask"
classpath="${oracle.jdeveloper.ant.library}"/>
<ora:ojdeployxmlns:ora="oraclelib:OJDeployAntTask"executable="${oracle.jdeveloper.ojdeploy.path}"
ora:buildscript="${oracle.jdeveloper.deploy.dir}/ojdeploy-build.xml"
ora:statuslog="${oracle.jdeveloper.deploy.dir}/ojdeploy-statuslog.xml">
<ora:deploy>
<ora:parametername="workspace"value="${oracle.jdeveloper.workspace.path}"/>
<ora:parametername="project"value="${oracle.jdeveloper.project.name}"/>
<ora:parametername="profile"value="${oracle.jdeveloper.deploy.profile.name}"/>
<ora:parametername="nocompile"value="false"/>
<ora:parametername="outputfile"value="${oracle.jdeveloper.deploy.outputfile}"/>
</ora:deploy>
</ora:ojdeploy>
</target>
<targetname="compile"description="Compile Java source files"depends="init">
<javacdestdir="${output.dir}"classpathref="classpath"debug="${javac.debug}"nowarn="${javac.nowarn}"
deprecation="${javac.deprecation}"encoding="UTF8"source="1.8"target="1.8">
<srcpath="SOA/SCA-INF/src"/>
</javac>
</target>
<targetname="copy"description="Copy files to output directory"depends="init">
<patternsetid="copy.patterns">
<includename="**/*.GIF"/>
<includename="**/*.JPEG"/>
<includename="**/*.JPG"/>
<includename="**/*.PNG"/>
<includename="**/*.cpx"/>
<includename="**/*.dcx"/>
<includename="**/*.ejx"/>
<includename="**/*.gif"/>
<includename="**/*.ini"/>
<includename="**/*.jpeg"/>
<includename="**/*.jpg"/>
<includename="**/*.png"/>
<includename="**/*.properties"/>
<includename="**/*.sva"/>
<includename="**/*.tag"/>
<includename="**/*.tld"/>
<includename="**/*.wsdl"/>
<includename="**/*.xcfg"/>
<includename="**/*.xlf"/>
<includename="**/*.xml"/>
<includename="**/*.xsd"/>
<includename="**/*.xsl"/>
<includename="**/*.exm"/>
<includename="**/*.xml"/>
<excludename="build.xml"/>
</patternset>
<copytodir="${output.dir}">
<filesetdir="SOA/SCA-INF/src">
<patternsetrefid="copy.patterns"/>
</fileset>
<filesetdir=".">
<patternsetrefid="copy.patterns"/>
</fileset>
</copy>
</target>
</project>
![]()