Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
convert svn logs into ChangeLog (up to r7858 for now)
[simgrid.git] / examples / platforms / metaxml.xml
1 <!-- This platform shows the use of traces, clusters and sets of hosts defined with the new XML format. It also explains how to define
2       routes between sets of hosts using the route:multi tag
3  -->
4  <?xml version='1.0'?>
5  <!DOCTYPE platform SYSTEM "simgrid.dtd">
6  <platform version="3">
7  <AS  id="AS0"  routing="Full">
8  
9    <!-- define a trace inside the XML file -->
10    <trace id="mytrace" periodicity="12">
11         5 100    <!-- new value at time 5  is 100 -->
12         12 200   <!-- new value at time 12 is 200 -->
13         15 140   <!-- new value at time 15 is 140 -->
14         <!-- value will stay at 140 for 12 more seconds (the periodicity parameter), and go back on top of the trace afterward) -->
15    </trace>
16  
17    <!-- define a cluster for Nancy. Hosts, links, backbone, routes for inter linkage and external linkage are generated by the parser automatically --> 
18    <cluster id="Nancy" prefix="nancy_" radical="0-2" suffix="_host" power="1234566789" bw="125000000" lat="0.00005" bb_bw="50000000" bb_lat="0.001"/>
19  
20    <!-- Now we will define in 5 steps the same thing for cluster Lille but using the tags foreach and route:multi -->
21  
22    <!-- 1. Define Lille set -->
23    <set id="Lille" prefix="lille_" suffix="_host" radical="0-2"/>
24  
25    <!-- 2. Define the Lille group (host+link) -->
26    <foreach set_id="Lille">
27      <host id="$1" power="1234566789"/>
28      <link id="$1" bandwidth="125000000" latency="0.00005"/>
29    </foreach>
30  
31    <!-- 3. Backbones for Lille hosts -->
32    <link id="Lille_bb" bandwidth="50000000" latency="0.00005"/>
33  
34    <!-- Define backbone for communication between Nancy and Lille-->
35    <link id="INTER-bb" bandwidth="125000000" latency="0.000100"/>
36  
37    <!-- 4. Define startpoint for Lille -> $* (All other hosts including Nancy hosts) routes. It is the starting point so it overrides all previosly routes!!! -->
38    <route:multi src="Lille" dst="$*" action="OVERRIDE" symmetric="NO">
39      <link_ctn id="$src"/>
40    </route:multi>
41  
42    <!-- 5. Define Lille intra-cluster communication. Default behaviour POSTPEND links to already existing routes, and NOT symmetric because all routes are created in the first pass.  If you choose symmetric you will duplicate links due to POSTPEND !!!-->
43    <route:multi src="Lille" dst="Lille" symmetric="NO">
44      <link_ctn id="Lille_bb"/>
45    </route:multi>
46  
47    <!-- Add other links to routes. Default behaviour POSTPEND links to already existing routes -->
48    <route:multi src="Nancy" dst="Lille">
49      <link_ctn id="INTER-bb"/>
50      <link_ctn id="$dst"/>
51    </route:multi>
52    
53    <!-- Connect the trace with the host nancy_0_host -->
54    <trace_connect trace="mytrace" kind="POWER" element="nancy_0_host"/>
55  
56  </AS>
57  </platform>