

def openConnection_jdbc():
    logger = logging.getLogger(__name__)
    try:
        _ = threadVar.connection
    except:
        threadVar.connection = None
    if (threadVar.connection is None):
        logger.info('To get database meta connection')
        threadVar.connection = zxJDBC.connect(conf.metadb_url_jdbc, conf.metadb_uid_jdbc, conf.metadb_pwd_jdbc, conf.metadb_driver_jdbc)
        logger.info('Meta connection: %s', (threadVar.connection,))
    logger.debug('DB connection used: %s', threadVar.connection)
    return threadVar.connection

dataset/ETHPy150Open harryliu/edwin/edwinServer/common/database_meta.py openConnection_jdbc/original