Transformation

A generic client for creating transformations

class DIRAC.TransformationSystem.Client.Transformation.Transformation(transID=0, transClient=None)

Bases: DIRAC.Core.Base.API.API

addFilesToTransformation(lfns, printOutput=False)
addTaskForTransformation(lfns=[], se='Unknown', printOutput=False)
addTransformation(addFiles=True, printOutput=False)
cleanTransformation(printOutput=False)
deleteTasks(taskMin, taskMax, printOutput=False)
deleteTransformation(printOutput=False)
extendTransformation(nTasks, printOutput=False)
getAuthorDNfromProxy()

gets the AuthorDN and username of the transformation from the uploaded proxy

getServer()
getSummaryTransformations(transID=[])

Show the summary for a list of Transformations

Fields starting with ‘F’ (‘J’) refers to files (jobs). Proc. stand for processed.

getTransformation(printOutput=False)
getTransformationFiles(fileStatus=[], lfns=[], outputFields=['FileID', 'LFN', 'Status', 'TaskID', 'TargetSE', 'UsedSE', 'ErrorCount', 'InsertedTime', 'LastUpdate'], orderBy='FileID', printOutput=False)
getTransformationLogging(printOutput=False)
getTransformationStats(printOutput=False)
getTransformationTaskStats(printOutput=False)
getTransformationTasks(taskStatus=[], taskIDs=[], outputFields=['TransformationID', 'TaskID', 'ExternalStatus', 'ExternalID', 'TargetSE', 'CreationTime', 'LastUpdateTime'], orderBy='TaskID', printOutput=False)
getTransformations(transID=[], transStatus=[], outputFields=['TransformationID', 'Status', 'AgentType', 'TransformationName', 'CreationDate'], orderBy='TransformationID', printOutput=False)
getTransformationsByUser(authorDN='', userName='', transID=[], transStatus=[], outputFields=['TransformationID', 'Status', 'AgentType', 'TransformationName', 'CreationDate', 'AuthorDN'], orderBy='TransformationID', printOutput=False)
reset(transID=0)
setBody(body)

check that the body is a string, or using the proper syntax for multiple operations

Parameters:

body (string or list of tuples (or lists) of string and dictionaries) –

transformation body, for example

body = [ ( “ReplicateAndRegister”, { “SourceSE”:”FOO-SRM”, “TargetSE”:”BAR-SRM” }),
         ( “RemoveReplica”, { “TargetSE”:”FOO-SRM” } ),
       ]

Raises:
  • TypeError – If the structure is not as expected
  • ValueError – If unknown attribute for the Operation is used
Returns:

S_OK, S_ERROR

setFileStatusForTransformation(status, lfns, printOutput=False)
setServer(server)
setSourceSE(seList)
setTargetSE(seList)
setTaskStatus(taskID, status, printOutput=False)