From 205a3d2463f46bfb8616a3ab664927ab87391937 Mon Sep 17 00:00:00 2001 From: Andre Sailer Date: Wed, 29 May 2019 10:34:22 +0200 Subject: [PATCH 1/2] Docs: installTS Tutorial: add options for TaskAgents to update the file and task statuses --- docs/source/AdministratorGuide/Tutorials/installTS.rst | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/source/AdministratorGuide/Tutorials/installTS.rst b/docs/source/AdministratorGuide/Tutorials/installTS.rst index 6fb47865130..a4c27370940 100644 --- a/docs/source/AdministratorGuide/Tutorials/installTS.rst +++ b/docs/source/AdministratorGuide/Tutorials/installTS.rst @@ -29,6 +29,7 @@ More Links ========== * :ref:`adminTS` +* See the options for services and agents in code documentation of the :mod:`~DIRAC.TransformationSystem` Installing the TransformationSystem =================================== @@ -67,11 +68,11 @@ The TS is no different than any other DIRAC system. The installation steps are t Loading configuration template /home/diracuser/DiracInstallation/DIRAC/TransformationSystem/ConfigTemplate.cfg Adding to CS agent Transformation/InputDataAgent agent Transformation_InputDataAgent is installed, runit status: Run - [dirac-tuto]$ install agent Transformation WorkflowTaskAgent -p PollingTime=30 + [dirac-tuto]$ install agent Transformation WorkflowTaskAgent -p PollingTime=30 -p MonitorTasks=True -p MonitorFiles=True Loading configuration template /home/diracuser/DiracInstallation/DIRAC/TransformationSystem/ConfigTemplate.cfg Adding to CS agent Transformation/WorkflowTaskAgent agent Transformation_WorkflowTaskAgent is installed, runit status: Run - [dirac-tuto]$ install agent Transformation RequestTaskAgent -p PollingTime=30 + [dirac-tuto]$ install agent Transformation RequestTaskAgent -p PollingTime=30 -p MonitorTasks=True -p MonitorFiles=True Loading configuration template /home/diracuser/DiracInstallation/DIRAC/TransformationSystem/ConfigTemplate.cfg Adding to CS agent Transformation/RequestTaskAgent agent Transformation_RequestTaskAgent is installed, runit status: Run From c9a299abdd3b41c19216e8ec24c8b76d172cdf79 Mon Sep 17 00:00:00 2001 From: Andre Sailer Date: Wed, 29 May 2019 10:35:07 +0200 Subject: [PATCH 2/2] RequestTaskAgent: add all options to config template --- .../Agent/RequestTaskAgent.py | 49 ++----------------- TransformationSystem/ConfigTemplate.cfg | 45 +++++++++++++++++ 2 files changed, 50 insertions(+), 44 deletions(-) diff --git a/TransformationSystem/Agent/RequestTaskAgent.py b/TransformationSystem/Agent/RequestTaskAgent.py index d6a22c7f706..2ff60d8ad41 100644 --- a/TransformationSystem/Agent/RequestTaskAgent.py +++ b/TransformationSystem/Agent/RequestTaskAgent.py @@ -3,50 +3,11 @@ The following options can be set for the RequestTaskAgent. -:: - - RequestTaskAgent - { - # Use a dedicated proxy to submit requests to the RMS - shifterProxy=DataManager - # Use delegated credentials. Use this instead of the shifterProxy option (New in v6r20p5) - ShifterCredentials= - # Transformation types to be taken into account by the agent - TransType=Replication,Removal - # Location of the transformation plugins - PluginLocation=DIRAC.TransformationSystem.Client.TaskManagerPlugin - # maximum number of threads to use in this agent - maxNumberOfThreads=15 - - # Give this option a value if the agent should submit Requests - SubmitTasks= - # Status of transformations for which to submit Requests - SubmitStatus=Active,Completing - # Number of tasks to submit in one execution cycle per transformation - TasksPerLoop=50 - - # Give this option a value if the agent should monitor tasks - MonitorTasks= - # Status of transformations for which to monitor tasks - UpdateTasksStatus = Active,Completing,Stopped - # Task statuses considered transient that should be monitored for updates - TaskUpdateStatus=Checking,Deleted,Killed,Staging,Stalled,Matched - TaskUpdateStatus+=Scheduled,Rescheduled,Completed,Submitted - TaskUpdateStatus+=Assigned,Received,Waiting,Running - # Number of tasks to be updated in one call - TaskUpdateChunkSize=0 - - # Give this option a value if the agent should monitor files - MonitorFiles= - # Status of transformations for which to monitor Files - UpdateFilesStatus=Active,Completing,Stopped - - # Give this option a value if the agent should check Reserved tasks - CheckReserved= - # Status of transformations for which to check reserved tasks - CheckReservedStatus= Active,Completing,Stopped - - } +.. literalinclude:: ../ConfigTemplate.cfg + :start-after: ##BEGIN RequestTaskAgent + :end-before: ##END + :dedent: 2 + :caption: RequestTaskAgent options * The options *SubmitTasks*, *MonitorTasks*, *MonitorFiles*, and *CheckReserved* need to be assigned any non-empty value to be activated diff --git a/TransformationSystem/ConfigTemplate.cfg b/TransformationSystem/ConfigTemplate.cfg index e1c3cabd8a9..2bb8956060c 100644 --- a/TransformationSystem/ConfigTemplate.cfg +++ b/TransformationSystem/ConfigTemplate.cfg @@ -22,10 +22,55 @@ Agents { PollingTime = 120 } + ##BEGIN RequestTaskAgent RequestTaskAgent { + # Use a dedicated proxy to submit requests to the RMS + shifterProxy = + # Use delegated credentials. Use this instead of the shifterProxy option (New in v6r20p5) + ShifterCredentials = + # Transformation types to be taken into account by the agent. If the option is empty, + # the value is taken from # *Operations/Transformations/DataManipulation* + # with a default of "Replication, Removal" + TransType = + # Location of the transformation plugins + PluginLocation = DIRAC.TransformationSystem.Client.TaskManagerPlugin + # maximum number of threads to use in this agent + maxNumberOfThreads = 15 + + # Give this option a value if the agent should submit Requests + SubmitTasks = yes + # Status of transformations for which to submit Requests + SubmitStatus = Active,Completing + # Number of tasks to submit in one execution cycle per transformation + TasksPerLoop = 50 + + # Give this option a value if the agent should update the status of tasks + MonitorTasks = + # Status of transformations for which to monitor tasks + UpdateTasksStatus = Active,Completing,Stopped + # Task statuses considered transient that should be monitored for updates + TaskUpdateStatus = Checking,Deleted,Killed,Staging,Stalled,Matched + TaskUpdateStatus += Scheduled,Rescheduled,Completed,Submitted + TaskUpdateStatus += Assigned,Received,Waiting,Running + # Number of tasks to be updated in one call + TaskUpdateChunkSize = 0 + + # Give this option a value if the agent should update the status for files + MonitorFiles= + # Status of transformations for which to monitor Files + UpdateFilesStatus = Active,Completing,Stopped + + # Give this option a value if the agent should check Reserved tasks + CheckReserved = + # Status of transformations for which to check reserved tasks + CheckReservedStatus = Active,Completing,Stopped + + #Time between cycles in seconds PollingTime = 120 + } + ##END TransformationAgent { PollingTime = 120