From f1f5f84f80dc0e4adacbba52901927bfa220713d Mon Sep 17 00:00:00 2001 From: Alan Malta Rodrigues Date: Sat, 21 Dec 2024 08:12:36 -0500 Subject: [PATCH] Consider AAA flags when adding input data to WMBS --- src/python/WMCore/WorkQueue/WMBSHelper.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/python/WMCore/WorkQueue/WMBSHelper.py b/src/python/WMCore/WorkQueue/WMBSHelper.py index 2f17b1696f..37264bd237 100644 --- a/src/python/WMCore/WorkQueue/WMBSHelper.py +++ b/src/python/WMCore/WorkQueue/WMBSHelper.py @@ -451,7 +451,16 @@ def addFiles(self, block): self._addACDCFileToWMBSFile(acdcFile) else: self.isDBS = True - blockPNNs = block['PhEDExNodeNames'] + # Location to be used in WMBS follows the order of: first use Rucio, otherwise use LQE + if block['PhEDExNodeNames']: + # See https://github.com/dmwm/WMCore/blob/d0b6d7d/src/python/WMCore/WorkQueue/WorkQueue.py#L415 + logging.info("Using actual Rucio data locality for data: %s", self.block) + blockPNNs = block['PhEDExNodeNames'] + else: + # See https://github.com/dmwm/WMCore/blob/d0b6d7d/src/python/WMCore/WorkQueue/WorkQueue.py#L454 + # In other words, it could be that data is not available in this list and will be read through AAA + logging.info("Using workqueue element location (including AAA flags) for data: %s", self.block) + blockPNNs = self.commonLocation logging.info('Adding files into WMBS for %s with PNNs: %s', self.wmSpec.name(), blockPNNs) for dbsFile in self.validFiles(block['Files']): self._addDBSFileToWMBSFile(dbsFile, blockPNNs)