Connection pools aren't currently supported - the argument is there for consistency with other engines.
(
self, querystring: QueryString, in_pool: bool = False
)
| 767 | return response |
| 768 | |
| 769 | async def run_querystring( |
| 770 | self, querystring: QueryString, in_pool: bool = False |
| 771 | ): |
| 772 | """ |
| 773 | Connection pools aren't currently supported - the argument is there |
| 774 | for consistency with other engines. |
| 775 | """ |
| 776 | query_id = self.get_query_id() |
| 777 | |
| 778 | if self.log_queries: |
| 779 | self.print_query(query_id=query_id, query=querystring.__str__()) |
| 780 | |
| 781 | query, query_args = querystring.compile_string( |
| 782 | engine_type=self.engine_type |
| 783 | ) |
| 784 | |
| 785 | # If running inside a transaction: |
| 786 | current_transaction = self.current_transaction.get() |
| 787 | if current_transaction: |
| 788 | response = await self._run_in_existing_connection( |
| 789 | connection=current_transaction.connection, |
| 790 | query=query, |
| 791 | args=query_args, |
| 792 | query_type=querystring.query_type, |
| 793 | table=querystring.table, |
| 794 | ) |
| 795 | else: |
| 796 | response = await self._run_in_new_connection( |
| 797 | query=query, |
| 798 | args=query_args, |
| 799 | query_type=querystring.query_type, |
| 800 | table=querystring.table, |
| 801 | ) |
| 802 | |
| 803 | if self.log_responses: |
| 804 | self.print_response(query_id=query_id, response=response) |
| 805 | |
| 806 | return response |
| 807 | |
| 808 | async def run_ddl(self, ddl: str, in_pool: bool = False): |
| 809 | """ |
nothing calls this directly
no test coverage detected