The <site> element is used in LWF files to describe the site the lease workload is meant to be run on. In future versions of Haizea, it will also be used to specify simulated sites from the configuration file.
The <site> has two child elements: <resource-types>, used to specify the valid resource types in the site (separated by spaces), and a <nodes> element specifying the nodes in the site:
<site> <resource-types names="..."/> <nodes> ... </nodes> </site>
The nodes can only have resources specified in <resource-types>. For example, if "CPU Memory" is specified, then the type attribute of the <res> elements in <nodes> can only be CPU or Memory. Note that Haizea doesn't ``understand'' what these types are, and treats them all as consumable capacities, so you can specify any resource types you want. However, Haizea does require that, at the very least, all sites specify at least a CPU and a Memory resource.
The site has eight nodes, all with one CPU and 1024MB of memory. Four of them have four ponies, and the other four have none (if no amount is specified for a resource type, it defaults to zero).
<site> <resource-types names="CPU Memory Ponies"/> <nodes> <node-set numnodes="4"> <res type="CPU" amount="100"/> <res type="Memory" amount="1024"/> <res type="Ponies" amount="4"/> </node-set> <node-set numnodes="4"> <res type="CPU" amount="100"/> <res type="Memory" amount="1024"/> </node-set> </nodes> </site>
Borja Sotomayor 2009-12-17