beforeOpen abstract method

Future<void> beforeOpen(
  1. QueryExecutor executor,
  2. OpeningDetails details
)

A callbacks that runs after the database connection has been established, but before any other query is sent.

The query executor will wait for this future to complete before running any other query. Queries running on the executor are an exception to this, they can be used to run migrations. No matter how often QueryExecutor.ensureOpen is called, this method will not be called more than once.

Implementation

Future<void> beforeOpen(QueryExecutor executor, OpeningDetails details);