Sunday, 5 January 2014

BAM deployment to remote server using ant

There is no much information around the BAM deployment . BAM deployment can be done by the following two ways
  1. When you have to do a deployment to BAM all you can use is ICommandTask which needs to run from the same machine as the weblogic server. You can still use it from the remote machine provided you copy the config file from the remote machine to the local one
  2. Using the ICommand.jar file you can create an ant task and deploy it to the server. You needn't copy any files from the remote server all you need is url and credentials to the environment
In this post i would like to explain on the second approach as you can find a lot of oracle doc from the oracle site. This jar was published as a oracle white paper white paper url .
I have done some enhancements to the ant task . The enhancements are
  1. BAM icommand only accepts inline content as it can't read remote files . Copying and pasting all this is a pain so i have automated using ant and reading the file.
  2. Checking the response in the file (is difficult for multiple files) so i have made it available on to the command prompt.
The bam.option is to be set to all if you wish to deploy mutiple files at once else provide the file name in the bam.option. Don't modify the command file name and command file location unless you wish to change the template command file name and location .The properties file should be modified as per the  environment you wish


 
The ant task reads the file to be imported and replaces the predefined config file for export. Since the content requires to be inline for remote deployment.

You can get the complete source on my git hub repository.

No comments:

Post a Comment