v3.3.0 (oracledb): "DPI-1011: connection was not acquired from a session pool" on destroyRawConnection
Author: ICitateCreated Aug 25, 2026Updated Aug 25, 2026
Hi! We upgraded to 3.3.0 and stumbled upon the following,
The oracledb dialect destroys pooled connections with:
destroyRawConnection(connection) {
return connection.release({ drop: true });
}But connections in the default pool are standalone, created via oracledb.getConnection(). drop: true is only valid for native pool connections.
So on a standalone connection using oracle's thick mode this happens:
DPI-1011: connection was not acquired from a session poolThus, leaving the connection open.
I think this was introduced by PR #6414. We reverted back to 3.2.10 and the problem is gone. Another solution would be to move to a native pool, but I reckon this doesn't address the issue.
Source: knex/knex