Changeset 29d5f7c for fedd/fedd_ftopo.py


Ignore:
Timestamp:
Nov 18, 2011 6:43:19 PM (12 years ago)
Author:
Ted Faber <faber@…>
Branches:
compt_changes, info-ops, master
Children:
80b1e82
Parents:
2ac64d1a
Message:

More new Info stuff. Create, terminate, ftopo all work.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/fedd_ftopo.py

    r2ac64d1a r29d5f7c  
    4848    sys.exit("Error processing RPC: %s" % e)
    4949
    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 
    6050if 'experimentdescription' in resp_dict and \
    6151        'topdldescription' in resp_dict['experimentdescription']:
     
    6353            **resp_dict['experimentdescription']['topdldescription'])
    6454    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 ""))
    6758else:
    6859    sys.exit("Badly formatted response (no experiment descrption)!?")
Note: See TracChangeset for help on using the changeset viewer.