Changeset 29d5f7c for fedd/fedd_ftopo.py
- Timestamp:
- Nov 18, 2011 6:43:19 PM (12 years ago)
- Branches:
- compt_changes, info-ops, master
- Children:
- 80b1e82
- Parents:
- 2ac64d1a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fedd/fedd_ftopo.py
r2ac64d1a r29d5f7c 48 48 sys.exit("Error processing RPC: %s" % e) 49 49 50 emap = { }51 if 'embedding' in resp_dict:52 for e in resp_dict['embedding']:53 tn = e.get('toponame', None)54 if tn:55 emap[tn] = ":".join((tn,56 ",".join(e.get('physname', [])),e.get('testbed',"")))57 else:58 sys.exit("No embedding")59 60 50 if 'experimentdescription' in resp_dict and \ 61 51 'topdldescription' in resp_dict['experimentdescription']: … … 63 53 **resp_dict['experimentdescription']['topdldescription']) 64 54 for e in top.elements: 65 if isinstance(e, topdl.Computer) and e.name in emap: 66 print emap[e.name] 55 if isinstance(e, topdl.Computer): 56 print ":".join((e.name, ",".join(e.localname), e.status, 57 ",".join(e.operation), e.get_attribute('testbed') or "")) 67 58 else: 68 59 sys.exit("Badly formatted response (no experiment descrption)!?")
Note: See TracChangeset
for help on using the changeset viewer.