Skip to content
Snippets Groups Projects
Commit 0f8dc35c authored by Adriaan Renting's avatar Adriaan Renting
Browse files

Task #9556: Added setting input files in parset

parent 9b95d469
No related branches found
No related tags found
No related merge requests found
......@@ -143,7 +143,7 @@ class RAtoOTDBPropagator():
logger.error(e)
self.doTaskConflict(otdb_id)
def parseStorageProperties(self, storage_claim):
def ParseStorageProperties(self, storage_claim):
"""input something like:
{u'username':u'anonymous', u'status': u'allocated', u'resource_name':
u'cep4storage', u'user_id': -1, u'resource_type_id': 5, u'task_id': 6349,
......@@ -201,7 +201,7 @@ class RAtoOTDBPropagator():
for claim in claims:
logger.debug("Processing claim: %s" % claim)
if claim['resource_type_name'] == 'storage': ## TODO we will need to check for different storage names/types in the future
info['storage'] = parseStorageProperties(claim)
info['storage'] = self.ParseStorageProperties(claim)
info["starttime"] = task["starttime"]
info["endtime"] = task["endtime"]
info["status"] = task["status"]
......
......@@ -182,6 +182,7 @@ class RAtoOTDBTranslator():
return result
def CreateStorageKeys(self, otdb_id, storage_properties, project_name, io_type):
result = {}
if 'nr_of_uv_files' in storage_properties:
result.update(self.CreateCorrelated(otdb_id, storage_properties, project_name, io_type))
if 'nr_of_cs_files' in storage_properties:
......
......@@ -97,7 +97,7 @@ class BaseResourceEstimator(object):
for sap_data_type, sap_data_value in sap['properties'].items():
if sap_data_type in data_properties: # We found this SAP's nr_of_<data_type>_files
output_files[data_type][sap_data_type] = sap_data_value # We only count the nr_of_files from this SAP
output_files['saps'].append({'sap_nr': sap_nr, 'properties': {sap_data_type:sap_data_value}})
output_files['saps'].append({'sap_nr': sap_nr, 'properties': sap['properties']})
if sap_data_type == 'start_sb_nr':
output_files[data_type]['start_sb_nr'] = sap_data_value
return output_files
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment