I am trying to create a templae which will create multiple virtual servers and server farms based on a list of ports.
I created the template and it validates ok but errors when I try to generate an application.
The errors are
Line 6, Col 22: The content of element 'serverfarm' is not complete. One of '{probe, rserver}' is expected.
Line 9, Col 22: The content of element 'serverfarm' is not complete. One of '{probe, rserver}' is expected.
the full template is listed below. Any got any ideas or can point me to the full syntax for templates.
<?xml version="1.0" encoding="UTF-8"?>
<template xmlns:xalan="http://xml.apache.org/xslt" applicationType="Webmethods" version="1.0" xsi:noNamespaceSchemaLocation="file:application_template_v2.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" description="Webmethods Template Multiple ports" showsInGuidedSetup="true">
<input>
<group name="service" type="group" displayString="Application Configuration">
<variable name="name" type="name" displayString="Application Config Name:" perm="ace_vip"/>
<variable name="vip" type="ipaddresswithprefix" displayString="VIP Address:" perm="ace_vip"/>
<array name="reals" displayString="IP Addresses of Real Servers" perm="ace_vip">
<variable name="ipAddr" displayString="" type="ipaddress" perm="ace_vip"/>
</array>
<variable name="sticky" type="boolean" displayString="Session Persistence:" perm="ace_vip"/>
<array name="portList" displayString="List of ports to load balance" perm="ace_vip">
<variable name="lPort" type="port" displayString="Listener Port:" perm="ace_vip"/>
</array>
</group>
<group name="network" type="group" displayString="Network Configuration">
<variable name="device" type="device" displayString="Load Balancer (Device

irtualContext):" perm="ace_vip"/>
<variable name="vlans" type="vlans" displayString="Client VLANs:" perm="ace_vip"/>
<variable name="autoNat" type="boolean" displayString="Enable Source NAT:" perm="ace_vip"/>
</group>
</input>
<config device="{$device}">
<slb>
<foreach iterate="{$portList/$lPort}">
<serverfarm name="{$name}-{$portList/$lPort}" predictor="leastconns">
<probe name="TCP_Probe" type="tcp"/>
<foreach iterate="{$reals/$ipAddr}">
<rserver name="{$reals/$ipAddr}" ipAddr="{$reals/$ipAddr}" port="{$portList/$lPort}"/>
</foreach>
</serverfarm>
<vserver-http name="{$name}-{$portList/$lPort}" vlans="{$vlans}" inService="true" autoNat="{$autoNat}" icmpReply="active">
<vip address="{$vip}" protocol="any"/>
<if test="{$sticky}=true">
<sticky-loadbalance>
<ip-sticky activeConns="true" replication="true" name="{$name}-{$portList/$lPort}-sticky" addressType="source" netmask="255.255.255.255" serverfarm="{$name}-{$portList/$lPort}"/>
</sticky-loadbalance>
</if>
<else>
<loadbalance serverfarm="{$name}-{$portList/$lPort}"/>
</else>
</vserver-http>
</foreach>
</slb>
</config>
</template>