prorm API Reference
    Preparing search index...

    Interface PrormEvents

    Event listener types for Prorm events

    interface PrormEvents {
        beforeQuery: (event: QueryEvent) => void;
        query: (event: QueryEvent) => void;
        slowQuery: (event: SlowQueryEvent) => void;
        acquire: (connection: any) => void;
        release: (connection: any) => void;
        pool: (error: Error) => void;
        error: (error: Error) => void;
    }
    Index
    beforeQuery: (event: QueryEvent) => void

    Fired before a query is executed

    query: (event: QueryEvent) => void

    Fired after a query is executed

    slowQuery: (event: SlowQueryEvent) => void

    Fired when a query exceeds the slow query threshold

    acquire: (connection: any) => void

    Fired when a connection is acquired from the pool

    release: (connection: any) => void

    Fired when a connection is released back to the pool

    pool: (error: Error) => void

    Fired when there's a pool error

    error: (error: Error) => void

    Fired when there's an error