def __init__(self, *args, **kwargs): # add the end point to prevent the existence check fails. self['endpoint'] = "phedex_emulator" self.dataBlocks = DataBlockGenerator() self.subRequests = {} self.deletionRequests = {} self.deletionRequestId = 0
def __init__(self, dict=None, responseType="json", logger=None, dbsUrl='https://cmsweb.cern.ch/dbs/prod/global/DBSReader'): print("Using MockPhEDExApi") self.dbsUrl = dbsUrl dict = dict or {} self.dataBlocks = DataBlockGenerator() self.subRequests = {}
def listFiles(self, datasetPath, retriveList): res = [] dbg = DataBlockGenerator() for block in dbg.getBlocks(datasetPath): files = dbg.getFiles(block['Name']) for f in files: f['Block'] = block res.append(f) return res
def __init__(self, url, **contact): self.dataBlocks = DataBlockGenerator() args = { "url" : url, "level" : 'ERROR', "version" : 'DBS_2_0_9'} self.dbs = _MockDBSApi(args)
def __init__(self, dict=None, responseType="json", secure=True): dict = dict or {} self.dataBlocks = DataBlockGenerator() self.subRequests = {}
def __init__(self, acct, hostUrl=None, authUrl=None, configDict=None): print("Using MockRucioApi: acct={}, url={}, authUrl={}".format( acct, hostUrl, authUrl)) configDict = configDict or {} self.dataBlocks = DataBlockGenerator() self.subRequests = {}