extensions reference other shared libraries. Previously I tried to turn
all those shared libs into static libs, however that didn't pan out so well.
So now the libwiredtiger.so library is loaded by wterl.so also, later on
during use libwiredtiger.so will load libwiredtiger_snappy.so and
libwiredtiger_bzip2.so which now have libsnappy.a and libbz2.a respectively
linked statically so as to avoid confusion.
than those in the various queues. Reenable the (still failing)
truncate tests (because they don't SEGV anymore). Still might be
a memory leak, next up is valgrind.
the request queue over to a simple fifo queue which could (if needed)
be made lock-free. Cursor searches can optionally now specifiy that
they are mid-scan so as not to have their cursor handles reset every
call.
stop sending it over. Allow the user to set a "type" of storage
in their config to either 'table' for btree or 'lsm' for a log
structured merge tree. Various other cleanup.
dtor commented out, otherwise it would SEGV on GC. Some of the truncate
tests fail (race?) but don't SEGV, so that's not so bad. Fixed numerous
issues and also removed a mutex and queue of idle worker threads because
it isn't used so why bother with it?
also not sure why there is a segv when exiting but not in gdb.
Unlock mutex before returning error codes. Alloc/free copies of some
strings allocated on the stack.
* No longer expose WT_SESSION into Erlang at all as WT's model is to
maintain one WT_SESSION per-thread and we don't know anything about
threads in Erlang.
* async_nif worker threads don't pull both mutexes on every loop
when processing requests, only one
* async_nif provides a worker_id (int, 0 - MAX_WORKERS) within the
work block scope which we use to find our per-worker WT_SESSIONs
* async_nif maintained a number of globals which I'm moving into
the NIF's priv_data so that on upgrade/reload we have a fighting
chance to "Do the Right Thing(TM)".
* NIF Upgrades/Reloads started to plumb this in.
* Use a khash to manage the cache of URI->WT_CURSORs per WT_SESSION.
* Added start/stop positions into truncate call to allow for truncating
sub-ranges data.
* Lots of other details I'm sure I've forgotten and more left undone.
Search for "TODO:" or try to compile to see what's left, and then
there is a need for a lot more tests given all this new complexity.
to avoid a) opening a large number of Sessions or Cursors and b) avoid
reusing a Session/Cursor pair in more than one thread. Each operation,
except folds, use the Session/Cursor pair corresponding to the scheduler
id (roughly "core") they are running on. Each vnode instance will have
(count(schedulers) + count(active folds)) Session/Cursor pairs in use so
be sure to set session_max large enough when opening the connection to
WiredTiger. This method will cause problems with scheduler threads going
to "sleep" so be sure to run schedmon to wake them up.