Where the environment was initialized with the Db.DB_INIT_TXN flag,
calling DbEnv.close aborts any uncommitted transactions.
(Applications are should not depend on this behavior. If the process' has
already closed a database handle which is necessary to abort an
uncommitted transaction, the Berkeley DB environment must then require that
recovery be run before further operations are done, since once a
transaction exists that cannot be committed or aborted, no future
checkpoint can ever succeed.)
In multi-threaded applications, only a single thread may call
Once DbEnv.close has been called, regardless of its return,
the Berkeley DB environment handle may not be accessed again.
The DbEnv.close method throws an exception that encapsulates a non-zero error value on
The DbEnv.close method may fail and throw an exception for errors specified for other Berkeley DB and C library or system methods.
If a catastrophic error has occurred, the DbEnv.close method may fail and throw
a DbRunRecoveryException, in which case all subsequent Berkeley DB calls
will fail in the same way.