From 5e799672255a13338f10c4ad2335d407815f9577 Mon Sep 17 00:00:00 2001 From: Andre Sailer Date: Fri, 21 Jun 2024 11:34:31 +0200 Subject: [PATCH] sweep: #7685 better place to document token toggle --- src/DIRAC/Resources/Computing/ComputingElement.py | 6 ++++++ src/DIRAC/WorkloadManagementSystem/Agent/SiteDirector.py | 6 +----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/DIRAC/Resources/Computing/ComputingElement.py b/src/DIRAC/Resources/Computing/ComputingElement.py index 690cdb6b5fb..33455665cc0 100755 --- a/src/DIRAC/Resources/Computing/ComputingElement.py +++ b/src/DIRAC/Resources/Computing/ComputingElement.py @@ -30,6 +30,12 @@ (the submission of a job is blocking the execution until its completion). It deals with one job at a time. - Inner Pool ComputingElement: includes methods to locally interact with Inner ComputingElements asynchronously. It can manage a pool of jobs running simultaneously. + + To configure the use of Tokens for CEs: + + * the CE is able to receive any token. Validation: 'Tag = Token' should be included in the CE parameters. + * the CE is able to receive VO-specifc tokens. Validation: 'Tag = Token:' should be included in the CE parameters. + """ import os diff --git a/src/DIRAC/WorkloadManagementSystem/Agent/SiteDirector.py b/src/DIRAC/WorkloadManagementSystem/Agent/SiteDirector.py index f5fe743bb04..540ff1e6948 100644 --- a/src/DIRAC/WorkloadManagementSystem/Agent/SiteDirector.py +++ b/src/DIRAC/WorkloadManagementSystem/Agent/SiteDirector.py @@ -896,11 +896,7 @@ def __getPilotToken(self, audience: str, scope: list[str] = None): return gTokenManager.getToken(userGroup=pilotGroup, requiredTimeLeft=600, scope=scope, audience=audience) def __supportToken(self, ce: ComputingElement) -> bool: - """Check whether the SiteDirector is able to submit pilots with tokens. - - * the CE is able to receive any token. Validation: Tag = Token should be included in the CE parameters. - * the CE is able to receive VO-specifc tokens. Validation: Tag = Token: should be included in the CE parameters. - """ + """Check whether the SiteDirector is able to submit pilots with tokens.""" return "Token" in ce.ceParameters.get("Tag", []) or f"Token:{self.vo}" in ce.ceParameters.get("Tag", []) def _setCredentials(self, ce: ComputingElement, proxyMinimumRequiredValidity: int):