In part 1 of this series we created T-Shirt size blueprints in vRA, let’s see now how we can pass on the “Blueprint” price as custom property through custom forms in vRA 7.4 so that it can be visible in the ServiceNow portal.
Step 2: Create a “Custom Property” for Blueprint Price and add it to your Blueprint
In this step we will simply create a blank “Custom Property” and add it to the “Blueprint”.
Later on we will associate a value for this property through Custom Forms logic in vRA. And as it a custom property it can be easily passed on to ServiceNow through OTOB plugin integration.
Edit your Blueprint and a custom property for price.
Step 3: Get the CPU and Memory price for your vRA Reservations/Clusters from vRBC.
Go to Consumption –> Pricing in vRealize for Business portal.
Note down the daily price for vCPU and Memory for your vRA reservations. Unless you have defined custom pricing policies this will be based on the cost drivers you have added for your clusters in vRBC. You can also use custom pricing policies which are more consistent for showback purpose.
Step 4: Calculate the price of your Blueprints based on T-Shirt size configuration and CPU/Memory daily price in vRBC.
In this step we will calculate the price of a Blueprint for each T-Shirt size & storage configuration.
Blueprint Price =CPU Size X vCPU Price + Memory Size X Memory Price + Storage Size X Storage Price
Calculate the price for each T-Shirt size , please note that this will be a daily price and if you want to display the monthly price to your end users you can also do that by converting it accordingly.
Step 5 Add the T-Shirt size and price for each Blueprint using conditional logic in vRA “Custom Forms”
Open your Blueprint canvas and click on “Edit Custom Form”
Drag the following Blueprint elements on your Custom Form. Please note “Image” and “Size” are the properties for T-Shirt size.
If you click on the “Size” Blueprint element you can notice the Values associated with it which we have defined in our T-Shirt sizes.
This is one of the biggest advantage of vRA 7.4 Custom forms that we need not to use complex vRO actions and java scripting to drive any conditional logic in vRA forms, most of these tasks can be achieved in the UI itself.
Now define the Values for your “Blueprint Price” custom property based on the “T-Shirt Size” of the Blueprint . These are the values which we have already calculated in the previous steps.
You can also select CPU element and define its values based on the “Size” of the Blueprint. So that user can see the CPU configuration for a respective T-Shirt size.
Likewise define the values for the Memory based on the size of the Blueprint.
Last step is to activate your custom form
Now if you go and select your T-Shirt Size blueprint for deployment , you can see the corresponding CPU, Memory and Cost values in the vRA Custom form
Step 6: As the Price of Blueprint is recorded as “Custom Property” it will get passed on to ServiceNow portal and will be available to the end user at the time of request.
This is the last step, just make sure that your new T-Shirt size blueprint is synced in ServiceNow and the Blueprint price custom property is not hidden and is available as a read only property in the ServiceNow request form.
Yes finally your ServiceNow users should be able to see the upfront daily/monthly price of the published Cloud Services before deploying or consuming them.