|
66 | 66 | from DIRAC.Resources.Computing.BatchSystems.Condor import HOLD_REASON_SUBCODE, parseCondorStatus, subTemplate |
67 | 67 | from DIRAC.Resources.Computing.ComputingElement import ComputingElement |
68 | 68 | from DIRAC.WorkloadManagementSystem.Client import PilotStatus |
69 | | -from DIRAC.WorkloadManagementSystem.Client.PilotManagerClient import PilotManagerClient |
70 | 69 |
|
71 | 70 | MANDATORY_PARAMETERS = ["Queue"] |
72 | 71 | DEFAULT_WORKINGDIRECTORY = "/opt/dirac/pro/runit/WorkloadManagement/SiteDirectorHT" |
@@ -386,33 +385,10 @@ def killJob(self, jobIDList): |
386 | 385 |
|
387 | 386 | ############################################################################# |
388 | 387 | def getCEStatus(self): |
389 | | - """Method to return information on running and pending jobs. |
390 | | -
|
391 | | - Warning: information currently returned depends on the PilotManager and not HTCondor. |
392 | | - Results might be wrong if pilots or jobs are submitted manually via the CE. |
393 | | - """ |
394 | | - result = S_OK() |
395 | | - result["SubmittedJobs"] = 0 |
396 | | - result["RunningJobs"] = 0 |
397 | | - result["WaitingJobs"] = 0 |
398 | | - |
399 | | - # getWaitingPilots |
400 | | - condDict = {"DestinationSite": self.ceName, "Status": PilotStatus.PILOT_WAITING_STATES} |
401 | | - res = PilotManagerClient().countPilots(condDict) |
402 | | - if res["OK"]: |
403 | | - result["WaitingJobs"] = int(res["Value"]) |
404 | | - else: |
405 | | - self.log.warn(f"Failure getting pilot count for {self.ceName}: {res['Message']} ") |
406 | | - |
407 | | - # getRunningPilots |
408 | | - condDict = {"DestinationSite": self.ceName, "Status": PilotStatus.RUNNING} |
409 | | - res = PilotManagerClient().countPilots(condDict) |
410 | | - if res["OK"]: |
411 | | - result["RunningJobs"] = int(res["Value"]) |
412 | | - else: |
413 | | - self.log.warn(f"Failure getting pilot count for {self.ceName}: {res['Message']} ") |
414 | | - |
415 | | - return result |
| 388 | + """Method to return information on running and pending jobs.""" |
| 389 | + return S_ERROR( |
| 390 | + "getCEStatus() not supported for HTCondorCEComputingElement: HTCondor does not expose this information" |
| 391 | + ) |
416 | 392 |
|
417 | 393 | def getJobStatus(self, jobIDList): |
418 | 394 | """Get the status information for the given list of jobs""" |
|
0 commit comments