Esteban's Blog

/dev/rnd

New Change-Set Editor in Guvnor 5.4

By default, Guvnor provides a unique Change-Set per package containing the package binary or the drl source. The main problem with this is when you want to use just a sub-set of assets of a package (or even from different packages) in your application.
The only solution to this problem was to create the change-sets files in your applications pointing to individual assets in Guvnor using its REST interface. One drawback of this solution is that change-set management is outside the scope of Guvnor, so you don’t have a centralized place to manage them, version them, etc.
was working in a new Change-Set editor where you can define your own change-sets inside Guvnor in any way you want. You can have a combination of different assets and packages, or even different snapshots of a package in a change-set. You can have all the change-sets per package you need, so if different applications are using the same package in different ways (different assets or assets’ versions of a same package) you can make use of this new feature of Guvnor.

This new editor will be available in Guvnor 5.4 

Change-Set Editor UI

To create a new Chang-Set you have to go to “Create New” -> “New Change Set” option in Knowledge Base section of Guvnor.
In the editor you have 4 items you can interact with:

  1. Change-Set Editor canvas: Here you can edit your change-set by hand. You can add, remove or edit resources as you wish. Of course you will need to know the URL of each of the resources. You could get this information from the “Attributes” tab of each of the resources.
  2. Change-Set URL: This is the URL you need to use in your applications to make reference to this change-set.
  3. Package Button: This is an easy way to add packages to your change-set. You need to place the cursor where you want to add a new Package in the  Change-Set Editor canvas and then click this button. A Wizard will appear to help you choose the right package. See next section for further information.
  4. Asset Button: Useful button to add a new Assets to the Change-Set using a Wizard. For more information please read “Adding Assets using a Wizard” section.

Adding Packages using a Wizard

Clicking in the “Package” button of Change-Set Editor, a wizard will be displayed to help you choose the package you want to add as resource.

The Package Wizard has 3 sections:

  1. Name: Each resource inside a Change-Set could have a descriptive name. Use this optional field to set this property.
  2. Description: Each resource inside a Change-Set could have a description. Use this optional field to set this property.
  3. Packages: In this section you can select the package and the Snapshot version of a package you want to add as a resource of the Change-Set you are editing. If the Change-Set you are editing belongs to the Global Area, then you will be able to select the resource to add from all the packages defined in Guvnor and their snapshots of course. If the Change-Set you are editing belongs to a particular Package, you will only see the Snapshots of that package in this Wizard.

Adding Assets using a Wizard

You have 2 ways of adding assets as resources of a Change-Set: by hand using the Change-Set Editor canvas or using the Asset Wizard. This Wizard is invoked using the “Asset” button of the editor.

This Wizard has 5 sections:

  1. Name: Each resource inside a Change-Set could have a descriptive name. Use this optional field to set this property.
  2. Description: Each resource inside a Change-Set could have a description. Use this optional field to set this property.
  3. Package: Use this field to filter the assets of a particular Package. If the Change-Set you are editing belongs to the Global Area, then you will be able to select any package, otherwise the package where your Change-Set belongs is automatically selected and you will not be able to change it.
  4. Format: Use this field to filter the type of assets you are looking for.
  5. Assets: The list of assets that match the selected package and format. You can select one or more assets using the check-box column and then click “OK” to add each resource to the Change-Set you are editing.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Information

This entry was posted on December 27, 2011 by in drools, Guvnor, java, jbpm5, plugtree and tagged , , , .
%d bloggers like this: