Documentation
    Preparing search index...

    Interface InitConnectionOptions

    Options for initConnection.

    interface InitConnectionOptions {
        onError?: (err: Error) => void;
    }
    Index
    onError?: (err: Error) => void

    Called when a pooled connection fails outside of a query, for example when the database restarts, fails over, or terminates the session (pg_terminate_backend, idle_in_transaction_session_timeout). The pool discards the broken connection and opens a new one on demand, so this is for reporting only.