-
Notifications
You must be signed in to change notification settings - Fork 123
Closed
Labels
bugAn issue relates to behaviour that violates the intention of the libraryAn issue relates to behaviour that violates the intention of the library
Description
My assumption was that the Dbi
object would be created once and then can be used from any thread (using relevant read/write transactions). I based this on the docs here:
Generally databases should only be opened once, by the first transaction in the process. After the first transaction completes, the database handles can freely be used by all subsequent transactions
If this is the case then there is a bug due to compKeyA
and compKeyB
being fields in Dbi
and thus shared across users of Dbi
. This code shows how a reader will lead to corrupt inserts of sequential keys when Dbi
is shared. It feels like the reusable buffers should be coupled with the txn
object, but I cannot see a good way of achieving this in the current form.
Metadata
Metadata
Assignees
Labels
bugAn issue relates to behaviour that violates the intention of the libraryAn issue relates to behaviour that violates the intention of the library