When putting a record, just make space for the data, don't copy it.
(Not compatible with MDB_DUPSORT, since the actual data is needed
to determine the insert location.)
For any change to a page or node, update all other cursors pointing
at the same page (or node). Cursors are now stored in a linked list
off their owning transaction. Cursors are all closed when the transaction
ends. Cursors in parent transactions are updated when their child
transaction commits.
Instead of converting directly to a subDB when the first duplicate
item is seen for a key, convert to a subpage instead. Allow the
subpage to grow up to the overflow limit, then convert to a subDB.
This saves a significant amount of space in a typical slapd index
database.
Currently we don't convert back to the smaller form if items are
later deleted. Probably could do that with some hysteresis, e.g.,
convert back from subDB to subpage when the size drops below
(overflow limit/2). Maybe later.
Various mistakes when converting from previous data structures.
Add a few more debug asserts/sanity checks.
Split all "if (foo) return" constructs to separate lines to allow
easier breakpoint setting.
Add mtest6 for checking mdb_split() behavior. This needs to be
expanded to check rebalance/merge cases too.
Use unsigned int for reader counts/max limits, that's the smallest
change. Don't need uint32_t when mdb_env_set_maxreaders() takes less.
Change prototypes of mdb_env_set_maxreaders,mdb_env_get_maxreaders().
Check the mdb_env_set_maxreaders() argument.