本文整理汇总了Python中WMCore.Services.WorkQueue.WorkQueue.WorkQueue.getWorkflowStatusFromWQE方法的典型用法代码示例。如果您正苦于以下问题:Python WorkQueue.getWorkflowStatusFromWQE方法的具体用法?Python WorkQueue.getWorkflowStatusFromWQE怎么用?Python WorkQueue.getWorkflowStatusFromWQE使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类WMCore.Services.WorkQueue.WorkQueue.WorkQueue
的用法示例。
在下文中一共展示了WorkQueue.getWorkflowStatusFromWQE方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: advanceStatus
# 需要导入模块: from WMCore.Services.WorkQueue.WorkQueue import WorkQueue [as 别名]
# 或者: from WMCore.Services.WorkQueue.WorkQueue.WorkQueue import getWorkflowStatusFromWQE [as 别名]
def advanceStatus(self, config):
"""
gather active data statistics
"""
reqDBWriter = RequestDBWriter(config.reqmgrdb_url)
gqService = WorkQueue(config.workqueue_url)
self.logger.info("Getting GQ data for status check")
wfStatusDict = gqService.getWorkflowStatusFromWQE()
self.logger.info("Advancing status")
moveForwardStatus(reqDBWriter, wfStatusDict, self.logger)
moveToArchivedForNoJobs(reqDBWriter, wfStatusDict, self.logger)
return
示例2: advanceStatus
# 需要导入模块: from WMCore.Services.WorkQueue.WorkQueue import WorkQueue [as 别名]
# 或者: from WMCore.Services.WorkQueue.WorkQueue.WorkQueue import getWorkflowStatusFromWQE [as 别名]
def advanceStatus(self, config):
"""
Advance the request status based on the global workqueue elements status
"""
reqmgrSvc = ReqMgr(config.reqmgr2_url, logger=self.logger)
gqService = WorkQueue(config.workqueue_url)
wmstatsSvc = WMStatsServer(config.wmstats_url, logger=self.logger)
self.logger.info("Getting GQ data for status check")
wfStatusDict = gqService.getWorkflowStatusFromWQE()
self.logger.info("Advancing status")
moveForwardStatus(reqmgrSvc, wfStatusDict, self.logger)
moveToCompletedForNoWQJobs(reqmgrSvc, wfStatusDict, self.logger)
moveToArchived(wmstatsSvc, reqmgrSvc, self.logDB, config.archiveDelayHours, self.logger)
self.logger.info("Done advancing status")
return