Changeset f81aba7 for fedd/federation
- Timestamp:
- Mar 4, 2010 3:17:27 PM (15 years ago)
- Branches:
- axis_example, compt_changes, info-ops, master, version-3.01, version-3.02
- Children:
- 6280b1f
- Parents:
- 632dd59
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fedd/federation/topdl.py
r632dd59 rf81aba7 797 797 slots = e.get_attribute("slots") or "1"; 798 798 startup = e.get_attribute("startup") 799 tarfiles = " ".join([ "%s %s" % (s.install, s.location) \ 800 for s in e.software if s.location and s.install ]) 799 # XXX: unreliable on ProtoGENI 20100303 800 #tarfiles = " ".join([ "%s %s" % (s.install, s.location) \ 801 # for s in e.software if s.location and s.install ]) 801 802 802 803 extras = "" 803 804 if startup: extras += '\t\tstartup_command="%s"\n' % startup 804 if tarfiles: extras +='\t\ttarfiles="%s"\n' % tarfiles805 #if tarfiles: extras +='\t\ttarfiles="%s"\n' % tarfiles 805 806 out += '\t<node virtual_id="%s"\n\t\tvirtualization_type="%s"\n' % \ 806 807 (name, virt_type) … … 817 818 818 819 for i, s in enumerate(t.substrates): 819 out += '\t<link virtual_id="%s" link_type="ethernet">\n' 820 if len(s.interfaces) == 0: 821 continue 822 out += '\t<link virtual_id="%s" link_type="ethernet">\n' % s.name 820 823 if s.capacity and s.capacity.kind == "max": 821 out += '\t\t<bandwidth>%f</bandwidth>\n' % s.capacity.rate 824 bwout = True 825 out += '\t\t<bandwidth>%d</bandwidth>\n' % s.capacity.rate 826 else: 827 bwout = False 822 828 if s.latency and s.latency.kind == "max": 823 out += '\t\t<latency>%f</latency>\n' % s.latency.time 829 out += '\t\t<latency>%d</latency>\n' % s.latency.time 830 elif bwout: 831 out += '\t\t<latency>0</latency>\n' 824 832 for ii in s.interfaces: 825 833 out += ('\t\t<interface_ref virtual_node_id="%s" ' + \
Note: See TracChangeset
for help on using the changeset viewer.