Changeset 2820

Show
Ignore:
Timestamp:
02/16/2009 10:56:02 AM (9 months ago)
Author:
burt
Message:

First stab at fixing Trac ticket #18

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • gip/trunk/gip/providers/osg_info_timestamp.py

    r2158 r2820  
    66sys.path.append(os.path.expandvars("$GIP_LOCATION/lib/python")) 
    77from gip_common import config, getTemplate, getLogger, printTemplate 
     8from gip_cluster import getSubClusterIDs, getClusterID 
    89 
    910# Retrieve our logger in case of failure 
     
    2223        # To view its contents, see $VDT_LOCATION/gip/templates/GlueCluster 
    2324        template = getTemplate("GlueCluster", "GlueLocationLocalID") 
     25        cluster_id = getClusterID(cp) 
     26        for subClusterId in getSubClusterIDs(cp): 
     27            # Dictionary of data to fill in for GlueLocationLocalID 
     28            info = {'locationId':   'TIMESTAMP', 
     29                    'subClusterId': subClusterId, 
     30                    'clusterId':    cluster_id, 
     31                    'locationName': 'TIMESTAMP', 
     32                    'version':      epoch, 
     33                    'path':         now, 
     34                    } 
    2435 
    25         # Dictionary of data to fill in for GlueLocationLocalID 
    26         info = {'locationId':   'TIMESTAMP', 
    27                 'subClusterId': cp.get('ce', 'name'), 
    28                 'clusterId':    cp.get('ce', 'name'), 
    29                 'locationName': 'TIMESTAMP', 
    30                 'version':      epoch, 
    31                 'path':         now, 
    32                } 
    33  
    34         # Spit out our template, fill it with the appropriate info. 
    35         printTemplate(template, info) 
     36            # Spit out our template, fill it with the appropriate info. 
     37            printTemplate(template, info) 
    3638 
    3739    except Exception, e: