Add a test case for Java auto close feature.
Add file I forgot.
Create a cache of WT_SIZE structures in the WT_SESSION_IMPL handle so
we (hopefully) never call malloc while holding the block manager's live
lock, and minimize modifying the WT_BLOCK structure's cache lines.
Merge pull request #767 from wiredtiger/session-size-alloc

Add a WT_SIZE structure cache to the WT_SESSION_IMPL handle.
We backed out the change to rename "allocation_size" in 1.6.6, back out
the entry in the upgrading document.
Merge branch 'java-auto-close2' of https://github.com/wiredtiger/wiredtiger into develop
Null out closed handles in Java, and detect nulled handles on use.  refs #485.

As reported in #485, when a conn/session is closed, any subordinate
open cursors and sessions have dangling handles that refer to freed
memory.  But also, if a conn/session/cursor handle is closed, that
handle may still be referenced in Java though it references freed
memory.

This commit uses the event handler for close calls to capture the first
case, and makes explicit calls at the close site for the second case.
For each case, a close will set the Java side 'swigCPtr' for each associated
object being closed to 0.

For detection, typemaps effectively check an arg's swigCPtr to see
if the object has been previously closed.  Special cases, like when
a NULL handle is permitted in the API, are accounted for.

Some details:
  - WT_HANDLE_NULLABLE() and WT_HANDLE_CLOSED() mark points in the API
    (wiredtiger.in) where handles may be used as null and where
    handles are closed.  This are not exposed to doxygen.
  - lang_private fields have been added to WT_CONNECTION_IMPL,
    WT_SESSION_IMPL and WT_CURSOR to keep a handle to the
    associated java object, needed at the time of the close().
Add static initializer for WT_CURSOR.lang_private. refs #485.
Start tuning the WT_SESSION_IMPL cache of WT_EXT and WT_SIZE structures.

Increase the pre-alloc of WT_EXT/WT_SIZE structures from 5/2 to 5/5 in
the write/free paths, and from 100/10 to 250/250 in the checkpoint path.

Turn off cache limits: checkpoints can take tens of thousands of WT_EXT
structures and hundreds of WT_SIZE structures, we want to cache
everything until the checkpoint completes.  Add a cleanup call after the
checkpoint so we don't tie down megabytes of memory between checkpoints.

Split the previous pre-allocate function into two parts, it's simpler
as a function to pre-allocate entries and a separate function to take
an entry for use.

Remove the tracking of "memory allocations while locked"; there are
extent lists we read while not holding any locks, and they can be
really, really large requiring the allocation of tens of thousands of
WT_EXT structures, they make the statistic meaningless.
Add upgrade documentation for WT_EVENT_HANDLER changes.
Cut WiredTiger release 1.6.6
Bump release in develop branch to 1.6.7
Merge branch 'develop' into java-auto-close2

Conflicts:
	src/include/session.h
Merge branch 'develop' of https://github.com/wiredtiger/wiredtiger into java-auto-close2
LSM optimizations:

1. improve merge algorithm, particularly when there are multiple merge threads;
2. get incrementally more aggressive about merging, rather than all or nothing;
3. avoid the checkpoint lock in common LSM paths.
Go back to holding the checkpoint lock when flushing in-memory LSM chunks.  Otherwise, we can race with application checkpoints in test/format.

refs #769
Merge pull request #768 from wiredtiger/session-ext

Start tuning the WT_SESSION_IMPL cache of WT_EXT and WT_SIZE structures.
Merge pull request #769 from wiredtiger/lsm-opt

LSM optimizations
Fix a GCC (un)signed warning:
lsm/lsm_worker.c:129:3: error: conversion to 'u_int' from 'int' may change the sign of the result
Another GCC (un)signed warning:
lsm/lsm_worker.c:109:25: error: conversion to 'u_int' from 'int' may change the sign of the result