Request A Demo
Back to All Blog Articles

Deploying B2B Agreements through FlexDeploy

In this post I am going to highlight some of the possibilities and flexibility of FlexDeploy by showcasing a custom Oracle B2B workflow configured with the Ant Plugin. There are a couple different approaches we can take in configuring this workflow. The first option is to use a source code management tool to maintain versioning as well as provide visibility to existing exported agreements or partners. The second option is to make use of FlexDeploy’s artifact repository feature to maintain versioning. We are going to cover the second approach in this post.

Before we dive in let’s make sure we have our prerequisites completed. We will need a build instance, and development instance defined. An agreement will already need to be setup on your build instance. Lastly you will need to be sure that the ant-b2b-util.xml file exists on the servers where your b2b console resides. This file is part of the default soa installation and is located here: ORACLE_HOME/soa/bin.

Here is a quick look at our B2B environment before we deploy. As you can see there are no trading partners, other than the default MyCompany, and no agreements.

B2BEmpty_10-13-15

Using the approach of FlexDeploy’s artifact repository to maintain the versioning, we will need to create 2 workflows.  Let’s take a look at the first workflow called ExportAgreement.

Step 1: ExportAgreement

B2B-Step1_10-13-15

The purpose of this step is to export the agreement from our build instance.  The build file will be the same throughout this exercise for all Ant steps.  The run target is b2bexport in this step and the arguments include the trading partner agreement we want to export and the filename resulting from the export.

Step 2: SaveAgreement

B2B-Step2_10-13-15

This step saves the exported agreement to FlexDeploy’s artifact repository.  The subfolder should be the file location where you exported the document in the previous step.  The input file filter in this case is FD_PROJECT_NAME.zip.  After this workflow executes the zip export will be archived in FlexDeploy and will be available to deploy to other environments.

The second flow, as you might have guessed, is for deploying the agreement to your target server.  Consistent with the other flow, we can accomplish this in 2 short steps.

Step 1: copyAgreement

B2B-Step3_10-13-15

This step copies the agreement from the FlexDeploy artifact repository, which the previous step had saved.  Input File Filter must match the name we saved in the very first step as part of the ant build parameters.  The directory will be your base FlexDeploy directory and then any subdirectories specified when saving the Agreement.

Step 2: ImportAgreement

B2B-Step4_10-13-15

The final step is the ant script to import the copied agreement from earlier to the target server.  The Ant build file is the same as the export step.  Our run target is b2bimport in this case and our argument is the filename of the copied agreement from the previous step.

Now let’s take a look at what our project looks like in the project tab.

B2B-Step5_10-13-15

In this current configuration we have the project name the same as the agreement name in B2B.  Doing this allows us to make use of the FD_PROJECT_NAME variable when exporting the agreement which is what allows this workflow to be reused for multiple agreements.  Our Build Workflow is set to ExportAgreement and Deploy Workflow is set to DeployAgreement.  The SCM configurations can be ignored as we showcased option 2 which doesn’t use SCM.

Note that this workflow is customized to export and deploy agreements.  When an agreement is deployed to a new environment in this fashion, all dependencies for the agreement are deployed along with it including any relative documents, listening channels, partners etc.  This is really where the benefit of using FlexDeploy comes into play.  Setting up agreements through the B2B UI can be extremely time consuming, especially when setting it up across multiple environments.

 

Lastly, let’s take a quick look at the b2b environment where we deployed the agreement.

B2BFull_10-13-15

 

 

Related Resources

Unlock the Power of DevOps Compliance for Your Enterprise Software

In today’s fast-paced software development environment, ensuring compliance with regulatory standards and policies is not just a necessity—it’s a strategic ...

Integrating Tricentis Tosca (DEX) with FlexDeploy for Test Automation

Tricentis Tosca is a software testing tool that is used to automate end-to-end testing for software applications. Tricentis Tosca combines ...

Integrating ACCELQ with FlexDeploy for Seamless Test Automation

ACCELQ is a cloud-based, continuous testing platform that offers codeless test automation for web, mobile, API, desktop, and packaged applications. ...

Join DevOps leaders across the globe who receive analysis, tips, and trends in their inbox