LittleCMDB (An Orchestrator and WaveMaker project) – Part 2

Table of Content

In Part1 we start with the SQL DB Plugin and create the required database for our need.

In Part2 we start with the development of our Workflow. We will start with a few elements.

In Part3 we  finish the  collection of the VM information.

In Part4 we insert our data into the database and test our created workflow

In Part5 we create our webview to get a look on our Data in the SQL Database

In Part6 we will make our Workflow smarter to update the DB with actual VM information

In Part7 problems with vAPP located virtual machines are fixed


Here we go with Part2 of the “Little CMDB” Project. Enjoy the Post 😉

After the SQL Database is ready, it is time to start with the Workflow development. As first task, let’s start and create a new workflow. I will name my as GetVMConfig.

Insert a good description for the Workflow, change the Version Number and then lets go to the schema tab.

 The first thing we need, is a action element to get a list of all virtual machines. Just drag the action element into the window.


Just insert „getAll“ into the filter field. As second step choose the “getAllVMs” Workflow.

After we have insert the workflow we change to the „General“ Tab and drag a „Scriptable Task“ and a „Custom Decision“ into the Schema

Now we insert a name for the „Scriptable task“, I choose CalculateVMNumber and a Description.

After that, we are changing the name the of the “Decision” to “NumberofVMs” and insert a description.


After we have complete this naming and description for the workflows, we have to create some Variables.

There are two ways to create the variables. The first one is, to drag and drop from the workflows and actions over the Visual Binding tab. The second is to create the variables on the general tab. I will use the first choice.

For all other, here is a sheet with the required variables and there value to create them on the General tab:

Local Parameter Variable Name Module Direction Type
actionResult allVMs GetAllVMs out Array/VC:VirtualMachine
allVMs allVMs CalculateVMNumber in Array/VC:VirtualMachine
NumberVMs NumberVMs CalculateVMNumber out Number
NumberVMs NumberVMs NumberofVMs in Number

Lets start with the “getAllVMs” Action

I recommend to give a variables a “speaking” name and a description

When your are finished, your “Out” tab must look like this:

The next thing we have to configure, is the “CalculateVMNumber”. Here we have to insert the “allVMs” variable over the “IN” Tab

You can insert the Variable over the “Plus” symbol.

At the moment we have only one possible value so we choose the “allVMs”.

Next we go to the “Out” tab. Here we have to export the “NumberVMs” Variable. You can insert the variable over the “Plus” Sign. If you don’t have created the Variable jet, you can do so over the link above.

After we have created the variable (don’t forget we need a “number” as type 😉 ) we go to the script tab.

Here we do our first scripting. We wont to get the length of the array. We can to that with this small script:

NumberVMs = allVMs.length;

You don’t have to literally type the variables. The bound variables for the Workflow are shown on top of the “Scripting” tab. You can simple click on them and there are used in the scripting field.

At last (for the moment) we go to the “NumberofVMs” Decision. There we insert the “NumberVMs” Variable on the in field and insert this script in the scripting tab.

Now, we have to connect the different modules. We can use the connector by clicking on the “connector symbol” and drag-and-drop between the different modules.

After you are finished, just click on the “Validate” button and lets see if we have any error in our workflow.

At the moment we have two errors, which are logical (we don’t have finished our CMDB jet…).

Save the Workflow and then we will in Part3 we will go one with our LittleCMDB so stay tuned 😉

De Vcoportal Part2
De Vcoportal Part2
110.7 KiB