OSB Deployment scripts

OSB Deployment scripts

UPDATE: For deployment scripts …. see my new post http://nitinaggarwal.wordpress.com/2014/04/04/osb-deployment-scripts-11-1-1-7-using-configtool/


There are several OSB posts regarding the OSB Deployment Scripts available on the internet.

For Oracle Service Bus 10.3 & 11g you can use the ANT / WLST deployment scripts provided by Oracle.

I went through the post by Edwin


This is the most straight forward to use and works without making much changes.

It is all self explanatory and you can read the post + the read me file for the details

Very important! Do this on a copy of your workspace or use subversion because maybe you need to delete the .metadata folder for a successful export. ( you will loose all your workspace settings )


Step by step instructions

Ant OSB deployment scripts for OSB PS5 patch set 5

deploy 1 or more OSB project from a OEPE workspace to a jar with the exportFromWorkspace ant target
deploy an OSB to an OSB server with the importToOSB ant target
export a project from an OSB server with a deployment plan with the exportToOSB ant target

A weblogic middleware home
matching OEPE
matching OSB install

How to run

change osb.bat or osb.sh depending on whether you are running on windows or shell with you own settings.

set FMW_HOME=C:OracleOSB11116
set ANT_HOME=%FMW_HOME%modulesorg.apache.ant_1.7.1
set JAVA_HOME=%FMW_HOME%jdk160_29
export FMW_HOME=/opt/oracle/wls/wls11g
export ANT_HOME=/opt/apache/apache-ant-1.8.4
export PATH=$ANT_HOME/bin:$PATH
export JAVA_HOME=/usr/java/jdk1.7.0_07

change the build.properties file with your setting and what you want to deploy

I made the following changes to make it work for My Project

wls.username      = weblogic
wls.password      = welcome1
wls.server        = t3://localhost:7001
# properties for workspace export
#config.project="OSB Configuration"
# export properties
# specify a project or use None
#export.project    = None
#export.customFile = None
export.project    = GenericProxyService
export.jar        = ${basedir}/export/NYS_GP.jar
export.customFile =  ${basedir}/plans/GP_CustomisationFile.xml
# import properties
# specify a project or use None
#import.project    = None
#import.jar        = ${basedir}/export/NYS_ALL.jar
#import.customFile = None
import.project    = None
import.jar        = ${basedir}/export/NYS_ALL.jar
import.customFile = ${basedir}/plans/GP_CustomisationFile.xml

run osb.bat or osb.sh  to set the environment

Then chose which target you need to run out of the following.
ant -f build.xml exportFromWorkspace
ant -f build.xml importToOSB
ant -f build.xml exportToOSB