def __init__(self, channel, stage='raw'): self.channel = channel CBaseStore.__init__(self) self.stage = stage self.db_name = '%s_%s' % (self.channel, self.stage) self.coll_name = 'cv_%s' % self.stage
def __init__(self, owner): CBaseStore.__init__(self) self.owner = owner self.db = "cv_crawler" self.coll = 'page_store_{}'.format(self.owner) self.py_c = self.cmgClient.cv_page_store_mongo_client[self.db][self.coll] self._bulk = self.py_c.initialize_unordered_bulk_op() self._bulk_size = 0
def __init__(self, stage='raw'): CBaseStore.__init__(self) self._stage = stage self.raw_db_name = "jd_51job_raw" self.measure_db_name = "jd_51job_measure" self.raw_coll_name = "jd_raw" self.measure_coll_name = "jd_measure" self.pymongo_raw_client = pymongo.MongoClient(self.cmgClient.jd_51job_raw_store_mongo_url) self.pymongo_measure_client = pymongo.MongoClient(self.cmgClient.jd_51job_measure_store_mongo_url)
def __init__(self, owner): CBaseStore.__init__(self) self.owner = owner self.db = "co_crawler" self.coll = 'page_store_{}'.format(self.owner) self.py_c = self.cmgClient.page_store_mongo_client[self.db][self.coll]
def __init__(self): CBaseStore.__init__(self) self.db = "2c_ipin" self.coll = "jd_measure" self.py_c = pymongo.MongoClient(self.cmgClient.toc_ipin_mongo_url)
def __init__(self): CBaseStore.__init__(self) self.db_name = 'cv_hash' self.coll_name = 'cv_hash' self.pymongo_client = self.cmgClient.cv_hash_table_client[self.db_name][self.coll_name]