title: SQLAlchemy: how to establish connection before using them?
body: <p>The first query execution takes much longer than consecutive calls because of connection establishment.</p>
  <p>For example:</p>
  <pre><code>connection_string = '...'
  engine = create_engine(connection_string)
  
  first_query = engine.execute('SELECT * FROM Table1').first()  # Takes about 2.2 seconds
  same_table_second_query = engine.execute('SELECT * FROM Table1').first()  # Takes about 0.8 seconds
  other_table_query = engine.execute('SELECT * FROM Table2').first()  # Takes about 0.8 seconds
  </code></pre>
  <p>In my case, the pool is intended to serve multiple threads (and I'll adjust its size accordingly) and performance is VERY critical.</p>
  <p>Is there a way to initialize / establish the entire pool before using it? If there's a different solution I'd love to learn it.</p>
  <hr />
  <p>Edit:<br />
  If I use the returned connection instead of the engine:</p>
  <pre><code>connection = engine.connect()
  first_query = connection.execute('SELECT * FROM Table1').first()
  same_table_second_query = connection.execute('SELECT * FROM Table1').first()
  </code></pre>
  <p>Both take about 0.07s.
  But this doesn't solve my problem as I still need an established pool to share between threads.</p>