def get_test_db_conn(dbname='gus'): '''return a test connection to the specified database ''' log.info("connecting to test database") return sqlcontext.get_db_conn(CONNECTION_ARGS[dbname]['test'])
def get_db_conn(dbname='gus'): '''return a production connection to the specified database ''' log.info("connecting to production database") return sqlcontext.get_db_conn(CONNECTION_ARGS[dbname]['prod'])