summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Bump version to 1.1.1.1.1.1Michael Cahill2012-03-125-6/+34
|
* Revert a comment, only clear the exclusive flag if it was set.Michael Cahill2012-03-121-5/+5
|
* Back out part of the last change: we have to reopen when releasing a treeMichael Cahill2012-03-122-5/+7
| | | | | | | handle after an exclusive operation because it will be cached in sessions and we don't check WT_BTREE_OPEN every time we open a cursor. Make sure that open flags are passed through the schema layer so that files are accessed with appropriate settings.
* Only reopen handles when exclusive access is required, leave them closed on theMichael Cahill2012-03-122-38/+70
| | | | | list so that any future accesses open them with whatever flags are required. Spin trying to get exclusive access to a handle in the open path: we don't want block waiting on open cursors if we race to open the file.
* Default to a verbose build, we can switch that off by running "configure ↵Michael Cahill2012-03-111-1/+1
| | | | | | | --enable-silent-rules"). --HG-- extra : rebase_source : 4af5f56a6a695af668c98ab5823d591a52bb843d
* Fix a buffer overflow when encoding a root address.Michael Cahill2012-03-122-3/+2
| | | | | --HG-- extra : rebase_source : 2cc50ff7b2851dc0a4a5f60aaf9b5ca9da6c9634
* tiny code simplification.Keith Bostic2012-03-111-5/+3
|
* Fix a race between a diagnostic check and session close so test/thread "-S" ↵Michael Cahill2012-03-112-11/+11
| | | | runs in diagnostic mode.
* spellingMichael Cahill2012-03-111-1/+1
|
* Always have an exclusive lock on btree handles before calling ↵Michael Cahill2012-03-114-14/+15
| | | | __wt_conn_btree_close, apart from the conn->close case which is inherently single-threaded.
* Only use the number of bytes in the root address known to be good: don't assumeMichael Cahill2012-03-111-9/+11
| | | | it is NUL terminated.
* Don't close a handle holding conn->spinlock: lock the handle exclusive instead.Michael Cahill2012-03-111-7/+15
|
* Wait for application threads in LRU eviction to drain before walking a file.Michael Cahill2012-03-111-0/+7
|
* Use default_session in case of errors.Michael Cahill2012-03-111-7/+10
|
* Close btree handles in the list: otherwise we can't safely remove or rename ↵Michael Cahill2012-03-115-18/+32
| | | | | | | | them. Use a separate spinlock in the OS layer to manage lists of file handles so that we can safely call close while holding the general purpose connection spinlock. Fixes test failures in test_base02 (among others). refs #178
* test/thread/run.c:129: warning: unused variable ‘keyno’Michael Cahill2012-03-111-1/+1
|
* Previously, we assumed the underlying object would be removed if theKeith Bostic2012-03-101-7/+4
| | | | | | ref count was 1 and we called __wt_session_remove_btree; that's no longer the case, so we have to release our exclusive lock to avoid deadlock.
* Fix an error message tag.Keith Bostic2012-03-101-1/+1
|
* Fix a comment, was listing the wrong name.Keith Bostic2012-03-101-1/+1
|
* Switch the function name order, use conn_btree_XXX instead ofKeith Bostic2012-03-105-19/+19
| | | | conn_XXX_btree.
* Changes for issue #178: pass the cfg argument to __wt_session_lock_btree()Keith Bostic2012-03-101-1/+1
| | | | no matter what path we took.
* The comment "start with the default session to keep error handlingKeith Bostic2012-03-101-6/+3
| | | | | | | 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.Keith Bostic2012-03-101-15/+57
| | | | | | | | | | 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.
* Don't leak the schema-table entry for the file when setting the root.Keith Bostic2012-03-101-1/+2
|
* Don't leak the allocated path if the turtle file doesn't yet exist.Keith Bostic2012-03-101-1/+2
|
* Changes for issue #178.Keith Bostic2012-03-106-36/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* Add the -S option to the test/thread program, that uses a new sessionKeith Bostic2012-03-103-69/+125
| | | | handle on every operation. This tests issue #178.
* Merge branch 'master' of https://github.com/wiredtiger/wiredtigerDon Anderson2012-03-0913-80/+100
|\
| * Overwrite pages when they're discarded to make it more likely we catchKeith Bostic2012-03-092-0/+4
| | | | | | | | a thread trying to use them.
| * Get rid of the pinned flag: it is no longer used.Michael Cahill2012-03-097-16/+9
| |
| * Fix a race between threads reading in and then modifying a page.Michael Cahill2012-03-091-2/+14
| |
| * Resize scratch buffers in preference to allocating new ones.Michael Cahill2012-03-091-40/+32
| |
| * Account for memory allocated when reading a page into cache.Michael Cahill2012-03-095-22/+41
| |
* | Standardize python spacing.Don Anderson2012-03-092-4/+4
| |
* | Standardize python spacing.Don Anderson2012-03-093-3/+6
| |
* | Standardize python spacing.Don Anderson2012-03-092-13/+13
| |
* | Standardize python spacing.Don Anderson2012-03-092-51/+51
|/
* If forced page eviction fails, just give up and hope it works next time.Michael Cahill2012-02-292-23/+33
| | | | | | | | | | | | | | | | 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
* 10% of 1MB is 100KB.Michael Cahill2012-02-281-1/+1
|
* Added tag 1.1.0 for changeset 98e12f19a801Michael Cahill2012-02-281-0/+1
|
* Removed tag release-1.01.1.0Michael Cahill2012-02-281-0/+2
|
* Added tag 1.0.0 for changeset 9e6541afe6e8Michael Cahill2012-02-281-0/+1
|
* Bump the version to 1.1.Michael Cahill2012-02-285-9/+50
|
* Make checks of test code optional, so they don't complain in a release tree.Michael Cahill2012-02-283-12/+12
|
* Allow s_release to work from a git or hg tree.Michael Cahill2012-02-281-7/+16
|
* Mark some more buffers as requiring alignment for use with O_DIRECT.Michael Cahill2012-02-281-0/+1
|
* Fix the configure test for default buffer alignment.Michael Cahill2012-02-282-16/+16
|
* Additional re-structuring of the eviction code. The only real changesKeith Bostic2012-02-271-44/+83
| | | | | | | are failing when we notice a page that can't be merged, (rather than continuing on and attempting to push out the full tree), and noticing that a page is empty and can't be evicted during review, instead of in the parent-page-update routine.
* fix a comment.Keith Bostic2012-02-271-2/+2
|
* Fix a comment.Keith Bostic2012-02-271-6/+5
|