Vmware VRO (VCO) :How to design workflow [series2]

In this series, will explain about the workflow. We will take one of the predefined workflow in vRo, will try to understand the requirement.

As a system admin,when we have to use VMware vSphere environment, we will login into virtual center instance and manage our environment.In case of vRo, any workflow will be execute on Datacenter,cluster,host or VM , which will be accessed through the Virtual center instance. In that case, SA has to execute Add virtual center instance  first to connect virtual center to Orchestrator.Its a predefined workflow in vRo.

Lets start from : How we login to virtual center, what parameters are require? Here we are trying to create an UML.  The parameters are :User Name,Domain,Port number,Password, and Certificate.  When we provide the following information, its combine all these information, import certificate, validate information, and Connect the VC.

SA inputs->import certificate (if true)->Validate all the information->Connect to Virtual center instance.

So following are our standard inputs: Username,password,port,certificate path,domain.

Standard output: Return value (Whether VC registered or not)

Now lets see the predefined workflow and try to understand, how it is co-related to our standard login.



Lets understand icon used in workflow:


In above workflow the first stuff is scriptable task, which is “combining the host and port”.  When we give in virtual client we provide “host ip:port number” . So for this scriptable task the inputs are: host (ip or name):type string ,port :type number. We need to store the output as well,since it will be used as input in the workflow.

Note: When we need to use the one scriptable task output as input in  next scriptable task in same workflow,we store as attribute.

In this case the attribute hostAndPort:type string (output).

Scripting: hostAndPort = host + “:” + port;

Next stuff in workflow, import certificate. We want to ignore the certificate, its a true/false condition which is Boolean. If ignore is false, we need the url to download, which is our attribute:hostAndPort. In this task we will use hostAndPort attribute as input.

Next stuff is scriptable task “Validate”. As the name says, here we validate all the must input,such as Vcenter enable for vRo,username,password,sdk path,host,port.



if (enabled) {
VcPlugin.validateConnection(host , port , path , userName , password);

enabled=True, then above code will execute.

Note: API search is availble in vRo

VcPlugin: This is object (type scripting class), which used to entry point for vCenter to access the objects from vCenter can be accessed.


In left hand side pane, one which is empty square is properties. The one which has black square are methods of objects.

In above scripting, we are using methods, explored the method:


Its shows what inputs,and return type:void.

If validation fails, it will terminate the Workflow, else it will go to next scriptable task which is “Register the Virtual Center”.

Scripting: newInstance = VcPlugin.registerVCenterServerInstance(enabled, host, port, path,sessionPerUser, userName, password, domain);

In above case also we are using VcPlugin object and the method is registerVCenterServerInstance.Lets explore this method:


By seeing this method, we can make out what are the inputs require, and what output its giving to us. The output return type is VcSDKConnection. So the “new intance” type we need to define is VcSDKConnection.

In this series we got to know about input,output,objects,methods. We will explore more in upcoming series, will try to understand rest of the parameters …