Parameter passing in IBM UrbanCode Deploy

Parameter passing in IBM UrbanCode Deploy

While investigating a customer question I just found something very useful in terms of passing parameters within and between UrbanCode Deploy component processes. Groovy (Windows / Linux platforms) and Powershell (Windows platforms) steps have the ability to set output properties as shown below :

Groovy

Within the Groovy script add a line such as :

outProps.setProperty("ReplicaSet", myReplicaSet)

This will create an output property on the process step called ReplicaSet with a value from the variable myReplicaSet.

Powershell

Within the Powershell script add a line such as :

Set-StepOutputProperty 'IPAddress' $cmdOutput

This will create an output property on the process step called IPAddress with a value from the variable cmdOutput.

Each of the above output properties can be used within subsequent steps within the same component process by addressing the property as either :

${p:<Groovy-step-name>/ReplicaSet} or ${p:<Powershell-step-name>/IPAddress}

Sharing property values with other component processes

If you want to share a property with a step within a different component process (maybe even a different component) then you need to create a new property to hold the value. The step called 'Set Process Request Property' allows you to define a process property and set a value. The value can be cleartext or a secure property depending on your needs. The process step has a field for a process request ID that sets the context for the new property. This will have a default value of ${p:request.id} which will be the ID of the current component process. If you change this process request ID to ${p:parentRequest.id} then you are creating an application process property and not a component process property. Therefore by using ${p:parentRequest.id} you elevate the scope of the property to an application property and any step in any subsequent component process can use the property simply by referencing ${p:<Property-name>}.

If you wan to know more contact Mark Roberts at markroberts@uk.ibm.com

Very helpful tips! Is there a way to pass values from one generic process to the subsequent generic process from within the same application process?

Like
Reply

To view or add a comment, sign in

More articles by Mark Roberts

  • UrbanCode Deploy Plugin for Resource Management

    The UrbanCode Deploy Resource Tree Many IBM UrbanCode Deploy customers create resource tree structures to hold…

  • ASPERA Breakfast Briefing

    IBM Southbank - 29th September, 2015 8:30 am to 10:30 am Do you struggle to transfer high volumes of data between…

Others also viewed

Explore content categories