Publish Profile

◷ Reading Time: 10 minutes


Publishing allows you to bundle your logic documents for deployment as a set of files and folders or as a single zip package. Decision Modules are bundles of your business logic that are used to publish a set of logic. A Decision Module contains all of the logic required to support a specific scenario:

  1. Flow
  2. Procedure
  3. Validation
  4. Decision Table
  5. Natural Language
  6. Decision Graph (i.e. Decision Model and Notation, DRD)

To add a new profile to publish,

Document Types --> Utilities --> Publish Profile

Once you add a document, this will be the window.

Publish Profile Properties

When the Profile node is selected in the tree, you can see the following in the Properties window 

  1. Display Title: Each Decision Module may have a display title that can be set using this property.
  2. Name: This is the actual name of the published decision module. This name cannot be changed and is the identifier of the decision to be executed.
  3. Destination: This is the address to which the linked files and areas will be pushed.
  4. Entry Uri: Name of the file that should run first (If there are multiple files, this is the main flow file).
  5. Base: The base folder, which is where your rule project files are located.
  6. Type:
    1. ZipPackage: Create a package zipped in one package file
    2. Directory: Create separate folders inside the given Destination
  7. Inclusions: File types to be added. Add multiple extensions separated by commas ,
  8. Exclusions: File types to be removed from the package. Add multiple extensions separated by commas ,
  9. Version: Package and service versions
  10. Identifier: Package name


The toolbox has the following items.

Top Menu

At the top menu, you can see the following items.

  1. Move down the selected node: Move a node
  2. Move up the selected node: Move a node up
  3. Delete selected node: Delete a node
  4. Show properties of node: Show properties of a node
  5. Expand tree: Show more of a tree node
  6. Collapse tree: Show less of a tree node

Node Properties

If you click on a node, its property window will appear. The properties vary depending on the node type.

Create and Publish a Publish Profile

Create a Publish Profile

To create a tree, drag and drop Area and Files from the Toolbox or Rule Project explorer.

1. Select the command (Area) from the toolbox

2. Drag the Area under the publish node

3. Drop the Area (release your mouse button)

And then you can do the same for “File” and set the “Source” property of the file. Or you can simply drag and drop from your rule project explorer.

1. Select the file from the project explorer

2. Drag it under the appropriate Area node

3. Drop the file (release your mouse button)

When you are linking a logic file (file in your project explorer) using the drag and drop technique, it automatically creates a File node under the Area. You don’t need to add a File from the toolbox first.

Publish Mode

You have the option to deploy the profile as:

  1. Hierarchically nested folder structure
  2. The single decision module file

Check the Type property of your profile to set this behavior.

Adding Assemblies

Assemblies should reside the root of the package when a package is built. Therefore, Name property of assemblies should address 2 levels up.

Assemblies can be added to the publish profile as below.

Create an Area for bin folder and add the assemblies there

Add the Area Name as ..\..\bin to create the bin folder for assemblies.

Also, make sure the assemblies extensions *.dll are added as part of the inclusion list.

Add *.dll as an inclusion of the profile to include the assemblies


Before you publish, you need to validate your package model. This validation identifies issues with your package model. Validating a package model is no different than validating other models in your FlexRule Designer (Click on Validate button ).

Publish a Publish Profile

When you have built the structure of your Decision Module and you are ready to publish it (either to a file/folder structure of a single package file), you need to go to Tools->Publisher and select “Publish a Profile” from the menu as is shown below:

Settings for FlexRule Server

This section explains how the properties of the publish profile maps with the service URL and the FlexRuler Server package properties.

Properties of a sample profile are as follows.

This is the service URL with the above properties.

http://<server address>//api/services/execute/testProfile/2/Profile
  • Name: Service name is Profile
    http://<server address>//api/services/execute/testProfile/2/Profile
  • Destination: This package will be saved in D:\Projects\MyProject
  • Entry Uri: The package execution will start with devidedbyzero.xml file
  • Type: It will create a ZipPackage called Profile.frd
  • Inclusions: This will include XML and DLL files
  • Exclusions: This will not include files with the extension help.xml
  • Version: Package and service version is 2
    http://<server address>//api/services/execute/testProfile/2/Profile
  • Identifier: Package name will be testProfile

Once you create the file, they are reflected on the server as below.

Identifier as Package name, and Version as Version

Name as Service name

Other properties are reflected under service –> Edit

Create a Package Using Command Line

It is possible to execute an existing package profile via the command line. FlexRule Designer accepts some parameters and can build your package from the console command line.

FlexRule.Designer.exe [Project File] 
       -plugin FlexRule.Designer.Deployment.dll 
       -run "build package" 
       -profile [Profile file path]
       -version [Package version]
       -identifier [Package identifier]
       -output [Package location to save]


  • plugin: This parameter must remain as above FlexRule.Designer.Deployment.dll as we are targeting the publisher plugin.
  • run: This parameter is the command that is defined within the plugin. It should remain the same as the above build package
  • profile: Defines a Decision Module file relative to the location of your rule project. If multiple Decision Module needs to be added, multiple profile parameters can be used.
  • includeAssemblies: ensures all the assemblies in the project will be included in the package.
  • version: Defines the package version
  • identifier: Defines the package identifier
  • output: This is the full path to which the package is saved.


The below command creates a package for our sample XBRL project:

FlexRule.Designer.exe "D:\XBRL Rules\XBRL.frpj" -plugin FlexRule.Designer.Deployment.dll -run "build package" -profile "Publish\XBRL Package.xml" -includeAssemblies -version 1 -identifier "XBRL Validation Rules" -output "d:\XBRL Validation Package.frdp"

The package will be stored at d:\XBRL validation package.frdp

Decision Module

A Decision Module is a bundle of logic that is going to be deployed to an environment. That can be for different purpose, such as Testing, Production, and so on.

A Decision Module contains all different set of logic:

1. Flow
2. Validation
3. Decision Table
4. Procedure
5. Decision Requirement Diagram (DRD)
6. Information Requirement diagram (IRD)
7. Glossary
By creating a Decision Module you build a RuleSet in which the address of each individual logic will be relevant to the Area in which it is located.

As the Decision Module represents a RuleSet, it should have an Entry Uri..

Video Tutorial

Sample Project

Download the sample profile using the attachment at the end of the page.

Updated on August 9, 2021

Article Attachments

Was this article helpful?

Related Articles