def _init_connection(self):
<EOL>if not self.servers:<EOL><INDENT>raise RuntimeError("<STR_LIT>")<EOL><DEDENT>server = random.choice(self.servers)<EOL>if server.scheme in ["<STR_LIT:http>", "<STR_LIT>"]:<EOL><INDENT>self.connection = http_connect(<EOL>[server for server in self.servers if server.scheme in ["<STR_LIT:http>", "<STR_LIT>"]],<EOL>timeout=self.timeout, basic_auth=self.basic_auth, max_retries=self.max_retries, retry_time=self.retry_time)<EOL>return<EOL><DEDENT>elif server.scheme == "<STR_LIT>":<EOL><INDENT>self.connection = thrift_connect(<EOL>[server for server in self.servers if server.scheme == "<STR_LIT>"],<EOL>timeout=self.timeout, max_retries=self.max_retries, retry_time=self.retry_time)<EOL><DEDENT>
Create initial connection pool