Ignore:
Timestamp:
May 28, 2010 4:02:20 AM (14 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master, version-3.01, version-3.02
Children:
fa4a4a8
Parents:
2f6820c
Message:

Importing is a relatively access semantics free endeavour, but export needs to be in each access controller.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/federation/access.py

    r2f6820c r2c1fd21  
    690690                    "Cannot write client.conf: %s" %s)
    691691
    692     def export_store_info(self, cf, proj, ename, connInfo):
    693         """
    694         For the export requests in the connection info, install the peer names
    695         at the experiment controller via SetValue calls.
    696         """
    697 
    698         for c in connInfo:
    699             for p in [ p for p in c.get('parameter', []) \
    700                     if p.get('type', '') == 'output']:
    701 
    702                 if p.get('name', '') == 'peer':
    703                     k = p.get('key', None)
    704                     surl = p.get('store', None)
    705                     if surl and k and k.index('/') != -1:
    706                         value = "%s.%s.%s%s" % \
    707                                 (k[k.index('/')+1:], ename, proj, self.domain)
    708                         req = { 'name': k, 'value': value }
    709                         self.log.debug("Setting %s to %s on %s" % \
    710                                 (k, value, surl))
    711                         self.call_SetValue(surl, req, cf)
    712                     else:
    713                         self.log.error("Bad export request: %s" % p)
    714                 elif p.get('name', '') == 'ssh_port':
    715                     k = p.get('key', None)
    716                     surl = p.get('store', None)
    717                     if surl and k:
    718                         req = { 'name': k, 'value': self.ssh_port }
    719                         self.log.debug("Setting %s to %s on %s" % \
    720                                 (k, self.ssh_port, surl))
    721                         self.call_SetValue(surl, req, cf)
    722                     else:
    723                         self.log.error("Bad export request: %s" % p)
    724                 else:
    725                     self.log.error("Unknown export parameter: %s" % \
    726                             p.get('name'))
    727                     continue
    728 
    729692    def import_store_info(self, cf, connInfo):
    730693        """
Note: See TracChangeset for help on using the changeset viewer.