What's New in the Sun N1 Service Provisioning System 5.2 Update 2 Release

The <compVarList> Element

The new <compVarList> element allows you to supply the values of component variable settings during the <install> step of a plan. The <compVarList> element is a child of the <install> element and is valid only if the <install> element uses a <component> repository targeter. For information about <component> repository targeters, see Repository Component Targeters in Sun N1 Service Provisioning System 5.2 XML Schema Reference Guide.

The purpose of the <compVarList> element is to specify a list of values to be used as overriding component variable settings for the component target when it is installed.

If a <compVarList> element is specified for a targeter component in an install step, you cannot override the component's version either in the Plan Run screen of the browser interface, or when running the plan at the command line, with the pe.p.run command and the -vs argument. This restriction applies in exactly the same way as with dynamic targeting. See Changes to Elements for Variable Substitution in Repository Component Targeters for more information on dynamic targeting.

Each attribute of the <compVarList> element names a variable in the resolved target component. The value of each of these attributes takes precedence when the resolved component is installed. If any of these attributes does not correspond to a variable that has been declared in the target component variable settings, the plan check-in does not succeed.

Any component variables that are not named in the <compVarList> element are given their default value when installed, and if the <compVarList> element is not used, all component variables are given their default values when installed.

All component variables named in the <compVarList> element must be accessible to the <install> step of the plan, and must be declared with access mode PUBLIC or PROTECTED.

Component variables named in the <compVarList> element cannot be declared with access mode FINAL or PRIVATE. If component variables named in the <compVarList> element are declared with access mode FINAL or PRIVATE, an error occurs during plan check-in.

Here is an example of the <compVarList> element, with a single variable, and variable substitution:

<install blockName='default'>
   <component name='foo' path='/tmp'/>
   <compVarList comp1var1='val1' comp1var2=':[localVar]'/>
</install>