Example #1
0
 def getTreeFromStream(self, stream):
     tree, migrated, errors = gangaObjectFactory(eval(stream))
     if migrated:
        msg = "JobTree was migrated from previous version"
        logger.warning(msg)
     if errors:
         tree = None
         msg = "JobTree can not be recreated because of the errors %s." % str(map(str, errors))
         logger.error(msg)
     return tree
Example #2
0
 def _getJobFromDict(self, attrDict):
     j, migrated, errors = gangaObjectFactory(attrDict)
     if errors:
         j.status = 'incomplete'
         msg = "Job %d can not be completely recreated because of the errors %s It is created in incomplete state." % (j.id, str(map(str, errors)))
         logger.error(msg)
     else:
         if migrated:
             # add job to the MigrationControl list for flushing back to the repository
             from MigrationControl import migrated_jobs
             if j not in migrated_jobs:
                 migrated_jobs.append(j)
     return j
Example #3
0
 def getJobFromStream(self, stream):
     return gangaObjectFactory(pickle.loads(stream))