def __init__(self, conf): ExtractedDataConnector.__init__(self) self.host = conf['hbase_host'] self.port = int(conf['hbase_port']) table_prefix = '' if conf['hbase_namespace'] == 'default' or conf['hbase_namespace'] == '' else conf['hbase_namespace'].encode()+':' self.domain_table = table_prefix + conf['hbase_domain_table'].encode() self.extracted_all_table = table_prefix + conf['hbase_extracted_all_table'].encode() self.extracted_domain_table = table_prefix + conf['hbase_extracted_domain_table'].encode() self.hbase_conn = None
def __init__(self, config): """ :param config: database connection info and table names { user:..., database:..., password:..., host:...., } :return: a new EntityDataConnector for a mysql database """ ExtractedDataConnector.__init__(self) self.config = config self.cnx = None
def __init__(self, config): """ :param config: database connection info and table names { user:..., database:..., password:..., host:...., } :return: a new EntityDataConnector for a mysql database """ ExtractedDataConnector.__init__(self) self.config = config self.cnx = None
def __init__(self, hbase_host): ExtractedDataConnector.__init__(self) self.hbase_host = hbase_host self.hbase_conn = None