Integrating with Rational Build Forge

You can use IBM® Rational® Asset Manager and IBM Rational Build Forge® to deliver, track, and govern reliable software builds.

Rational Asset Manager complements existing build applications systems such as Rational Build Forge. You can use Rational Build Forge to create a build based on assets in Rational Asset Manager, and you can also use the integration to publish the build results as new assets in Rational Asset Manager. A set of supplied scripts enables you to download assets, check dependencies, compile, build, and deliver results as new assets.

The process for enabling the integration and using Rational Asset Manager as a definitive software library is as follows:
The image shows a box that represents Rational Asset Manager with smaller boxes that represent an ANT library, compile tools, common components, open source components, and am implementation image within this larger box. There are also three other boxes that represent Rational Build Forge, a build server, and IBM Rational Team Concert. Arrows point from the components within Rational Asset Manager, Rational Team Concert, and Rational Build Forge to the Build server, where the compiling and testing are performed. The result is then published back to Rational Asset Manager from the build server.
  1. Copy the required Rational Asset Manager scripts and their dependent ANT library jar files to the build server.
  2. Download from Rational Asset Manager the required build tools (such as compiler, test tools, and common scripts).
  3. Stage the source from source control.
  4. Fetch dependent artifacts from Rational Asset Manager (such as open source, models, wsdls, xsds, marked as links in the source projects).
  5. Compile and test.
  6. Publish final builds into Rational Asset Manager with dependencies to all the dependent components and required relationships.

In Rational Build Forge, you define a new build project to build and publish assets. The sources for the build are assets and artifacts in Rational Asset Manager and the builds can be published as assets in Rational Asset Manager.

For example, once the required files are set for the build and then, after you run the build and it completes, you can deploy the build results (such as a .ear file) as assets in Rational Asset Manager. Or, after the build results are saved as Rational Asset Manager assets, you can put the new assets and associated artifacts through a review process to ensure that they are approved for deployment (for example, before they published as a Milestone build).

You can mark a Build Type (such as Milestone or Golden Master) in Rational Build Forge to specify the type of review process for the new assets created from the build results. When a Rational Build Forge build completes, the published assets are listed in the build, and in Rational Asset Manager all dependencies are included in the new asset.

Developers can search for assets, artifacts and links to Rational Asset Manager artifacts and add them to their workspace. They can use the Visual Browse utility to see the relationships and dependencies between assets. The download asset script helps automate the delivery of the files to a build process. In Rational Build Forge, after logging in and creating a project, a developer can set the build project properties and complete other required steps to deliver the build results.

For a demonstration of the integration and a sample library and build project, see http://www.ibm.com/support/docview.wss?uid=swg27016509 or http://www.ibm.com/developerworks/offers/lp/demos/summary/r-assetmanagerrbf.html

Setting up the integration

Note: The integration requires Ant version 1.7.x and the current version of the client APIs. The ramclient.zip file is available from the web client Help > Extensions page.
Rational Asset Manager provides the following ANT scripts that you can use in your Rational Build Forge projects:
  • ramDownloadAsset.xml - This script downloads assets in Rational Asset Manager for use in a build project.
  • ramDownloadArtifactLinks.xml - This script downloads related artifacts that are required dependencies for the downloaded assets for use in a build project.
  • ramPublishAsset.xml - This script publishes the build results (such as a .ear file) as new assets in Rational Asset Manager.
You must copy these scripts and their dependent ANT library JAR files from the ramclient.zip file to make the libraries and scripts available on the build server. See Configuring the scripts for the integration. If the tools, libraries, and dependant components are all available as assets in Rational Asset Manager, you can use the supplied ANT scripts to run a build based on these assets. You can also use these scripts with other build utilities and solutions.
After you copy the scripts and configure them for your environment, follow these steps:
  1. Download required tools, such as compiler, test tools, and common scripts.

    Refer to the source code files to the build server by using the appropriate extract command library to extract the source files from the software configuration management (SCM) system, such as Rational ClearCase® or Rational Team Concert™. You must extract source code files from a SCM system for the build to use, such as the download tools including the Rational Asset Manager client library so that the DownloadAsset and other ANT scripts can be used on the Rational Build Forge server. You must provide the SCM system information for the build project, such as the server URL, user ID, and password.

  2. Download the Rational Asset Manager client library from the Rational Asset Manager server and extract it so that the supplied ANT scripts can be used on the build server.
  3. Fetch dependent artifacts, such as open source, models, wsdls, xsds, marked as links in the source projects. If links to required Rational Asset Manager artifacts exist, you can use the DownloadArtifactLinks script to download the required Rational Asset Manager artifacts and specify where to extract them to.

    You can use AppScan® to scan all the source and libraries that are included in the project.

  4. Compile and test.
  5. Publish final builds into Rational Asset Manager with dependencies to all the dependent components and required relationships. You must specify the directory structure for the assets that you will publish and specify other property values in the supplied PublishAsset ANT script.

You can use the sample files to define a new project with a set of libraries and configuration information by importing the contents of the .zip file by importing the eligibility.xml file. The sample files are available at http://www.ibm.com/developerworks/offers/lp/demos/summary/r-assetmanagerrbf.html. Rational Build Forge recreates the eligibility project when you load the eligibility.xml file. Select Libraries and then choose a library, such as GetRamLibraries, to retrieve the ramclient.zip file. Then, modify these files for your configuration. You must also modify the ANT scripts and add them to the Rational Build Forge project.

Running Rational Build Forge projects at specific points of the lifecycle of assets

Rational Asset Manager includes a policy that you can use to run a Rational Build Forge project at specific points in the lifecycle of assets. For example, if a software asset moves from a development state into a staged state in preparation for testing, you might want to run a Rational Build Forge project that automatically builds the software and deploy it for others to see.

This policy is not installed by default, but it is included with the product. To install the policy:
  1. In the web client, click the Help icon and then Extensions.
  2. In the Build Forge Policy section, download the buildforge.zip file. Do not extract the file.
  3. Click Administration.
  4. In the Repository Administration sidebar, click Custom Extensions.
  5. In the Policy Extensions section, click New Policy Extension.
  6. In the New Extension window, in the Class name field, type com.ibm.ram.buildforge.policy.BuildGovernor
  7. In the .jar or .zip file field, click Browse and navigate to the buildforge.zip file that you downloaded. Then, click OK.

For more information about policies and lifecycles, see Policies for lifecycles in Rational Asset Manager, Asset development and lifecycles, and Creating custom lifecycles.


Feedback