Added tag 1.1.0 for changeset 98e12f19a801
10% of 1MB is 100KB.
If forced page eviction fails, just give up and hope it works next time.

This allows rec_evict.c to simply set the WT_REF state to WT_REF_MEM after all
failures, and fixes a bug where pages on the forced eviction queue would end up
with state WT_REF_MEM, meaning they could be chosen for eviction multiple
times.

The tradeoff is that when building a tree from scratch that is larger than the
cache size, the eviction thread may never get exclusive access to the single
leaf page in order to evict it.  I've added a yield to the eviction server path
to give application threads a chance to leave the page, but that won't help in
cases of genuine contention (though we've never had a complete answer for that
case).

closes #175
Account for memory allocated when reading a page into cache.
Resize scratch buffers in preference to allocating new ones.
Fix a race between threads reading in and then modifying a page.
Get rid of the pinned flag: it is no longer used.
Overwrite pages when they're discarded to make it more likely we catch
a thread trying to use them.
Standardize python spacing.
Standardize python spacing.
Standardize python spacing.
Standardize python spacing.
Merge branch 'master' of https://github.com/wiredtiger/wiredtiger
Add the -S option to the test/thread program, that uses a new session
handle on every operation.  This tests issue #178.
Changes for issue #178.

The underlying problem is btree files weren't completely closed before
they could be re-opened.  This behavior can be triggered by using a
new session on every operation (see the new -S flag to the test/thread
program).  Instead of repeating the dance we do on open, I'm leaving
the btree handles in the connection list for the life of the connection.

The reason I'm going in this direction is that any application that opens
new sessions on each operation (for example, simple scripting language
APIs), will be doing file I/O on every open, and I'd rather avoid that.
(In other words, performance will just suck, instead of being unusable:
it's about 60% slower at the moment).

Most applications don't operate on enough files to care that files aren't
actually discarded, but if you have a long-lived application that opens
thousands of unique files, this approach will eventually see problems
(long file open times as the list of files gets long, and file-descriptor
consumption).

Detailed changes:

When connections are closed, create a session and discard the btree
handles.  I think this fixes a long-standing bug in closing a connection,
that, for any reason, still has open btree handles, we'd drop core when we
tried to evict the pages because we were closing them using the default
session handle.  I don't see any reason we can't allocate a new session
during connection->close, but this is worth careful review.

Change the session close of a btree to be a reference decrement, and
nothing else.  (We don't need the reference right now, but any future
house-cleaning solution will likely need a reference count, so I'm
leaving it in.)

Change __wt_session_lock_btree() to always re-open the tree, even if
it's the first time the session is opening the file.  Now that we're
caching handles in the connection layer, there's no reason to believe
the existing handle is open in any particular configuration.

Move set/clear of the WT_BTREE_OPEN flag into the connection btree handle
code, it's cleaner.  I actually don't think we need the WT_BTREE_OPEN flag
any longer, but I'm not totally convinced of that, and we may need it when
we do cleanup.
Don't leak the allocated path if the turtle file doesn't yet exist.
Don't leak the schema-table entry for the file when setting the root.
Changes for issue #178.

Close/discard all of the files but the schema file first, because writing
those files may result in updates to the schema file.

Updating the schema file may add the schema table to the session's list
of btrees: we're about to discard the underlying schema table file object,
so manually clear that list before closing the last file and discarding
the session handle.
The comment "start with the default session to keep error handling
simple."  no longer makes any sense, that's the underlying function's
problem because we aren't passing it a session handle (and it handles
it correctly).  Use NULL as the "not allocated" flag value rather than
the default session.
Changes for issue #178: pass the cfg argument to __wt_session_lock_btree()
no matter what path we took.