salortiz / LMDB_File

Perl wrapper around the OpenLDAP's LMDB
Other
8 stars 12 forks source link

Allow user to select auto commit mode in BeginTxn(), LMDB::Env->new, or on $DB #26

Open akotlar opened 7 years ago

akotlar commented 7 years ago

Would be useful to have a flag to set the default auto commit mode to commit instead of abort.

I could see this being done in several places, such as BeginTxn(), LMDB::Env->new, or as a property on $DB.

This saves the overhead of having to set the autocommit mode every time a new transaction is created, which in our case happens billions of times per database.